mongoid-enum
mongoid-enum copied to clipboard
search translation in superclass if it's not in subclass.
When i have a inherited model and a enum in the superclass, I need to repeat the translation. E.g
class Employee
enum :foo, [:bar, :baz, :zaz]
class Manager < Employee
and in translation .yml file I need to have
enums:
employee:
foo:
bar: BAR
baz: BAZ
zaz: ZAZ
employees/manager:
foo:
bar: BAR
baz: BAZ
zaz: ZAZ
So if I don't have the employees/manager defined, its should search in the employee