% if ma.course_message_type == "News" && ma.course_message %>
-
<%=link_to image_tag(url_to_avatar(ma.course_message.author), :width => "30", :height => "30"),user_path(ma.course_message.author), :target => '_blank' %>
-
<%=link_to ma.course_message.author.try(:show_name), user_path(ma.course_message.author), :class => "newsBlue homepageNewsPublisher", :target => '_blank' %>
发布了通知:
-
<%= link_to ma.course_message.title, {:controller => 'news', :action => 'show', :id => ma.course_message.id },
:class =>"#{ma.viewed == 0 ? "newsBlack" : "newsGrey"}",
:target => '_blank',
:title => "#{ma.course_message.title}"
%>
标题:<%= ma.course_message.title %>
<% unless ma.course_message.description.nil? %>
内容:
<%= ma.course_message.description.html_safe %>
<% end %>
- <%= time_tag(ma.created_at).html_safe %>
<% end %>
<% if ma.course_message_type == "Comment" && ma.course_message %>
-
<%=link_to image_tag(url_to_avatar(ma.course_message.author), :width => "30", :height => "30"), user_path(ma.course_message.author), :target => '_blank' %>
-
<%=link_to User.find(ma.course_message.author_id).show_name, user_path(ma.course_message.author), :class => "newsBlue homepageNewsPublisher", :target => '_blank' %>
评论了通知:
-
<%= link_to ma.course_message.commented.title, {:controller => 'news', :action => 'show', :id => ma.course_message.commented.id },
:class =>"#{ma.viewed == 0 ? "newsBlack" : "newsGrey"}" ,
:target => '_blank',
:title => "#{ma.course_message.commented.title}"
%>
评论对象:<%= ma.course_message.commented.title %>
<% unless ma.course_message.comments.nil? %>
评论内容:
<%= ma.course_message.comments.html_safe %>
<% end %>
- <%= time_tag(ma.created_at).html_safe %>
<% end %>
<% if ma.course_message_type == "HomeworkCommon" && ma.status.nil? && ma.course_message %>
-
<%=link_to image_tag(url_to_avatar(ma.course_message.user), :width => "30", :height => "30"), user_path(ma.course_message.user), :target => '_blank' %>
-
<%=link_to ma.course_message.user.lastname + ma.course_message.user.firstname + "老师", user_path(ma.course_message.user), :class => "newsBlue homepageNewsPublisher", :target => '_blank' %>
发布了班级作业:
-
<% if !User.current.allowed_to?(:as_teacher, ma.course_message.course) && cur_user_works_for_homework(ma.course_message).nil? %>
<%= link_to "作业标题:" + ma.course_message.name, new_student_work_path(:homework => ma.course_message.id),
:class =>"#{ma.viewed == 0 ? "newsBlack" : "newsGrey"}",
:target => '_blank',
:title => "作业标题:#{ma.course_message.name}"
%>
<% else %>
<%= link_to "作业标题:" + ma.course_message.name, student_work_index_path(:homework => ma.course_message.id),
:class => "#{ma.viewed == 0 ? "newsBlack" : "newsGrey"}",
:target => '_blank',
:title => "作业标题:#{ma.course_message.name}"
%>
<% end %>
<% if User.current.allowed_to?(:as_teacher,ma.course_message.course) %>
<%= User.current.lastname + User.current.firstname %>老师您好!
<%= User.current.eql?(ma.course_message.user)?"您":(ma.course_message.user.show_name + "老师")%>刚刚发布了一个作业:
- 班级名称:<%= ma.course_message.course.name %>
(<%= ma.course_message.course.time.to_s + '年'+ ma.course_message.course.term %>)
- 作业标题:<%= ma.course_message.name %>
- 发布时间:<%= DateTime.parse(ma.course_message.created_at.to_s).strftime('%Y-%m-%d %H:%M').to_s %>
- 提交截止:<%= ma.course_message.end_time %> 23:59
- 匿评开始:<%= ma.course_message.homework_detail_manual.evaluation_start %> 23:59
- 匿评关闭:<%= ma.course_message.homework_detail_manual.evaluation_end %> 23:59
- 迟交扣分:<%= ma.course_message.late_penalty %>分
- 缺评扣分:<%= ma.course_message.homework_detail_manual.absence_penalty %>分
您可以修改作业内容、评分规则、匿评过程等,谢谢!
<% else %>
<%= User.current.lastname + User.current.firstname %>同学您好!<%= ma.course_message.user.lastname + ma.course_message.user.firstname %>老师刚刚发布了一个作业:
- 班级名称:<%= ma.course_message.course.name %>
(<%= ma.course_message.course.time.to_s + '年'+ ma.course_message.course.term %>)
- 作业标题:<%= ma.course_message.name %>
- 提交截止:<%= ma.course_message.end_time %> 23:59
- 匿评开始:<%= ma.course_message.homework_detail_manual.evaluation_start %> 23:59
- 匿评关闭:<%= ma.course_message.homework_detail_manual.evaluation_end %> 23:59
- 迟交扣分:<%= ma.course_message.late_penalty %>分
- 缺评扣分:<%= ma.course_message.homework_detail_manual.absence_penalty %>分
请抓紧时间提交您的作品,谢谢!
<% end %>
- <%= time_tag(ma.created_at).html_safe %>
<% end %>
<% if ma.course_message_type == "HomeworkCommon" && ma.status == 1 && ma.course_message %>
-
<%=link_to image_tag(url_to_avatar(ma.course_message.user), :width => "30", :height => "30"), user_path(ma.course_message.user), :target => '_blank' %>
-
<%=link_to ma.course_message.user.lastname + ma.course_message.user.firstname + '老师',
user_path(ma.course_message.user),
:class => "newsBlue homepageNewsPublisher",
:title => "#{ma.course_message.user.lastname + ma.course_message.user.firstname}老师",
:target => '_blank' %>
发布的作业:
-
<%= link_to "作业标题:" + ma.course_message.name, student_work_index_path(:homework => ma.course_message.id),
:class => "#{ma.viewed == 0 ? "newsBlack" : "newsGrey"}",
:target => '_blank',
:title => "作业标题:#{ma.course_message.name}"
%>
<% if !User.current.allowed_to?(:as_teacher,ma.course_message.course) %>
<%= User.current.lastname + User.current.firstname %>同学您好!
<%= ma.course_message.user.lastname + ma.course_message.user.firstname %>老师发布的作业截止日期快到了:
- 班级名称:<%= ma.course_message.course.name %>(<%= ma.course_message.course.time.to_s + '年'+ ma.course_message.course.term %>)
- 作业标题:<%= ma.course_message.name %>
- 提交截止:<%= ma.course_message.end_time %> 23:59
- 匿评开始:<%= ma.course_message.homework_detail_manual.evaluation_start %> 23:59
- 匿评关闭:<%= ma.course_message.homework_detail_manual.evaluation_end %> 23:59
- 迟交扣分:<%= ma.course_message.late_penalty %>分
- 缺评扣分:<%= ma.course_message.homework_detail_manual.absence_penalty %>分
请抓紧时间提交您的作品,谢谢!
<% end %>
- 截止时间快到啦
- <%= time_tag(ma.created_at).html_safe %>
<% end %>
<% if ma.course_message_type == "HomeworkCommon" && ma.status == 2 && ma.course_message %>
-
<%= link_to image_tag(url_to_avatar(ma.course_message.user), :width => "30", :height => "30"), user_path(ma.course_message.user), :target => '_blank' %>
-
<%= link_to ma.course_message.user.show_name + "老师",
user_path(ma.course_message.user), :class => "newsBlue homepageNewsPublisher", :target => '_blank' %>
启动了作业匿评:
-
<%= link_to "作业标题:" + ma.course_message.name, student_work_index_path(:homework => ma.course_message.id), :class => "#{ma.viewed == 0 ? "newsBlack" : "newsGrey"}",
:onmouseover => "message_titile_show($(this),event)",
:onmouseout => "message_titile_hide($(this))", :target => '_blank' %>
<%= User.current.lastname + User.current.firstname %><%= User.current.allowed_to?(:as_teacher,ma.course_message.course) ? '老师' : '同学' %>您好!
<%= User.current.eql?(ma.course_message.user)?"您":(ma.course_message.user.lastname + ma.course_message.user.firstname+"老师") %>开启了匿评,作业详情如下:
- 班级名称:<%= ma.course_message.course.name %>(<%= ma.course_message.course.time.to_s + '年'+ ma.course_message.course.term %>)
- 作业标题:<%= ma.course_message.name %>
- 缺评扣分:<%= ma.course_message.homework_detail_manual.absence_penalty %>分
- 匿评截止:<%= ma.course_message.homework_detail_manual.evaluation_end %> 23:59
<% unless User.current.allowed_to?(:as_teacher, ma.course_message.course)%>
请您尽早完成匿评,如果您在截止日期前未完成匿评,您的最终成绩将被扣除<%= ma.course_message.homework_detail_manual.absence_penalty %>分乘以缺评份数。
例如,您缺评了两份作品,则您的最终成绩将被扣除 <%= ma.course_message.homework_detail_manual.absence_penalty %> * 2 = <%= ma.course_message.homework_detail_manual.absence_penalty * 2 %>分
<% end%>
- <%= time_tag(ma.created_at).html_safe %>
<% end %>
<% if ma.course_message_type == "HomeworkCommon" && ma.status == 3 && ma.course_message %>
-
<%= link_to image_tag(url_to_avatar(ma.course_message.user), :width => "30", :height => "30"), user_path(ma.course_message.user), :target => '_blank' %>
-
<%=link_to ma.course_message.user.lastname + ma.course_message.user.firstname + "老师",
user_path(ma.course_message.user), :class => "newsBlue homepageNewsPublisher", :target => '_blank' %>
关闭了作业匿评:
-
<%= link_to "作业标题:" + ma.course_message.name, student_work_index_path(:homework => ma.course_message.id), :class =>"#{ma.viewed == 0 ? "newsBlack" : "newsGrey"}", :target => '_blank' %>
<%= User.current.lastname + User.current.firstname %><%= User.current.allowed_to?(:as_teacher,ma.course_message.course) ? '老师':'同学'%>您好!
该作业已经关闭了匿评。作业信息如下:
- 班级名称:<%= ma.course_message.course.name %>(<%= ma.course_message.course.time.to_s + '年'+ ma.course_message.course.term %>)
- 作业标题:<%= ma.course_message.name %>
注:缺省情况下,系统将在作业提交截止日期后14天自动关闭匿评。
<% if User.current.allowed_to?(:as_teacher,ma.course_message.course)%>
祝您的教学活动高效、顺利、愉快!
<% end %>
- <%= time_tag(ma.created_at).html_safe %>
<% end %>
<% if ma.course_message_type == "HomeworkCommon" && ma.status == 4 && ma.course_message %>
-
<%= link_to image_tag(url_to_avatar(ma.course_message.user), :width => "30", :height => "30"), user_path(ma.course_message.user), :target => '_blank' %>
-
<%= link_to ma.course_message.user.lastname + ma.course_message.user.firstname + "老师",
user_path(ma.course_message.user), :class => "newsBlue homepageNewsPublisher", :target => '_blank' %>
启动作业匿评失败:
-
<%= link_to truncate(ma.course_message.name,:length=>25)+'(失败原因:提交作品的人数低于2人)', student_work_index_path(:homework => ma.course_message.id),
:class => "#{ma.viewed == 0 ? "c_red" : "newsGrey "}",
:target => '_blank',
:title => "#{truncate(ma.course_message.name,:length=>25)}(失败原因:提交作品的人数低于2人)"
%>
<%= User.current.lastname + User.current.firstname %><%= User.current.allowed_to?(:as_teacher, ma.course_message.course) ? '老师':'同学'%>您好!
<%= User.current.eql?(ma.course_message.user) ?"您":(ma.course_message.user.lastname + ma.course_message.user.firstname + "老师") %>启动作业匿评失败啦
- 班级名称:<%= ma.course_message.course.name %>(<%= ma.course_message.course.time.to_s + '年' + ma.course_message.course.term %>)
- 作业标题:<%= ma.course_message.name %>
- 提交截止:<%= ma.course_message.end_time%> 23:59
- <%= time_tag(ma.created_at).html_safe %>
<% end %>
<% if ma.course_message_type == "HomeworkCommon" && ma.status == 5 %>
<%= render :partial => 'apply_homework_course_message', :locals => {:ma => ma} %>
<% end %>
<% if ma.course_message_type == "ApplyResource" && ma.status == 0 && ma.course_message %>
<%= render :partial => 'apply_resource_course_message', :locals => {:ma => ma} %>
<% end %>
<% if ma.course_message_type == "ApplyResource" && ma.status == 1 && ma.course_message %>
<%= render :partial => 'apply_resource_course_message_reply', :locals => {:ma => ma} %>
<% end %>
<% if ma.course_message_type == "HomeworkCommon" && ma.status == 6 && ma.course_message %>
-
<%= image_tag(url_to_avatar(User.find(ma.apply_user_id)), width: "30px", height: "30px", class: "mt3") %>
-
<%= link_to ma.course_message.user.try(:show_name),
user_path(ma.course_message.user), :class => "newsBlue homepageNewsPublisher", :target => '_blank' %>
<%= ma.apply_result == 1 ? '同意' : '拒绝'%>引用作业:
-
<% link_str = ma.apply_result == 1 ?
'您申请引用作业"'+HomeworkCommon.find(ma.course_message_id).name+'"的申请已通过'
:
'您申请引用作业"'+HomeworkCommon.find(ma.course_message_id).name+'"的申请被拒绝' %>
<% if User.current.member_of_course?(ma.course_message.course) || User.current.admin? || (ma.course_message.is_open == 1 && ma.course_message.course.is_public == 1) %>
<%= link_to link_str, student_work_index_path(:homework => ma.course_message.id), :title => link_str,:class => "#{ma.viewed == 0 ? "newsBlack" : "newsGrey "}", :target => '_blank' %>
<% else %>
<%= link_str %>
<% end %>
- <%= time_tag(ma.created_at).html_safe %>
<% end %>
<% if ma.course_message_type == "Poll" && ma.course_message %>
-
<%= link_to image_tag(url_to_avatar(ma.course_message.user), :width => "30", :height => "30"), user_path(ma.course_message.user), :target => '_blank' %>
-
<%= link_to ma.course_message.user.try(:show_name), user_path(ma.course_message.user), :class => "newsBlue homepageNewsPublisher", :target => '_blank' %>
发布了问卷:
-
<%= link_to format_activity_title(" #{ma.course_message.polls_name.nil? ? "未命名问卷" : ma.course_message.polls_name}"), poll_path(ma.course_message.id),
:class=>"#{ma.viewed==0?"newsBlack":"newsGrey"}", :target => '_blank' %>
<%= ma.course_message.polls_name %>
- <%= time_tag(ma.created_at).html_safe %>
<% end %>
<% if ma.course_message_type == "Message" && !ma.nil? && !ma.course_message.nil? %>
-
<%=link_to image_tag(url_to_avatar(ma.course_message.author), :width => "30", :height => "30"), user_path(ma.course_message.author), :target => '_blank' %>
-
<%=link_to ma.course_message.author.try(:show_name), user_path(ma.course_message.author), :class => "newsBlue homepageNewsPublisher", :target => '_blank' %>
<%= ma.course_message.parent_id.nil? ? "发布了班级帖子:" : "评论了班级帖子:" %>
<% if ma.course_message.parent_id.nil? %>
-
<%= link_to ma.course_message.subject, board_message_path(ma.course_message.board_id, ma.course_message.id),
:class => "#{ma.viewed==0 ? "newsBlack" : "newsGrey"}",
:target => '_blank',
:title => "#{ma.course_message.subject}"
%>
主题:<%= ma.course_message.subject %>
<% unless ma.course_message.content.nil? %>
内容:
<%= ma.course_message.content.html_safe %>
<% end %>
<% else %>
-
<%= link_to message_content(ma.course_message.content), board_message_path(ma.course_message.board_id, ma.course_message.parent_id),
:class => "#{ma.viewed==0 ? "newsBlack" : "newsGrey"}", :target => '_blank' %>
主题:<%= ma.course_message.subject %>
<% unless ma.course_message.content.nil? %>
内容:
<%= ma.course_message.content.html_safe %>
<% end %>
<% end %>
- <%= time_tag(ma.created_at).html_safe %>
<% end %>
<% if ma.course_message_type == "StudentWorksScore" && ma.course_message %>
-
<% if ma.course_message.reviewer_role == 3 %>
<%= link_to image_tag(url_to_avatar(""), :width => "30", :height => "30"),"javascript:void(0);", :target => '_blank' %>
<% else %>
<%= link_to image_tag(url_to_avatar(ma.course_message.user), :width => "30", :height => "30"), user_path(ma.course_message.user), :target => '_blank' %>
<% end %>
-
<% if ma.course_message.reviewer_role == 3 %>
匿名用户
<% else %>
<%= link_to ma.course_message.user.lastname + ma.course_message.user.firstname + "老师",
user_path(ma.course_message.user), :class => "newsBlue homepageNewsPublisher", :target => '_blank' %>
<% end %>
<%= ma.status == 0 ? "评阅了您的作品:" : "重新评阅了您的作品:" %>
-
<% unless ma.content.nil? %>
<%= link_to message_content(ma.content), student_work_index_path(:homework => ma.course_message.student_work.homework_common_id),
:class =>"#{ma.viewed == 0 ? "newsBlack" : "newsGrey"}", :target => '_blank' %>
<%= User.current.show_name %>同学您好!
<%= ma.course_message.reviewer_role == 3? "匿名用户" : (ma.course_message.user.show_name + "老师")%>
<%= ma.status == 0? "评阅了您的作品" : "重新评阅了您的作品" %>。详情如下:
- 班级名称:<%= ma.course.name %>(<%= ma.course.time.to_s + '年'+ ma.course.term %>)
- 作业标题:<%=ma.course_message.student_work.homework_common.name %>
<% content = ma.content.gsub("作业评分:","").split(" 评语:")%>
- 作品评分:<%= content[0] %>分
<% if content.size > 1 %>
- 作品评语:
<%= content[1] %>
<% end %>
本次作业将在<%= ma.course_message.student_work.homework_common.homework_detail_manual.evaluation_end %> 23:59结束匿评,到时您将可以看到所有其他同学的作品啦!大家可以进一步互相学习。 期待您取得更大的进步!
<% end %>
- <%= time_tag(ma.created_at).html_safe %>
<% end %>
<% if ma.course_message_type == "JournalsForMessage" && ma.course_message %>
<% if ma.course_message.jour_type == 'Course' %>
<% if params[:type] != 'homework' %>
-
<%= link_to image_tag(url_to_avatar(ma.course_message.user), :width => "30", :height => "30"), user_path(ma.course_message.user), :target => '_blank' %>
-
<%= link_to ma.course_message.user.try(:show_name), user_path(ma.course_message.user), :class => "newsBlue homepageNewsPublisher", :target => '_blank' %>
在班级中留言了:
-
<%= link_to message_content(ma.course_message.notes), course_feedback_path(:id => ma.course_id),
:class => "#{ma.viewed == 0 ? "newsBlack" : "newsGrey"}", :target => '_blank' %>
<%= ma.course_message.notes.html_safe %>
- <%= time_tag(ma.created_at).html_safe %>
<% end %>
<% elsif ma.course_message.jour_type == 'HomeworkCommon' %>
-
<%= link_to image_tag(url_to_avatar(ma.course_message.user), :width => "30", :height => "30"), user_path(ma.course_message.user), :target => '_blank' %>
-
<%= link_to ma.course_message.user.try(:show_name), user_path(ma.course_message.user), :class => "newsBlue homepageNewsPublisher", :target => '_blank' %>
<% if ma.course_message.m_parent_id.nil? %>
回复了您的作业:
<% else %>
在作业中回复了您:
<% end %>
-
<%= link_to message_content(ma.course_message.notes), homework_common_index_url_in_org( ma.course_id),
:class => "#{ma.viewed == 0 ? "newsBlack" : "newsGrey"}", :target => '_blank' %>
<%= ma.course_message.notes.html_safe %>
- <%= time_tag(ma.created_at).html_safe %>
<% else %>
-
<% show_name = ma.course_message.jour.reviewer_role != 3 || ma.course_message.user.allowed_to?(:as_teacher, ma.course) %>
<%= link_to image_tag(url_to_avatar(show_name ? ma.course_message.user : ""), :width => "30", :height => "30"), show_name ? user_path(ma.course_message.user) : "javascript:void(0)", :target => '_blank' %>
-
<%= link_to show_name ? ma.course_message.user.show_name + "#{ma.course_message.user.allowed_to?(:as_teacher, ma.course)?"老师":"同学"}" : "匿名用户",
show_name ? user_path(ma.course_message.user) : "javascript:void(0)", :class => "newsBlue homepageNewsPublisher", :target => '_blank' %>
回复了作品评论:
-
<%= link_to message_content(ma.course_message.notes),
student_work_index_path(:homework => ma.course_message.jour.student_work.homework_common_id,:show_work_id => ma.course_message.jour.student_work_id),
:class => "#{ma.viewed == 0 ? "newsBlack" : "newsGrey"}",
:target => '_blank' %>
<%= User.current.show_name %>老师您好!
<%= User.find(ma.course_message.user).show_name %>
<%= ma.course_message.user.allowed_to?(:as_teacher, ma.course)?"老师":"同学"%>回复了您的作品评论。详情如下:
- 回复内容:<%= ma.course_message.notes %>
- 您的评论:<%= ma.course_message.jour.comment %>
- 班级名称:<%= ma.course.name %>(<%= ma.course.time.to_s + '年'+ ma.course.term %>)
- 作业标题:<%=ma.course_message.jour.student_work.homework_common.name %>
- <%= time_tag(ma.created_at).html_safe %>
<% end %>
<% end %>
<% if ma.course_message_type == "StudentWork" && !ma.course_message.nil? && !ma.course_message.homework_common.nil? && !User.current.allowed_to?(:as_teacher, ma.course_message.homework_common.course) && ma.course_message %>
-
<%= link_to image_tag(url_to_avatar(ma.course_message.homework_common.user), :width => "30", :height => "30"), user_path(ma.course_message.homework_common.user), :target => '_blank' %>
-
<%=link_to ma.course_message.homework_common.user.show_name+"老师", user_path(ma.course_message.homework_common.user), :class => "newsBlue homepageNewsPublisher", :target => '_blank' %>
发布的作业:
-
<%= link_to "作业标题:" + ma.course_message.homework_common.name, student_work_index_path(:homework => ma.course_message.homework_common_id),
:class => "#{ma.viewed==0 ? "newsBlack" : "newsGrey"}", :target => '_blank' %>
<%= User.current.lastname + User.current.firstname %>
<%= User.current.allowed_to?(:as_teacher,ma.course_message.homework_common.course) ? '老师':'同学'%>您好!由于迟交作业,您及您的作品都不能参与以下作业的匿评。作业详情如下:
- 班级名称:<%= ma.course_message.homework_common.course.name %>(<%= ma.course_message.homework_common.course.time.to_s + '年' + ma.course_message.homework_common.course.term %>)
- 作业标题:<%= ma.course_message.homework_common.name %>
- 提交截止:<%= ma.course_message.homework_common.end_time %> 23:59
- 提交时间:<%= format_time(ma.course_message.created_at) %>
- 迟交扣分:<%= ma.course_message.homework_common.late_penalty %>分
如需获得最终成绩,请您联系主讲老师对您的作品进行单独评分!
- 迟交作品
- <%= time_tag(ma.created_at).html_safe %>
<% end %>
<% if ma.course_message_type == "StudentWork" && ma.status == 1 && ma.course_message %>
-
<%= link_to image_tag(url_to_avatar(ma.course_message.user), :width => "30", :height => "30"), user_path(ma.course_message.user), :target => '_blank' %>
-
<%= link_to ma.course_message.user.lastname + ma.course_message.user.firstname + "同学",
user_path(ma.course_message.user), :class => "newsBlue homepageNewsPublisher", :target => '_blank' %>
重新提交了作品:
-
<%= link_to "作业标题:" + ma.course_message.name, student_work_index_path(:homework => ma.course_message.homework_common_id, :show_work_id => ma.course_message_id, :tab => 2),
:class =>"#{ma.viewed == 0 ? "newsBlack" : "newsGrey"}", :target => '_blank' %>
<%#= link_to truncate(ma.course_message.name,:length=>25)+'(失败原因:提交作品的人数低于2人)', student_work_index_path(:homework => ma.course_message.id), :class => "#{ma.viewed == 0 ? "c_red" : "newsGrey "}" %>
- <%= time_tag(ma.created_at).html_safe %>
<% end %>
<% if ma.course_message_type == "StudentWork" && ma.status == 2 && ma.course_message %>
-
<%= link_to image_tag(url_to_avatar(ma.course_message.user), :width => "30", :height => "30"), user_path(ma.course_message.user), :target => '_blank' %>
-
<%= link_to ma.course_message.user.show_name+ "同学",
user_path(ma.course_message.user), :class => "newsBlue homepageNewsPublisher", :target => '_blank' %>
追加新附件了:
-
<%= link_to "作业标题:" + ma.course_message.homework_common.name, student_work_index_path(:homework => ma.course_message.homework_common_id, :show_work_id => ma.course_message_id, :tab => 2),
:class =>"#{ma.viewed == 0 ? "newsBlack" : "newsGrey"}", :target => '_blank' %>
- <%= time_tag(ma.created_at).html_safe %>
<% end %>
<% if ma.course_message_type == "StudentWorksScoresAppeal" && ma.course_message %>
-
<%=link_to image_tag(url_to_avatar(""), :width => "30", :height => "30"), "javascript:void(0);", :target => '_blank' %>
-
<% if ma.status == 1 %>
匿名用户
<% elsif ma.status == 3 || ma.status == 4 %>
<% deal_user = User.find ma.apply_result %>
<%= link_to deal_user.show_name, user_path(deal_user), :class => "newsBlue homepageNewsPublisher", :target => '_blank' %>
<% end %>
">
<% if ma.status == 1 %>
对您的评阅发起申诉:
<% elsif ma.status == 3 %>
接受申诉:
<% elsif ma.status == 4 %>
拒绝申诉:
<% end %>
-
<%= link_to ma.course_message.student_works_score.student_work.homework_common.name, student_work_index_path(:homework => ma.course_message.student_works_score.student_work.homework_common_id, :show_work_id => ma.course_message.student_works_score.student_work_id, :tab => 2),
:class =>"#{ma.viewed == 0 ? "newsBlack" : "newsGrey"}", :target => '_blank' %>
- <%= time_tag(ma.created_at).html_safe %>
<% end %>
<% if ma.course_message_type == "Course" && ma.course_message %>
-
<%= image_tag("/images/trustie_logo1.png", width: "30px", height: "30px", class: "mt3") %>
-
系统提示
您成功创建了班级:
-
<%= link_to "班级名称:" + ma.course_message.name, course_path(ma.course_message),
:class => "#{ma.viewed==0 ? "newsBlack" : "newsGrey"}", :target => '_blank' %>
<%= User.current.lastname + User.current.firstname %>老师您好!您成功创建了一个班级,详情如下:
班级名称:<%= ma.course_message.name %>
开课学期:<%= ma.course_message.time.to_s + '年' + ma.course_message.term %>
班级ID:<%= ma.course_message.id %>
班级密码:<%= ma.course_message.password %>
学时总数:<%= ma.course_message.class_period %>
创建时间:<%= format_time(ma.course_message.created_at) %>
您可以点击左上角的“配置”按钮,修改班级基本信息,添加及删除班级成员。您也可以把邀请码告诉学生和其他成员,让他们输入邀请码加入班级。
<% if ma.course_message.is_public %>
您的班级是公开的,所有人都能访问您的班级。若不想设置为公开,您可以在配置中设置。
<% else %>
您的班级是私有的,非班级成员不能访问您的班级。如果想设置为公开,您可以在配置中设置。
<% end %>
- <%= time_tag(ma.created_at).html_safe %>
<% end %>
<% if ma.course_message_type == "JoinCourseRequest" && !ma.nil? %>
<%= render :partial => 'join_course_course_message', :locals => {:ma => ma} %>
<% end %>
<% if ma.course_message_type == "CourseRequestDealResult" %>
-
<%= link_to image_tag(url_to_avatar(User.find(ma.user_id)), :width => "30", :height => "30"), user_path(User.find(ma.user_id)), :target => '_blank' %>
-
<%=link_to User.find(ma.user_id).show_name, user_path(User.find(ma.user_id)),
:class => "newsBlue homepageNewsPublisher", :target => '_blank' %>
申请以“<%= ma.content.include?('9') ? '教师' : '教辅' %>”身份加入:
-
<%= link_to Course.find(ma.course_id).name, course_path(Course.find(ma.course_id)),
:class => "#{ma.viewed==0 ? "newsBlack" : "newsGrey"}", :target => '_blank' %>
-
<% if ma.status == 1 %>
<%= User.find(ma.course_message_id).show_name %>已通过
<% else %>
<%= User.find(ma.course_message_id).show_name %>已拒绝
<% end %>
- <%= time_tag(ma.created_at).html_safe %>
<% end %>
<% if ma.course_message_type == "JoinCourse" and ma.status == 0 %>
-
<%= link_to image_tag(url_to_avatar(User.find(ma.course_message_id)), :width => "30", :height => "30"), user_path(ma.course_message_id), :target => '_blank' %>
-
<%=link_to User.find(ma.course_message_id).show_name, user_path(User.find(ma.course_message_id)), :class => "newsBlue homepageNewsPublisher", :target => '_blank' %>
将您加入了班级:
-
<%= link_to ma.course.name, course_member_path(ma.course), :class => "#{ma.viewed == 0 ? "newsBlack" : "newsGrey"}", :target => '_blank' %>
<% if ma.course.is_public? || User.current.member_of_course?(ma.course) || User.current.admin? %>
<% teacher = User.find(ma.course_message_id) %>
<%= teacher.show_name %>(<%= teacher %>)老师把您加入了班级,详情如下:
班级名称:<%= ma.course.name %>
开课学期:<%= ma.course.time.to_s + '年'+ ma.course.term %>
班级ID:<%= ma.course.id %>
课时总数:<%= ma.course.class_period %>
<% else %>
您已经被移出该私有班级,非班级成员没有权限访问私有班级
<% end %>
- <%= time_tag(ma.created_at).html_safe %>
<% end %>
<% if ma.course_message_type == "JoinCourse" and ma.status == 1 %>
-
<%= image_tag("/images/trustie_logo1.png", width: "30px", height: "30px", class: "mt3") %>
-
系统提示
您增加了新的班级成员:
-
<%= link_to User.find(ma.course_message_id).login + "(" + (User.find(ma.course_message_id).show_name) +")",
{:controller => 'courses', :action => 'settings', :id => ma.course_id, :tab => 'member'},
:class => "#{ma.viewed == 0 ? "newsBlack" : "newsGrey"}",
:target => '_blank' %>
<% if ma.course.is_public? || User.current.member_of_course?(ma.course) || User.current.admin? %>
您增加了新的班级成员,详情如下:
成员:<%= User.find(ma.course_message_id).login+"("+(User.find(ma.course_message_id).realname ? User.find(ma.course_message_id).realname : User.find(ma.course_message_id).login) +")" %>
班级名称:<%= ma.course.name %>
开课学期:<%= ma.course.time.to_s + '年'+ ma.course.term %>
班级ID:<%= ma.course.id %>
课时总数:<%= ma.course.class_period %>
<% else %>
您已经被移出该私有班级,非班级成员没有权限访问私有班级
<% end %>
- <%= time_tag(ma.created_at).html_safe %>
<% end %>
<% if ma.course_message_type == "RemoveFromCourse" %>
-
<%=link_to image_tag(url_to_avatar(User.find(ma.course_message_id)), :width => "30", :height => "30"), user_path(ma.course_message_id), :target => '_blank' %>
-
<%=link_to User.find(ma.course_message_id).show_name, user_path(User.find(ma.course_message_id)), :class => "newsBlue homepageNewsPublisher", :target => '_blank' %>
将您移出了班级:
-
<%= link_to ma.course.name, member_course_path(ma.course), :class => "#{ma.viewed == 0 ? "newsBlack" : "newsGrey"}", :target => '_blank' %>
<% if ma.course.is_public? || User.current.member_of?(ma.course) || User.current.admin? %>
您已被<%= User.find(ma.course_message_id).show_name %>老师移出了班级,详情如下:
班级名称:<%= ma.course.name %>
开课学期:<%= ma.course.time.to_s + '年'+ ma.course.term %>
<% if !ma.content.nil? %>
担任角色:<%= ma.content %>
<% end %>
学时总数:<%= ma.course.class_period %>
<% else %>
您已经被移出该私有班级,非班级成员没有权限访问私有班级
<% end %>
- <%= time_tag(ma.created_at).html_safe %>
<% end %>
<% if ma.course_message_type == "Exercise" && ma.status == 2 && ma.course_message %>
-
<%=link_to image_tag(url_to_avatar(ma.course_message.user), :width => "30", :height => "30"), user_path(ma.course_message.user), :target => '_blank' %>
-
<%=link_to ma.course_message.user.lastname + ma.course_message.user.firstname + "老师",
user_path(ma.course_message.user), :class => "newsBlue homepageNewsPublisher", :target => '_blank' %>
发布了班级测验:
-
<%= link_to "测验题目:" + ma.course_message.exercise_name, exercise_path(:id => ma.course_message.id), :class =>"#{ma.viewed == 0 ? "newsBlack" : "newsGrey"}", :target => '_blank' %>
<%= User.current.lastname + User.current.firstname %><%= User.current.allowed_to?(:as_teacher,ma.course_message.course) ? '老师':'同学'%>您好!
<%= User.current.eql?(ma.course_message.user)?"您":(ma.course_message.user.lastname + ma.course_message.user.firstname+"老师") %>发布了班级测验 ,测验详情如下:
- 班级名称:<%= ma.course_message.course.name %>(<%= ma.course_message.course.time.to_s + '年'+ ma.course_message.course.term %>)
- 测验标题:<%= ma.course_message.exercise_name %>
- 截止时间:<%= ma.course_message.end_time.to_s.gsub("+0800","").to_datetime.strftime("%Y-%m-%d %H:%M:%S") %>
- 答题时长:<%= ma.course_message.time == -1 ? '不限时' : ma.course_message.time.to_s + '分钟' %>
<% if !User.current.allowed_to?(:as_teacher,ma.course_message.course)%>
请记得在截止时间前完成测验噢,辛苦啦!
<% end %>
- <%= time_tag(ma.created_at).html_safe %>
<% end %>
<% if ma.course_message_type == "Exercise" && ma.status == 3 && ma.course_message %>
-
<%=link_to image_tag(url_to_avatar(ma.course_message.user), :width => "30", :height => "30"), user_path(ma.course_message.user), :target => '_blank' %>
-
<%= link_to ma.course_message.user.lastname + ma.course_message.user.firstname + "老师",
user_path(ma.course_message.user), :class => "newsBlue homepageNewsPublisher", :target => '_blank' %>
发布的测验:
-
<%= link_to "测验题目:" + ma.course_message.exercise_name, exercise_path(:id => ma.course_message.id), :class =>"#{ma.viewed == 0 ? "newsBlack" : "newsGrey"}", :target => '_blank' %>
<%= User.current.lastname + User.current.firstname %><%= User.current.allowed_to?(:as_teacher,ma.course_message.course) ? '老师':'同学'%>您好!
<%= User.current.eql?(ma.course_message.user)?"您":(ma.course_message.user.lastname + ma.course_message.user.firstname+"老师") %>发布的班级测验截止时间快到了,测验详情如下:
- 班级名称:<%= ma.course_message.course.name %>(<%= ma.course_message.course.time.to_s + '年'+ ma.course_message.course.term %>)
- 测验标题:<%= ma.course_message.exercise_name %>
- 截止时间:<%= ma.course_message.end_time.to_s.gsub("+0800","").to_datetime.strftime("%Y-%m-%d %H:%M:%S") %>
- 答题时长:<%= ma.course_message.time == -1 ? '无限制' : ma.course_message.time.to_s + '分钟' %>
请及时完成班级测验,辛苦啦!
- 截止时间快到啦
- <%= time_tag(ma.created_at).html_safe %>
<% end %>