diff --git a/app/controllers/pages_controller.rb b/app/controllers/pages_controller.rb
index 3b0978f98..7a0ffa437 100644
--- a/app/controllers/pages_controller.rb
+++ b/app/controllers/pages_controller.rb
@@ -62,7 +62,14 @@ class PagesController < ApplicationController
def get_item
module_app = ModuleApp.first(:conditions => {:key => params[:app_name]})
- @item = Item.first(:conditions => {:module_app_id => module_app.id, :app_frontend_url => params[:app_action]})
+ if !params[:category_id].blank? && !params[:tag_id].blank?
+ @item = Item.first(:conditions => {:module_app_id => module_app.id, :app_frontend_url => params[:app_action], :category => params[:category_id], :tag => params[:tag_id]})
+ elsif !params[:category_id].blank?
+ @item = Item.first(:conditions => {:module_app_id => module_app.id, :app_frontend_url => params[:app_action], :category => params[:category_id]})
+ elsif !params[:tag_id].blank?
+ @item = Item.first(:conditions => {:module_app_id => module_app.id, :app_frontend_url => params[:app_action], :tag => params[:tag_id]})
+ end
+ @item = Item.first(:conditions => {:module_app_id => module_app.id, :app_frontend_url => params[:app_action]}) unless @item
#TODO 需要做 error handler 處理沒有新增該模組頁面導致錯誤的可能性
end
diff --git a/app/views/admin/sites/sitemap_frontend.html.erb b/app/views/admin/sites/sitemap_frontend.html.erb
index 3656bb2d8..cd8372d3f 100644
--- a/app/views/admin/sites/sitemap_frontend.html.erb
+++ b/app/views/admin/sites/sitemap_frontend.html.erb
@@ -1,10 +1,10 @@
<% @items.each_with_index do |item, i| %>
-
<%= i+1 %> <%= item.title %>
+
<% item.children.each_with_index do |child, ii| %>
- - <%= "#{i+1}-#{ii+1}" %> <%= child.title %>
+ - <%= "#{i+1}-#{ii+1}" %> <%= child.title %>
<% end if item.children %>
diff --git a/vendor/built_in_modules/announcement/app/views/panel/announcement/widget/bulletins/bulletins_side_bar.html.erb b/vendor/built_in_modules/announcement/app/views/panel/announcement/widget/bulletins/bulletins_side_bar.html.erb
index c7b31818e..ce06d2e78 100644
--- a/vendor/built_in_modules/announcement/app/views/panel/announcement/widget/bulletins/bulletins_side_bar.html.erb
+++ b/vendor/built_in_modules/announcement/app/views/panel/announcement/widget/bulletins/bulletins_side_bar.html.erb
@@ -13,7 +13,7 @@
<%= t('announcement.tag_cloud') %>
<% @tags.each do |tag| %>
- <%= link_to tag[I18n.locale], panel_announcement_front_end_bulletins_path(:tag_id => tag.id), :class => "#{tag.cloud_amper} hot#{rand(4) + 1} #{(tag.id.to_s.eql?(params[:tag_id]) || tag.key.eql?(params[:tag_id])) ? 'active' : nil} " %>
+ <%= link_to tag[I18n.locale], panel_announcement_front_end_bulletins_path(:tag_id => tag.id, :category_id => params[:category_id]), :class => "#{tag.cloud_amper} hot#{rand(4) + 1} #{(tag.id.to_s.eql?(params[:tag_id]) || tag.key.eql?(params[:tag_id])) ? 'active' : nil} " %>
<% end %>
diff --git a/vendor/built_in_modules/news/app/views/panel/news/widget/news_bulletins/news_bulletins_side_bar.html.erb b/vendor/built_in_modules/news/app/views/panel/news/widget/news_bulletins/news_bulletins_side_bar.html.erb
index f754b7630..bf127ed26 100644
--- a/vendor/built_in_modules/news/app/views/panel/news/widget/news_bulletins/news_bulletins_side_bar.html.erb
+++ b/vendor/built_in_modules/news/app/views/panel/news/widget/news_bulletins/news_bulletins_side_bar.html.erb
@@ -13,7 +13,7 @@
<%= t('announcement.tag_cloud') %>
<% @tags.each do |tag| %>
- <%= link_to tag[I18n.locale], panel_news_front_end_news_bulletins_path(:tag_id => tag.id),:class => "#{tag.cloud_amper} hot#{rand(4) + 1} #{(tag.id.to_s.eql?(params[:tag_id]) || tag.key.eql?(params[:tag_id])) ? 'active' : nil} " %>
+ <%= link_to tag[I18n.locale], panel_news_front_end_news_bulletins_path(:tag_id => tag.id, :category_id => params[:category_id]),:class => "#{tag.cloud_amper} hot#{rand(4) + 1} #{(tag.id.to_s.eql?(params[:tag_id]) || tag.key.eql?(params[:tag_id])) ? 'active' : nil} " %>
<% end %>