Created
March 9, 2016 18:41
-
-
Save jesuslerma/4c26adbc8d90d709e1ed to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def attr_redeable(attribute) | |
hash = { | |
:naturaleza => { | |
'1' => "Deudora", | |
'2' => 'Acreedora' | |
}, | |
:nivel_cuenta => { | |
'1' => 'Titulo', | |
'2' => 'Mayor', | |
'3' => 'Subcuenta', | |
'4' => 'Subtitulo' | |
}, | |
:tipo_cuenta => { | |
'1' => 'Activo', | |
'2' => 'Resultados Ingreso', | |
'3' => 'Resultados Gastos', | |
'4' => 'Pasivo', | |
'5' => 'Capital', | |
'6' => 'Cuentas de orden', | |
} | |
} | |
hash[attribute][self.send(attribute)] | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment