实训课堂500问题

dev_shixuns
huang 6 years ago
parent 432fc2f415
commit e764011fca

@ -82,7 +82,10 @@
<%= link_to "开始实战", shixun_path(activity.homework_commons_shixuns.shixun), :class => 'edu-filter-btn edu-activity-blue ml15 fl mt5', :target => "_blank" %>
<% elsif work.present? %>
<% myshixun = Myshixun.where(:id => work.myshixun_id).first %>
<% is_modify = ShixunModify.where(:myshixun_id => myshixun.try(:id), :shixun_id => myshixun.shixun.try(:id), :status => 1).first %>
<% if myshixun.present? %>
<% is_modify = ShixunModify.where(:myshixun_id => myshixun.try(:id), :shixun_id => myshixun.shixun.try(:id), :status => 1).first %>
<% end %>
<% if myshixun && is_modify.blank? %>
<%= link_to "继续实战", myshixun_game_path(myshixun.current_task, :myshixun_id => myshixun), :class => "edu-filter-btn edu-activity-blue ml15 fl mt5", :target => "_blank" %>
<% elsif myshixun %>

Loading…
Cancel
Save