educoder/app/views/syllabuses/edit.html.erb

63 lines
4.8 KiB
Plaintext
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

<div class="edu-class-container" style="flex: 1 0 auto;">
<p class="mb10">
<i class="fa fa-map-marker mr5 color-grey"></i>
<%= link_to User.current.show_name, user_path(User.current) %> > <%= link_to '智能课堂', courses_path %>
</p>
<div class="edu-con-top ">
<p class="ml15 color-grey">编辑课程</p>
</div>
<div class="edu-con-bg01">
<div class="edu-class-con ">
<div class="alert alert-orange mb30 ">
<button data-dismiss="alert" class="task-close fr" type="button">×</button>
课程的核心是授课大纲,您可以为一门课程创建多个不同的班级
</div>
<div class="panel-form clearfix">
<%= labelled_form_for @syllabus, :html => {:id => 'edit_syllabus'} do |f| %>
<ul>
<li class="clearfix mb20">
<label class="panel-form-label label-w20 fl" ><span class="color-orange mr5">*</span>专业层级&nbsp;&nbsp;&nbsp;&nbsp;</label>
<%= select_tag :major_level,options_for_select(major_level_option,@syllabus.major_level), {:id=>"major_level", :class=>"fl task-height-40 task-form-80"} %>
<div class="cl"></div>
<span class="color-orange fl none" id="major_level_notice" style="margin-left:20%;"><i class="fa fa-exclamation-circle mr5" ></i>请选择课程所属专业层级</span>
</li>
<li class="clearfix mb20">
<label class="panel-form-label label-w20 fl" ><span class="color-orange mr5">*</span>学科门类&nbsp;&nbsp;&nbsp;&nbsp;</label>
<%= select_tag :discipline_category_id,options_for_select(discipline_category_option(@syllabus.major_level),@syllabus.discipline_category_id), {:id=>"discipline_category_id", :class=>"fl task-height-40 task-form-80"} %>
<div class="cl"></div>
<span class="color-orange fl none" id="discipline_category_id_notice" style="margin-left:20%;"><i class="fa fa-exclamation-circle mr5" ></i>请选择课程所属学科门类</span>
</li>
<li class="clearfix mb20">
<label class="panel-form-label label-w20 fl" ><span class="color-orange mr5">*</span>一级学科&nbsp;&nbsp;&nbsp;&nbsp;</label>
<%= select_tag :first_level_discipline_id,options_for_select(first_level_discipline_option(@syllabus.discipline_category_id),@syllabus.first_level_discipline_id), {:id=>"first_level_discipline_id", :class=>"fl task-height-40 task-form-80"} %>
<div class="cl"></div>
<span class="color-orange fl none" id="first_level_discipline_id_notice" style="margin-left:20%;"><i class="fa fa-exclamation-circle mr5" ></i>请选择课程所属一级学科</span>
</li>
<li class="clearfix mb20">
<label class="panel-form-label label-w20 fl" ><span class="color-orange mr5">*</span>课程名称&nbsp;&nbsp;&nbsp;&nbsp;</label>
<input type="text" name="title" maxlength="50" value="&nbsp;<%= @syllabus.title %>" id="new_syllabus_name" class="task-form-80 task-height-40 panel-box-sizing fl" placeholder=" 例如&nbsp;&nbsp;计算机基础">
<div class="cl"></div>
<span class="color-orange fl none" id="new_syllabus_name_notice" style="margin-left:20%;"><i class="fa fa-exclamation-circle mr5" ></i>课程名称不能为空且至少有两个字符</span>
<span class="color-orange fl none" id="new_syllabus_name_repeat_notice" style="margin-left:20%;"><i class="fa fa-exclamation-circle mr5" ></i>同一个用户不能创建同名课程</span>
</li>
<li class="clearfix mb20">
<label class="panel-form-label label-w20 fl" >英文名称&nbsp;&nbsp;&nbsp;&nbsp;</label>
<input type="text" name="eng_name" value="&nbsp;<%= @syllabus.eng_name %>" maxlength="100" id="new_syllabus_eng_name" class="task-form-80 task-height-40 panel-box-sizing fl" placeholder=" 例如&nbsp;&nbsp;Basis of Computer Engineering">
<div class="cl"></div>
</li>
<li class="clearfix mb20">
<label class="panel-form-label label-w20 fl" >课程性质&nbsp;&nbsp;&nbsp;&nbsp;</label>
<%= select_tag :syllabus_type,options_for_select(syllabus_type_option,@syllabus.syllabus_type), {:id=>"syllabus_type", :class=>"fl task-height-40 task-form-80"} %>
<div class="cl"></div>
</li>
<li class="clearfix" >
<a href="javascript:void(0);" class="task-btn task-btn-blue fr" onclick="submit_edit_syllabus('<%= @syllabus.id %>');">保存</a>
<%= link_to "取消",syllabus_path(@syllabus),:class => "task-btn fr mr10"%>
</li>
</ul>
<% end %>
</div>
</div>
</div>
</div>