orbit-basic/app/helpers/admin/attribute_values_view_helpe...

16 lines
416 B
Ruby
Raw Permalink Normal View History

module Admin::AttributeValuesViewHelper
OPT = [
["YYYY / MM / DD hh : mm","format1"],
["YYYY / MM / DD","format2"],
["YYYY / MM","format3"],
["YYYY","format4"]
]
def show_type_panel(attribute_field,type)
markup = attribute_field.markup
LIST[:markups][markup]["panel"] == type ? type : [type,'hide'].join(" ")
end
def name_to_id(str)
str.gsub(/\]/,'').gsub(/\[/,"_")
end
end