2015-09-28 15:52:30 +08:00
|
|
|
<script type="text/javascript">
|
|
|
|
function reset_homework(){
|
|
|
|
$("#homework_name").val("");
|
|
|
|
$("#homework_end_time").val("");
|
|
|
|
$("#course_id").val($("#option_select").val());
|
|
|
|
$("#homework_attachments").html("<%= escape_javascript(render :partial => 'users/user_homework_attachment', :locals => { :container => HomeworkCommon.new,:has_program => true })%>");
|
|
|
|
homework_description_editor.html("");
|
|
|
|
$("#homework_editor").toggle();
|
|
|
|
}
|
2015-06-10 16:37:18 +08:00
|
|
|
|
2015-09-28 15:52:30 +08:00
|
|
|
$(function(){
|
|
|
|
$("#RSide").removeAttr("id");
|
|
|
|
$("#Container").css("width","1000px");
|
|
|
|
});
|
|
|
|
</script>
|
|
|
|
<style>
|
|
|
|
/*日历选择图*/
|
|
|
|
img.ui-datepicker-trigger {display:block;background:url(../images/public_icon.png) -31px 0 no-repeat;cursor: pointer;vertical-align: middle;width:16px;height:15px;float:left;margin: 7px;}
|
|
|
|
</style>
|
2015-06-30 10:18:46 +08:00
|
|
|
|
2015-09-28 15:52:30 +08:00
|
|
|
<div class="homepageRight mt0 ml10">
|
|
|
|
<div class="homepageRightBanner mb10">
|
|
|
|
<div class="NewsBannerName">作业</div>
|
|
|
|
</div>
|
|
|
|
<div class="cl"></div>
|
2015-07-17 17:59:42 +08:00
|
|
|
|
2015-09-28 15:52:30 +08:00
|
|
|
<% if @is_teacher%>
|
|
|
|
<!-- 老师身份才可以发布作业 -->
|
|
|
|
<div class="HomeWork mb10">
|
|
|
|
<%= labelled_form_for @new_homework,:url => user_new_homework_users_path,:method => "post" do |f| %>
|
|
|
|
<div id="HomeWorkCon">
|
|
|
|
<%= render :partial => 'users/user_homework_form', :locals => { :homework => @new_homework,:f => f,:edit_mode => false,:select_course => false } %>
|
2015-09-28 17:27:01 +08:00
|
|
|
<input type="hidden" name="is_in_course" value="1"/>
|
2015-07-24 15:19:01 +08:00
|
|
|
</div>
|
|
|
|
<% end%>
|
2015-09-28 15:52:30 +08:00
|
|
|
</div><!----HomeWork end-->
|
|
|
|
<% end%>
|
2015-06-03 09:59:15 +08:00
|
|
|
|
2015-09-28 17:27:01 +08:00
|
|
|
<%= render :partial => 'users/user_homework_list', :locals => {:homework_commons => @homeworks,:page => 0,:is_in_course => 1} %>
|
2015-09-28 15:52:30 +08:00
|
|
|
</div>
|
|
|
|
<div class="cl"></div>
|
2015-05-19 17:12:43 +08:00
|
|
|
|