diff --git a/app/views/bids/_bid_homework_show.html.erb b/app/views/bids/_bid_homework_show.html.erb index 166a4b224..cd9b7b037 100644 --- a/app/views/bids/_bid_homework_show.html.erb +++ b/app/views/bids/_bid_homework_show.html.erb @@ -45,7 +45,13 @@ <% if User.current.logged? && is_cur_course_student(@course) %> <% cur_user_homework = cur_user_homework_for_bid(bid) %> <% if cur_user_homework!= nil && cur_user_homework.empty? %> - <%= link_to l(:label_commit_homework),new_exercise_book_path(bid) %> + <% if bid.comment_status == 0 || bid.comment_status == 2%> + <%= link_to l(:label_commit_homework),new_exercise_book_path(bid) %> + <% else %> + + <%= l(:label_commit_homework)%> + + <% end %> <% else %> <%= l(:lable_has_commit_homework)%> diff --git a/app/views/homework_attach/_homeworks_list.html.erb b/app/views/homework_attach/_homeworks_list.html.erb index c778588f7..c40004d02 100644 --- a/app/views/homework_attach/_homeworks_list.html.erb +++ b/app/views/homework_attach/_homeworks_list.html.erb @@ -35,13 +35,13 @@