You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
11 lines
383 B
11 lines
383 B
5 years ago
|
json.data do
|
||
|
json.array! @data.each do |type, objs|
|
||
|
json.name I18n.t("enumerize.coo_img.img_type.#{type}")
|
||
|
json.values do
|
||
|
json.array! objs.sort_by(&:position).each do |obj|
|
||
|
json.img obj.url_states || (Util::FileManage.exist?('CooImg', obj.id) ? Util::FileManage.disk_file_url('CooImg', obj.id) : '')
|
||
|
json.url obj.src_states
|
||
|
end
|
||
|
end
|
||
|
end
|
||
|
end
|