Fix bug.
This commit is contained in:
parent
991b705399
commit
5c1e50eba7
|
@ -2,7 +2,6 @@ class SiteMenuWidgetsController < ApplicationController
|
|||
def create_json(pages)
|
||||
items = []
|
||||
pages.each do |page|
|
||||
next if (!page.menu_enabled_for.include?(I18n.locale.to_s) rescue false)
|
||||
item = {}
|
||||
item["obj"] = page
|
||||
if page.child_page.size > 0
|
||||
|
@ -92,7 +91,7 @@ class SiteMenuWidgetsController < ApplicationController
|
|||
end
|
||||
end
|
||||
if @expand_next_layer && !@expand_current_layer
|
||||
@pages = page.child_page
|
||||
@pages = page.sorted_published_child_pages
|
||||
end
|
||||
end
|
||||
@ul_index=[]
|
||||
|
|
Loading…
Reference in New Issue