新建测验样式调整

This commit is contained in:
Tim 2015-11-25 15:02:32 +08:00
parent d1f16a0851
commit bd7ee66e77
3 changed files with 153 additions and 146 deletions

View File

@ -12,20 +12,6 @@
</div>
</li>
<% if exercise.exercise_status == 1%>
<li class="pollsbtn fl ml10 pollsbtn_grey">统计结果</li>
<% else %>
<li><%= link_to l(:label_statistical_results), student_exercise_list_exercise_path(exercise.id,:course_id => @course.id), :class => "pollsbtn fl ml10"%></li>
<% end%>
<% if exercise.exercise_status == 1 %>
<li><a href="javascript:" class="pollsbtn btn_pu fl ml5" onclick="exercise_submit(<%= exercise.id%>,<%= exercise.exercise_name.length %>);">发布试卷</a></li>
<% elsif exercise.exercise_status == 2%>
<li><a href="javascript:" class="pollsbtn btn_de fl ml5" onclick="republish_exercise(<%= exercise.id%>);">取消发布</a></li>
<% else%>
<li class="pollsbtn fl ml10 pollsbtn_grey" style="margin-left: 5px;" >发布试卷</li>
<% end%>
<%= link_to(l(:button_delete), exercise,:method => :delete, :confirm => l(:text_are_you_sure), :remote => true, :class => "polls_de fr ml5 mr10") %>
<% if exercise.exercise_status == 1 %>
@ -48,6 +34,22 @@
<li class="polls_date fr"><%= format_date exercise.created_at.to_date%></li>
<% if exercise.exercise_status == 1 %>
<li><a href="javascript:" class="pollsbtn btn_pu fr mr5" onclick="exercise_submit(<%= exercise.id%>,<%= exercise.exercise_name.length %>);">发布试卷</a></li>
<% elsif exercise.exercise_status == 2%>
<li><a href="javascript:" class="pollsbtn btn_de fr mr5" onclick="republish_exercise(<%= exercise.id%>);">取消发布</a></li>
<% else%>
<li class="pollsbtn fr mr10 pollsbtn_grey" style="margin-left: 5px;" >发布试卷</li>
<% end%>
<% if exercise.exercise_status == 1%>
<li class="pollsbtn fr mr10 pollsbtn_grey">统计结果</li>
<% else %>
<li><%= link_to l(:label_statistical_results), student_exercise_list_exercise_path(exercise.id,:course_id => @course.id), :class => "pollsbtn fr mr10"%></li>
<% end%>
<% else%>
<% if exercise.exercise_status == 2%>
<%# if has_commit%>

View File

@ -1,4 +1,4 @@
<div class="polls_head">
<div class="polls_head" style="width:730px;">
<h2>所有试卷
<span><%= @obj_count%></span>
</h2>

View File

@ -1,5 +1,10 @@
<%= stylesheet_link_tag 'polls', :media => 'all' %>
<script type="text/javascript">
$(function(){
$("#RSide").css("width","730px");
$("#homework_page_right").css("min-height",$("#LSide").height()-30);
$("#Container").css("width","1000px");
});
function republish_exercise(exercise_id)
{
$('#ajax-modal').html("<div id='popbox02'>" +
@ -58,6 +63,6 @@
}
</script>
<div class="polls_content02" id="exercise">
<div class="polls_content02" id="exercise" style="width: 730px;">
<%= render :partial => 'exercises_list'%>
</div><!--问卷内容end-->