From 5e029c5e67728a58d6c0cfd8ef279982d22289c6 Mon Sep 17 00:00:00 2001 From: daiao <35855898@qq.com> Date: Fri, 8 Mar 2019 17:10:36 +0800 Subject: [PATCH] =?UTF-8?q?=E5=AE=9E=E8=AE=AD=E8=B7=AF=E5=BE=84=E6=9D=83?= =?UTF-8?q?=E9=99=90=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/views/subjects/_subject_item.html.erb | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/app/views/subjects/_subject_item.html.erb b/app/views/subjects/_subject_item.html.erb index abcf0f11..d3ac4ebf 100644 --- a/app/views/subjects/_subject_item.html.erb +++ b/app/views/subjects/_subject_item.html.erb @@ -1,19 +1,19 @@ -<% result = User.current.is_certification_teacher || User.current.admin? %> +<% result = User.current.is_certification_teacher || User.current.member_of_subject?(subject) %> <% subjects.each do |subject| %>
<% if subject.repertoire.present? %>
<%= subject.repertoire.name %>
<% end %> - <% unless result %> + <% if subject.status < 2 && !result %>

暂未开发

<% end %> - " class="square-img" target="_blank"><%= image_tag(url_to_avatar(subject)) %> + " class="square-img" target="_blank"><%= image_tag(url_to_avatar(subject)) %>

- <%= link_to subject.name, "#{result ? subject_path(subject) : "javascript:void(0);"}", :class => "justify color-grey-name", :target => "_blank" %> + <%= link_to subject.name, "#{ result || subject.status >= 2 ? subject_path(subject) : "javascript:void(0);"}", :class => "justify color-grey-name", :target => "_blank" %>

<% if subject.stages_count > 0 %>