From 0bdb3eb1184260faa08ef48d97aef060fe7d1817 Mon Sep 17 00:00:00 2001 From: wanglinchun Date: Tue, 22 Apr 2014 20:23:15 +0800 Subject: [PATCH] =?UTF-8?q?=E5=BA=94=E7=94=A8=E9=A1=B5=E9=9D=A2=E6=B7=BB?= =?UTF-8?q?=E5=8A=A0=E6=89=80=E5=B1=9E=E7=AB=9E=E8=B5=9B=E5=8F=8A=E7=9B=B8?= =?UTF-8?q?=E5=BA=94=E9=93=BE=E6=8E=A5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/views/softapplications/show.html.erb | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/app/views/softapplications/show.html.erb b/app/views/softapplications/show.html.erb index d5681c4ea..51195dfcf 100644 --- a/app/views/softapplications/show.html.erb +++ b/app/views/softapplications/show.html.erb @@ -25,7 +25,8 @@ 所属类别:<%= @softapplication.app_type_name %> - 发布时间:<%=format_time @softapplication.created_at %> + <% contest = @softapplication.contests.first %> + 所属竞赛:<%= contest ? link_to(contest.name, show_contest_contest_path(contest)) : '尚未加入竞赛'%> 发布人员:<%= @softapplication.user.name %> @@ -42,7 +43,7 @@ 平均评分: <%= rating_for @softapplication, :static => true, dimension: :quality, class: 'rateable div_inline' %> - + 发布时间:<%=format_time @softapplication.created_at %>