Update archives_controller.rb
This commit is contained in:
parent
132fd8aa4b
commit
185b16d7fe
|
@ -262,7 +262,7 @@ F cats = files_by_cateogry.keys.collect do |cat|
|
||||||
if categories.first == "all"
|
if categories.first == "all"
|
||||||
categories = OrbitHelper.widget_module_app.categories
|
categories = OrbitHelper.widget_module_app.categories
|
||||||
puts categories
|
puts categories
|
||||||
categories_sort = get_sorted_cat_with_filter(categories,'orm')
|
categories_sort = get_sorted_cat_with_filter(categories,'id')
|
||||||
@categories = categories_sort.collect do |cat|
|
@categories = categories_sort.collect do |cat|
|
||||||
{
|
{
|
||||||
"title" => cat.title,
|
"title" => cat.title,
|
||||||
|
@ -334,7 +334,7 @@ F cats = files_by_cateogry.keys.collect do |cat|
|
||||||
end
|
end
|
||||||
if cat_type=='id'
|
if cat_type=='id'
|
||||||
categories_temp = ModuleApp.where(:key => "archive").first.categories
|
categories_temp = ModuleApp.where(:key => "archive").first.categories
|
||||||
categories = categories_temp.where(id: categories)
|
categories = categories_temp.where(_id: categories)
|
||||||
end
|
end
|
||||||
categories_sort = []
|
categories_sort = []
|
||||||
all_categories_id.each do |cat_id|
|
all_categories_id.each do |cat_id|
|
||||||
|
|
Loading…
Reference in New Issue