Merge with sub_roles
This commit is contained in:
1 parent
fc591ee308
commit
62aaf79491
308 files changed
+2844
-17841
No files matched your search
@@ -1,7 +1,7 @@
|
||||
module Admin::UserHelper
|
||||
|
||||
def show_user_attribute(object, key, locale = '')
|
||||
attribute = object.attribute_values.detect {|av| av.key.to_s.eql?(key.to_s) || av[locale.to_s].eql?(locale.to_s) } rescue nil
|
||||
def show_attribute(object, field_id, locale = '')
|
||||
attribute = object.attribute_values.detect {|av| av.attribute_field_id.eql?(field_id) || av[locale.to_s].eql?(locale.to_s) } rescue nil
|
||||
if attribute
|
||||
if locale.to_s.blank?
|
||||
attribute['key']
|
||||
|
||||
Reference in new issue
Block a user