breadcrumb widget of front-end has done
Conflicts: app/controllers/front_controller.rb lib/parsers/parser_common.rb
This commit is contained in:
parent
f3bfe67e68
commit
bfad8467c8
|
@ -3,7 +3,7 @@ class FrontController < ApplicationController
|
||||||
layout false
|
layout false
|
||||||
|
|
||||||
def show_breadcrumb
|
def show_breadcrumb
|
||||||
@ancestors = Page.find(params[:page_id]).ancestors_and_self
|
@ancestors = Page.find(params[:id]).ancestors_and_self
|
||||||
@ancestors.delete_at(0)
|
@ancestors.delete_at(0)
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
|
@ -147,7 +147,7 @@ module ParserCommon
|
||||||
# breadcrumb
|
# breadcrumb
|
||||||
def parse_breadcrumbs_edit(body = nil, page = nil, edit=nil)
|
def parse_breadcrumbs_edit(body = nil, page = nil, edit=nil)
|
||||||
body.css('breadcrumb').each do |breadcrumb|
|
body.css('breadcrumb').each do |breadcrumb|
|
||||||
ancestors = Page.find(page.id).ancestors_and_self.map{|m|m.title} rescue nil
|
ancestors = Page.find(page.id).ancestors_and_self rescue nil
|
||||||
ancestors.delete_at(0)
|
ancestors.delete_at(0)
|
||||||
res = ''
|
res = ''
|
||||||
|
|
||||||
|
@ -156,7 +156,7 @@ module ParserCommon
|
||||||
res << "<ul class='list'>"
|
res << "<ul class='list'>"
|
||||||
ancestors.each do |node|
|
ancestors.each do |node|
|
||||||
res << "<li class='active'>"
|
res << "<li class='active'>"
|
||||||
res << "<a herf ='/#{node.path} )}>#{node}</a>"
|
res << "<a herf='/#{node.path}'>#{node.title}</a>"
|
||||||
res << "</li>"
|
res << "</li>"
|
||||||
end
|
end
|
||||||
res << "</ul>"
|
res << "</ul>"
|
||||||
|
@ -207,10 +207,7 @@ module ParserCommon
|
||||||
''
|
''
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
<<<<<<< HEAD
|
|
||||||
|
|
||||||
=======
|
|
||||||
>>>>>>> cf956ac... breadcrumb widget of back-end has done, front-end has bug...
|
|
||||||
# sitemap
|
# sitemap
|
||||||
def parse_sitemaps_edit(body = nil, page = nil, edit=nil)
|
def parse_sitemaps_edit(body = nil, page = nil, edit=nil)
|
||||||
sitemap = body.css('sitemap').first
|
sitemap = body.css('sitemap').first
|
||||||
|
|
Loading…
Reference in New Issue