Merge branch 'cxt_course' into develop
This commit is contained in:
commit
d212d4f4c5
|
@ -153,9 +153,9 @@
|
|||
<div>
|
||||
<% if activity.homework_type != 2 %>
|
||||
<% ids = student_work_scores.empty? ? "(-1)" : '('+student_work_scores.map{|sw|sw.student_work_id}.join(',')+')' %>
|
||||
<% student_works = activity.student_works.select("student_works.*,IF(final_score is null,null,final_score - absence_penalty - late_penalty) as score").where("student_works.id in #{ids}").order("score desc") %>
|
||||
<% student_works = activity.student_works.select("student_works.*,student_works.work_score as score").where("student_works.id in #{ids}").order("score desc") %>
|
||||
<% else %>
|
||||
<% student_works = activity.student_works.select("student_works.*,IF(final_score is null,null,final_score - absence_penalty - late_penalty) as score").order("score desc") %>
|
||||
<% student_works = activity.student_works.select("student_works.*,student_works.work_score as score").order("score desc") %>
|
||||
<% end %>
|
||||
<% student_works.each_with_index do |sw, i| %>
|
||||
<div class="fl mr10 w100" style="text-align:center;">
|
||||
|
|
|
@ -158,9 +158,9 @@
|
|||
<div>
|
||||
<% if activity.homework_type != 2 %>
|
||||
<% ids = student_work_scores.empty? ? "(-1)" : '('+student_work_scores.map{|sw|sw.student_work_id}.join(',')+')' %>
|
||||
<% student_works = activity.student_works.select("student_works.*,IF(final_score is null,null,final_score - absence_penalty - late_penalty) as score").where("student_works.id in #{ids}").order("score desc") %>
|
||||
<% student_works = activity.student_works.select("student_works.*,student_works.work_score as score").where("student_works.id in #{ids}").order("score desc") %>
|
||||
<% else %>
|
||||
<% student_works = activity.student_works.select("student_works.*,IF(final_score is null,null,final_score - absence_penalty - late_penalty) as score").order("score desc") %>
|
||||
<% student_works = activity.student_works.select("student_works.*,student_works.work_score as score").order("score desc") %>
|
||||
<% end %>
|
||||
<% student_works.includes(:user).each_with_index do |sw, i| %>
|
||||
<div class="fl mr10 w100" style="text-align:center;">
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
<div class="homepagePostBrief">
|
||||
<div class="homepagePostPortrait">
|
||||
<%= link_to image_tag(url_to_avatar(activity.author), :width => "50", :height => "50"), user_path(activity.author_id,:host=>Setting.host_user), :alt => "用户头像" %>
|
||||
<%#= render :partial => 'users/show_detail_info', :locals => {:user => activity.author} %>
|
||||
<%= render :partial => 'users/show_detail_info', :locals => {:user => activity.author} %>
|
||||
</div>
|
||||
<div class="homepagePostDes">
|
||||
<div class="homepagePostTo break_word mt-4">
|
||||
|
|
|
@ -162,9 +162,9 @@
|
|||
<div>
|
||||
<% if homework_common.homework_type != 2 %>
|
||||
<% ids = student_work_scores.empty? ? "(-1)" : '('+student_work_scores.map{|sw|sw.student_work_id}.join(',')+')' %>
|
||||
<% student_works = homework_common.student_works.select("student_works.*,IF(final_score is null,null,final_score - absence_penalty - late_penalty) as score").where("student_works.id in #{ids}").order("score desc") %>
|
||||
<% student_works = homework_common.student_works.select("student_works.*,student_works.work_score as score").where("student_works.id in #{ids}").order("score desc") %>
|
||||
<% else %>
|
||||
<% student_works = homework_common.student_works.select("student_works.*,IF(final_score is null,null,final_score - absence_penalty - late_penalty) as score").order("score desc") %>
|
||||
<% student_works = homework_common.student_works.select("student_works.*,student_works.work_score as score").order("score desc") %>
|
||||
<% end %>
|
||||
<% student_works.includes(:user).each_with_index do |sw, i| %>
|
||||
<div class="fl mr10 w100" style="text-align:center;">
|
||||
|
|
|
@ -26,6 +26,7 @@ function description_show_hide(id){
|
|||
//名片的显示
|
||||
function user_card_show_hide() {
|
||||
$(".homepagePostPortrait").mouseover(function(){
|
||||
$(".userCard").css("display","none");
|
||||
onImage = true;
|
||||
$(this).children(".userCard").css("display","block");
|
||||
});
|
||||
|
|
Loading…
Reference in New Issue