75 lines
3.9 KiB
Plaintext
75 lines
3.9 KiB
Plaintext
<%= content_for(:header_tags) do %>
|
|
<%= import_ke(enable_at: false, prettify: false, init_activity: true) %>
|
|
<% end %>
|
|
<script type="text/javascript">
|
|
$(function() {
|
|
sd_create_editor_from_data(<%= @syllabus.id %>, null, "100%", "<%= @syllabus.class.to_s %>");
|
|
showNormalImage('syllabus_description_<%= @syllabus.id %>');
|
|
$("#syllabus_description_<%= @syllabus.id%> p,#syllabus_description_<%= @syllabus.id%> span,#syllabus_description_<%= @syllabus.id%> em").each(function(){
|
|
var postContent = $(this).html();
|
|
postContent = postContent.replace(/ /g," ");
|
|
postContent= postContent.replace(/ {2}/g," ");
|
|
postContent=postContent.replace(/ /g," ");
|
|
postContent=postContent.replace(/ /g," ");
|
|
$(this).html(postContent);
|
|
});
|
|
autoUrl('syllabus_description_<%= @syllabus.id %>');
|
|
});
|
|
</script>
|
|
<ul id="sy_tab_nav">
|
|
<li id="sy_tab_nav_1" class="sy_tab_hover" onclick="HoverLi(1);">
|
|
<a href="javascript:void(0);" class="sy_tab_type" >课程大纲</a>
|
|
</li>
|
|
<li id="sy_tab_nav_2" onclick="HoverLi(2);">
|
|
<a href="javascript:void(0);" class="sy_tab_type" >班级列表</a>
|
|
</li>
|
|
<li id="sy_tab_nav_3" onclick="HoverLi(3);">
|
|
<a href="javascript:void(0);" class="sy_tab_type" >教师团队</a>
|
|
</li>
|
|
</ul>
|
|
<div id="sy_tab_con_1">
|
|
<% if User.current == @syllabus.user && @syllabus.courses.empty? %>
|
|
<p class="nodata c_red">您还没有创建班级,只有 <%= link_to "创建班级", new_course_path(:host=> Setting.host_course, :syllabus_id => @syllabus.id), :class => "linkBlue2", :target => '_blank'%> 后才可以开展在线教学哦~</p>
|
|
<% end %>
|
|
<% if @syllabus.des_status == 0 && User.current == @syllabus.user %>
|
|
<div class="icons_tishi"><img src="../images/sy/icons_tan.png" width="110" height="110" alt="" ></div>
|
|
<p class="sy_tab_con_p">您建立的课程尚未填写课程大纲,请完善您的 <%=link_to '课程大纲', edit_syllabus_path(@syllabus), :class => 'sy_corange' %>,谢谢啦!</p>
|
|
<% elsif @syllabus.des_status == 0 %>
|
|
<div class="icons_tishi"><img src="../images/sy/icons_tan.png" width="110" height="110" alt="" ></div>
|
|
<p class="sy_tab_con_p">该课程尚未填写课程大纲,敬请期待!</p>
|
|
<% else %>
|
|
<div class="sy_tab_con">
|
|
<div class="syllabuscon upload_img" id="syllabus_description_<%= @syllabus.id %>">
|
|
<%=@syllabus.description.html_safe %>
|
|
</div>
|
|
<div class="mt10" style="font-weight:normal; font-size: 12px;">
|
|
<%= render :partial=>"attachments/activity_attach", :locals=>{:activity => @syllabus} %>
|
|
</div>
|
|
<% if User.current.logged? && User.current == @syllabus.user%>
|
|
<div class="homepagePostSetting" style="margin:10px;">
|
|
<ul>
|
|
<li class="homepagePostSettingIcon">
|
|
<ul class="homepagePostSettiongText">
|
|
<li><%=link_to '编辑', edit_syllabus_path(@syllabus), :class => 'postOptionLink'%></li>
|
|
<li><%=link_to '删除', delete_des_syllabus_path(@syllabus), :class => 'postOptionLink', :confirm => l(:text_are_you_sure)%></li>
|
|
</ul>
|
|
</li>
|
|
</ul>
|
|
</div>
|
|
<div class="cl"></div>
|
|
<% end %>
|
|
<div class="fr fontGrey2">更新时间:<%=format_time @syllabus.updated_at %><div></div></div>
|
|
<div class="cl"></div>
|
|
</div><!--HomeWork end-->
|
|
<% end %>
|
|
|
|
<div class="homepagePostReply" style="margin-bottom: 20px;">
|
|
<div id="activity_post_reply_<%=@syllabus.id %>">
|
|
<%=render :partial => 'syllabuses/syllabus_post_reply', :locals => {:activity => @syllabus, :user_activity_id => @syllabus.id} %>
|
|
</div>
|
|
<div class="cl"></div>
|
|
</div><!--回复框 用正式版样式-->
|
|
</div><!--课程大纲 end-->
|
|
|
|
|