orbit-4-2/app/helpers/admin/attribute_values_view_helpe...

16 lines
416 B
Ruby

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