From 009a7626007ad930a9c71bd56be05dbd8537f9d3 Mon Sep 17 00:00:00 2001 From: p31729568 Date: Thu, 11 Jul 2019 17:00:01 +0800 Subject: [PATCH] fix competition index --- app/views/competitions/_header.html.erb | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/app/views/competitions/_header.html.erb b/app/views/competitions/_header.html.erb index b6790839..f4e0e912 100644 --- a/app/views/competitions/_header.html.erb +++ b/app/views/competitions/_header.html.erb @@ -4,7 +4,7 @@ <% @competition.competition_modules.where(:hidden => 0).each do |com_module| %> <% case com_module.name %> <% when '首页' %> - <% if params[:action] == 'show' %> + <% if params[:controller] == 'competitions' && params[:action] == 'show' %>
  • 首页
  • @@ -19,7 +19,7 @@ <% end %> <% when '赛事说明' %>
  • - <% if params[:action] == 'show' %> + <% if params[:controller] == 'competitions' && params[:action] == 'show' %> 赛事说明 <% else %> 赛事说明 @@ -27,7 +27,7 @@
  • <% when '大赛机构' %>
  • - <% if params[:action] == 'show' %> + <% if params[:controller] == 'competitions' && params[:action] == 'show' %> 大赛机构 <% else %> 大赛机构