From e42b6d65db0d575c74d30498c4af498c64fc0e2d Mon Sep 17 00:00:00 2001 From: sw <939547590@qq.com> Date: Wed, 2 Sep 2015 10:25:22 +0800 Subject: [PATCH] =?UTF-8?q?=E5=AF=BC=E5=85=A5=E4=BD=9C=E4=B8=9A=E4=B9=8B?= =?UTF-8?q?=E5=90=8E=E6=98=BE=E7=A4=BA=E6=89=80=E6=9C=89=E7=9A=84=E4=BD=9C?= =?UTF-8?q?=E4=B8=9A=E4=BF=A1=E6=81=AF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/views/users/user_homeworks.html.erb | 21 ++++++--------------- app/views/users/user_select_homework.js.erb | 1 + 2 files changed, 7 insertions(+), 15 deletions(-) diff --git a/app/views/users/user_homeworks.html.erb b/app/views/users/user_homeworks.html.erb index 3e2a0abe7..a935af2f5 100644 --- a/app/views/users/user_homeworks.html.erb +++ b/app/views/users/user_homeworks.html.erb @@ -12,16 +12,15 @@ } +
+
+
作业
+
+
+
<% if User.current.user_extensions && User.current.user_extensions.identity == 0 && User.current.allowed_to?(:add_course, nil, :global => true)%> -
-
-
发布作业
-
-
-
-
<% homework = HomeworkCommon.new %> <%= labelled_form_for homework,:url => user_new_homework_users_path,:method => "post" do |f| %> @@ -30,14 +29,6 @@
<% end%> - -<%else%> -
-
-
作业
-
-
-
<% end%> <%= render :partial => 'users/user_homework_list', :locals => {:homework_commons => @homework_commons,:page => 0} %> diff --git a/app/views/users/user_select_homework.js.erb b/app/views/users/user_select_homework.js.erb index 945da4c9a..a18fdacc8 100644 --- a/app/views/users/user_select_homework.js.erb +++ b/app/views/users/user_select_homework.js.erb @@ -5,3 +5,4 @@ $("#homework_end_time").val("<%= @homework.end_time%>"); $("#course_id").val("<%= @homework.course_id%>"); $("#homework_attachments").html("<%= escape_javascript(render :partial => 'users/user_homework_attachment', :locals => { :container => @homework })%>"); homework_description_editor.html("<%= escape_javascript(@homework.description.html_safe)%>"); +$("#homework_editor").show();