修改邮件提醒:项目缺陷动态不能收到
This commit is contained in:
parent
7197c33be4
commit
6cddb59a4a
|
@ -45,7 +45,6 @@ class Mailer < ActionMailer::Base
|
||||||
MailerProxy.new(self)
|
MailerProxy.new(self)
|
||||||
end
|
end
|
||||||
|
|
||||||
# author: alan
|
|
||||||
# 发送邀请未注册用户加入项目邮件
|
# 发送邀请未注册用户加入项目邮件
|
||||||
# 功能: 在加入项目的同时自动注册用户
|
# 功能: 在加入项目的同时自动注册用户
|
||||||
def send_invite_in_project(email, project, invitor)
|
def send_invite_in_project(email, project, invitor)
|
||||||
|
@ -101,16 +100,16 @@ class Mailer < ActionMailer::Base
|
||||||
course_ids = courses.map {|course| course.id}.join(",")
|
course_ids = courses.map {|course| course.id}.join(",")
|
||||||
|
|
||||||
# 查询user的缺陷,包括发布的,跟踪的以及被指派的缺陷
|
# 查询user的缺陷,包括发布的,跟踪的以及被指派的缺陷
|
||||||
sql = "select DISTINCT i.* from issues i, watchers w
|
# sql = "select DISTINCT i.* from issues i, watchers w
|
||||||
where (i.assigned_to_id = #{user.id} or i.author_id = #{user.id}
|
# where (i.assigned_to_id = #{user.id} or i.author_id = #{user.id}
|
||||||
or (w.watchable_type = 'Issue' and w.watchable_id = i.id and w.user_id = #{user.id}))
|
# or (w.watchable_type = 'Issue' and w.watchable_id = i.id and w.user_id = #{user.id}))
|
||||||
and (i.created_on between '#{date_from}' and '#{date_to}') order by i.created_on desc"
|
# and (i.created_on between '#{date_from}' and '#{date_to}') order by i.created_on desc"
|
||||||
|
sql = "select DISTINCT i.* from issues i where (i.created_on between '#{date_from}' and '#{date_to}') order by i.created_on desc"
|
||||||
@issues = Issue.find_by_sql(sql)
|
@issues = Issue.find_by_sql(sql)
|
||||||
|
|
||||||
# @bids 查询课程作业,包括老师发布的作业,以及user提交作业
|
# @bids 查询课程作业,包括老师发布的作业,以及user提交作业
|
||||||
# @attachments查询课程课件更新
|
# @attachments查询课程课件更新
|
||||||
@attachments ||= []
|
@attachments ||= []
|
||||||
|
|
||||||
@bids ||= [] # 老师发布的作业
|
@bids ||= [] # 老师发布的作业
|
||||||
|
|
||||||
unless courses.first.nil?
|
unless courses.first.nil?
|
||||||
|
@ -142,9 +141,9 @@ class Mailer < ActionMailer::Base
|
||||||
# 查询user在课程中发布的通知,项目中发的新闻
|
# 查询user在课程中发布的通知,项目中发的新闻
|
||||||
@course_news = (course_ids && !course_ids.empty?) ? News.find_by_sql("select DISTINCT n.* from news n
|
@course_news = (course_ids && !course_ids.empty?) ? News.find_by_sql("select DISTINCT n.* from news n
|
||||||
where n.course_id in (#{course_ids})
|
where n.course_id in (#{course_ids})
|
||||||
and (created_on between '#{date_from}' and '#{date_to}') order by created_on desc") : []
|
and (created_on between '#{date_from}' and '#{date_to}') order by created_on desc") : []
|
||||||
@project_news = (project_ids && !project_ids.empty?) ? News.find_by_sql("select DISTINCT n.* from news n where n.project_id in (#{project_ids})
|
@project_news = (project_ids && !project_ids.empty?) ? News.find_by_sql("select DISTINCT n.* from news n where n.project_id in (#{project_ids})
|
||||||
and (created_on between '#{date_from}' and '#{date_to}') order by created_on desc") : []
|
and (created_on between '#{date_from}' and '#{date_to}') order by created_on desc") : []
|
||||||
|
|
||||||
# 查询user在课程及个人中留言
|
# 查询user在课程及个人中留言
|
||||||
@course_journal_messages = JournalsForMessage.find_by_sql("select DISTINCT * from journals_for_messages where
|
@course_journal_messages = JournalsForMessage.find_by_sql("select DISTINCT * from journals_for_messages where
|
||||||
|
@ -165,7 +164,7 @@ class Mailer < ActionMailer::Base
|
||||||
}
|
}
|
||||||
mylogger.debug "Sent activity mail : #{user.mail} - #{has_content}"
|
mylogger.debug "Sent activity mail : #{user.mail} - #{has_content}"
|
||||||
#有内容才发,没有不发
|
#有内容才发,没有不发
|
||||||
mail :to => user.mail,:subject => subject if has_content
|
mail :to => user.mail, :subject => subject if has_content
|
||||||
end
|
end
|
||||||
|
|
||||||
# 公共讨论区发帖、回帖添加邮件发送信息
|
# 公共讨论区发帖、回帖添加邮件发送信息
|
||||||
|
@ -188,8 +187,8 @@ class Mailer < ActionMailer::Base
|
||||||
:subject => "[ #{l(:label_message_plural)} : #{memo.subject} #{l(:label_memo_create_succ)}]",
|
:subject => "[ #{l(:label_message_plural)} : #{memo.subject} #{l(:label_memo_create_succ)}]",
|
||||||
:filter => true
|
:filter => true
|
||||||
end
|
end
|
||||||
# Builds a Mail::Message object used to email recipients of the added journals for message.
|
|
||||||
|
|
||||||
|
# Builds a Mail::Message object used to email recipients of the added journals for message.
|
||||||
# 留言分为直接留言,和对留言人留言的回复
|
# 留言分为直接留言,和对留言人留言的回复
|
||||||
# 字段说明在JournalsForMessage.rb
|
# 字段说明在JournalsForMessage.rb
|
||||||
# 直接留言后 reply_id,m_parent_id 为空,相对应的at_user取值为nil
|
# 直接留言后 reply_id,m_parent_id 为空,相对应的at_user取值为nil
|
||||||
|
@ -511,7 +510,7 @@ class Mailer < ActionMailer::Base
|
||||||
end
|
end
|
||||||
|
|
||||||
# Builds a Mail::Message object used to email recipients of a news' project when a news comment is added.
|
# Builds a Mail::Message object used to email recipients of a news' project when a news comment is added.
|
||||||
#
|
# 新增新闻评论时邮件通知
|
||||||
# Example:
|
# Example:
|
||||||
# news_comment_added(comment) => Mail::Message object
|
# news_comment_added(comment) => Mail::Message object
|
||||||
# Mailer.news_comment_added(comment) => sends an email to the news' project recipients
|
# Mailer.news_comment_added(comment) => sends an email to the news' project recipients
|
||||||
|
@ -526,9 +525,9 @@ class Mailer < ActionMailer::Base
|
||||||
@comment = comment
|
@comment = comment
|
||||||
@news_url = url_for(:controller => 'news', :action => 'show', :id => news)
|
@news_url = url_for(:controller => 'news', :action => 'show', :id => news)
|
||||||
mail :to => news.recipients,
|
mail :to => news.recipients,
|
||||||
:cc => news.watcher_recipients,
|
:cc => news.watcher_recipients,
|
||||||
:subject => "Re: [#{news.project.name}] #{l(:label_news)}: #{news.title}",
|
:subject => "Re: [#{news.project.name}] #{l(:label_news)}: #{news.title}",
|
||||||
:filter => true
|
:filter => true
|
||||||
elsif news.course
|
elsif news.course
|
||||||
redmine_headers 'Course' => news.course.id
|
redmine_headers 'Course' => news.course.id
|
||||||
@author = comment.author
|
@author = comment.author
|
||||||
|
@ -563,9 +562,9 @@ class Mailer < ActionMailer::Base
|
||||||
@message = message
|
@message = message
|
||||||
@message_url = url_for(message.event_url)
|
@message_url = url_for(message.event_url)
|
||||||
mail :to => recipients,
|
mail :to => recipients,
|
||||||
:cc => cc,
|
:cc => cc,
|
||||||
:subject => "[#{message.board.project.name} - #{message.board.name} - msg#{message.root.id}] #{message.subject}",
|
:subject => "[#{message.board.project.name} - #{message.board.name} - msg#{message.root.id}] #{message.subject}",
|
||||||
:filter => true
|
:filter => true
|
||||||
elsif message.course
|
elsif message.course
|
||||||
redmine_headers 'Course' => message.course.id,
|
redmine_headers 'Course' => message.course.id,
|
||||||
'Topic-Id' => (message.parent_id || message.id)
|
'Topic-Id' => (message.parent_id || message.id)
|
||||||
|
@ -909,10 +908,11 @@ class Mailer < ActionMailer::Base
|
||||||
if email.attachments && email.attachments.any?
|
if email.attachments && email.attachments.any?
|
||||||
email.attachments.each do |attachment|
|
email.attachments.each do |attachment|
|
||||||
obj.attachments << Attachment.create(:container => obj,
|
obj.attachments << Attachment.create(:container => obj,
|
||||||
:file => attachment.decoded,
|
:file => attachment.decoded,
|
||||||
:filename => attachment.filename,
|
:filename => attachment.filename,
|
||||||
:author => user,
|
:author => user,
|
||||||
:content_type => attachment.mime_type)
|
|
||||||
|
:content_type => attachment.mime_type)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
|
@ -1,341 +1,331 @@
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<div class="content">
|
<div class="content">
|
||||||
<h4 class="wmail_h4" style="color:#474646; font-size:14px; margin-bottom:5px;" >
|
<h4 class="wmail_h4" style="color:#474646; font-size:14px; margin-bottom:5px;" >
|
||||||
<%= @subject %>
|
<%= @subject %>
|
||||||
</h4>
|
</h4>
|
||||||
<% if @attachments.first || @course_news.first || @bids.first ||
|
<% if @attachments.first || @course_news.first || @bids.first ||
|
||||||
@homeworks.first || @course_journal_messages.first|| @course_messages.first %>
|
@homeworks.first || @course_journal_messages.first|| @course_messages.first %>
|
||||||
<div class="wmail_main" style="padding:20px 10px 0px;">
|
<div class="wmail_main" style="padding:20px 10px 0px;">
|
||||||
<h2 class="wmail_h2" style="color:#15bccf; "><%= l(:label_course_overview)%></h2>
|
<h2 class="wmail_h2" style="color:#15bccf; "><%= l(:label_course_overview)%></h2>
|
||||||
<% unless @course_news.first.nil? %>
|
<% unless @course_news.first.nil? %>
|
||||||
<ul class="wmail_ul" style=" list-style-type:none;clear: both;margin-left:10px; border-bottom:1px dashed #cfcfcf; padding-bottom:15px; width:720px; margin-bottom:15px;">
|
<ul class="wmail_ul" style=" list-style-type:none;clear: both;margin-left:10px; border-bottom:1px dashed #cfcfcf; padding-bottom:15px; width:720px; margin-bottom:15px;">
|
||||||
|
<h4 class="wmail_h4" style="color:#474646; font-size:14px; margin-bottom:5px;" >
|
||||||
|
<%= l(:label_course_news) %>
|
||||||
|
<span class="wmail_num" style="color:#fe3f0c; margin-left:5px; font-weight:normal;">(<%= @course_news.count %>)</span>
|
||||||
|
</h4>
|
||||||
|
<% @course_news.each do |course_new|%>
|
||||||
|
<li style="clear: both; list-style: none;">
|
||||||
|
<span class="wmail_dis" style="float:left; color:#000000; margin-right:5px;">▪</span>
|
||||||
|
<span class="wmail_b" style="color:#1b55a7; font-weight:bold; float:left;">[</span>
|
||||||
|
|
||||||
<h4 class="wmail_h4" style="color:#474646; font-size:14px; margin-bottom:5px;" >
|
<%= link_to truncate(course_new.course.name,length: 30,omission: '...'), course_url(course_new.course, :token => @token.value),
|
||||||
<%= l(:label_course_news) %>
|
:class=> "wmail_column",
|
||||||
<span class="wmail_num" style="color:#fe3f0c; margin-left:5px; font-weight:normal;">(<%= @course_news.count %>)</span>
|
:style=> " font-weight: bold; display:block; float:left; color:#1b55a7;overflow:hidden; white-space: nowrap; text-overflow:ellipsis;" %>
|
||||||
</h4>
|
<span class="wmail_b" style="color:#1b55a7; font-weight:bold; float:left;">]</span>
|
||||||
|
|
||||||
<% @course_news.each do |course_new|%>
|
<%= link_to course_new.author, user_activities_url(course_new.author,:token => @token.value), :class => "wmail_name",
|
||||||
<li style="clear: both; list-style: none;">
|
:style => "color:#fe5722; float:left;display:block; margin-right:5px; margin-left:5px; overflow:hidden; white-space: nowrap; text-overflow:ellipsis;"%>
|
||||||
<span class="wmail_dis" style="float:left; color:#000000; margin-right:5px;">▪</span>
|
<span class="wmail_txt" style="float:left; margin-right:5px;color:#6e6e6e;"><%= l(:label_project_notice) %></span>
|
||||||
<span class="wmail_b" style="color:#1b55a7; font-weight:bold; float:left;">[</span>
|
|
||||||
|
|
||||||
<%= link_to truncate(course_new.course.name,length: 30,omission: '...'), course_url(course_new.course, :token => @token.value),
|
|
||||||
:class=> "wmail_column",
|
|
||||||
:style=> " font-weight: bold; display:block; float:left; color:#1b55a7;overflow:hidden; white-space: nowrap; text-overflow:ellipsis;" %>
|
|
||||||
<span class="wmail_b" style="color:#1b55a7; font-weight:bold; float:left;">]</span>
|
|
||||||
|
|
||||||
<%= link_to course_new.author, user_activities_url(course_new.author,:token => @token.value), :class => "wmail_name",
|
<%= link_to truncate(course_new.title,length: 30,omission: '...'), news_url(course_new,:token => @token.value),
|
||||||
:style => "color:#fe5722; float:left;display:block; margin-right:5px; margin-left:5px; overflow:hidden; white-space: nowrap; text-overflow:ellipsis;"%>
|
:class => 'wmail_info',
|
||||||
<span class="wmail_txt" style="float:left; margin-right:5px;color:#6e6e6e;"><%= l(:label_project_notice) %></span>
|
:style => "color:#5a5a5a; float:left; margin-right:5px; display:block;color:#1b55a7;overflow:hidden; white-space: nowrap; text-overflow:ellipsis;"
|
||||||
|
%>
|
||||||
|
<span class="wmail_date" style="color:#6e6e6e; float:right;display:block; margin-left:10px;"><%= format_time(course_new.created_on) %></span>
|
||||||
|
</li>
|
||||||
|
<% end %>
|
||||||
|
|
||||||
<%= link_to truncate(course_new.title,length: 30,omission: '...'), news_url(course_new,:token => @token.value),
|
<div class="cl"></div>
|
||||||
:class => 'wmail_info',
|
</ul><!--课程动态 end-->
|
||||||
:style => "color:#5a5a5a; float:left; margin-right:5px; display:block;color:#1b55a7;overflow:hidden; white-space: nowrap; text-overflow:ellipsis;"
|
<% end %>
|
||||||
%>
|
<% if !@bids.first.nil? || !@homeworks.first.nil? %>
|
||||||
<span class="wmail_date" style="color:#6e6e6e; float:right;display:block; margin-left:10px;"><%= format_time(course_new.created_on) %></span>
|
<ul class="wmail_ul" style="clear: both;margin-left:10px; border-bottom:1px dashed #cfcfcf; padding-bottom:15px; width:720px; margin-bottom:15px;">
|
||||||
</li>
|
|
||||||
|
<h4 class="wmail_h4" style="color:#474646; font-size:14px; margin-bottom:5px;"><%= l(:label_homework_overview) %><span class="wmail_num" style="color:#fe3f0c; margin-left:5px; font-weight:normal;">(<%= @bids.count %>)</span></h4>
|
||||||
|
<% unless @bids.first.nil?%>
|
||||||
|
<% @bids.each do |bid| %>
|
||||||
|
<li style="clear: both; list-style: none;">
|
||||||
|
<span class="wmail_dis" style="float:left; color:#000000; margin-right:5px;">▪</span>
|
||||||
|
<span class="wmail_b" style="color:#1b55a7; font-weight:bold; float:left;">[</span>
|
||||||
|
|
||||||
|
<%= link_to truncate(bid.courses.first.name,length: 30,omission: '...'), course_url(bid.courses.first, :token => @token.value),
|
||||||
|
:class=> "wmail_column",
|
||||||
|
:style=> " font-weight: bold; display:block; float:left; color:#1b55a7;overflow:hidden; white-space: nowrap; text-overflow:ellipsis;" %>
|
||||||
|
<span class="wmail_b" style="color:#1b55a7; font-weight:bold; float:left;">]</span>
|
||||||
|
|
||||||
|
<%= link_to bid.author, user_activities_url(bid.author,:token => @token.value), :class => "wmail_name",
|
||||||
|
:style => "color:#fe5722; float:left;display:block; margin-right:5px; margin-left:5px; overflow:hidden; white-space: nowrap; text-overflow:ellipsis;"%>
|
||||||
|
<span class="wmail_txt" style="float:left; margin-right:5px;color:#6e6e6e;"><%= l(:label_course_homework) %></span>
|
||||||
|
|
||||||
|
<%= link_to truncate(bid.name,length: 30,omission: '...'), course_for_bid_url(:id => bid.id,:token => @token.value),
|
||||||
|
:class => 'wmail_info',
|
||||||
|
:style => "color:#5a5a5a; float:left; margin-right:5px; display:block;color:#1b55a7;overflow:hidden; white-space: nowrap; text-overflow:ellipsis;"
|
||||||
|
%>
|
||||||
|
<span class="wmail_date" style="color:#6e6e6e; float:right;display:block; margin-left:10px;"><%= format_time(bid.created_on) %></span>
|
||||||
|
</li>
|
||||||
|
<% end %>
|
||||||
|
<% end %>
|
||||||
|
<% unless @homeworks.first.nil? %>
|
||||||
|
<% @homeworks.each do |homework| %>
|
||||||
|
<li style="clear: both; list-style: none;">
|
||||||
|
<span class="wmail_dis" style="float:left; color:#000000; margin-right:5px;">▪</span>
|
||||||
|
<span class="wmail_b" style="color:#1b55a7; font-weight:bold; float:left;">[</span>
|
||||||
|
|
||||||
|
<%= link_to truncate(homework.bid.courses.first.name,length: 30,omission: '...'), course_url(homework.bid.courses.first, :token => @token.value),
|
||||||
|
:class=> "wmail_column",
|
||||||
|
:style=> " font-weight: bold; display:block; float:left; color:#1b55a7;overflow:hidden; white-space: nowrap; text-overflow:ellipsis;" %>
|
||||||
|
<span class="wmail_b" style="color:#1b55a7; font-weight:bold; float:left;">]</span>
|
||||||
|
|
||||||
|
<%= link_to homework.user, user_activities_url(homework.user,:token => @token.value), :class => "wmail_name",
|
||||||
|
:style => "color:#fe5722; float:left;display:block; margin-right:5px; margin-left:5px; overflow:hidden; white-space: nowrap; text-overflow:ellipsis;"%>
|
||||||
|
<span class="wmail_txt" style="float:left; margin-right:5px;color:#6e6e6e;"><%= l(:label_course_submit_homework) %></span>
|
||||||
|
|
||||||
|
<%= link_to truncate(homework.name,length: 30,omission: '...'), course_for_bid_url(:id => homework.bid.id,:token => @token.value),
|
||||||
|
:class => 'wmail_info',
|
||||||
|
:style => "color:#5a5a5a; float:left; margin-right:5px; display:block;color:#1b55a7;overflow:hidden; white-space: nowrap; text-overflow:ellipsis;"
|
||||||
|
%>
|
||||||
|
<span class="wmail_date" style="color:#6e6e6e; float:right;display:block; margin-left:10px;"><%= format_time(homework.created_at) %></span>
|
||||||
|
</li>
|
||||||
|
<% end %>
|
||||||
|
<% end %>
|
||||||
|
|
||||||
|
<div class="cl"></div>
|
||||||
|
</ul><!--作业动态 end-->
|
||||||
<% end %>
|
<% end %>
|
||||||
|
|
||||||
<div class="cl"></div>
|
<% unless @course_journal_messages.first.nil? %>
|
||||||
</ul><!--课程动态 end-->
|
<ul class="wmail_ul" style="clear: both;margin-left:10px; border-bottom:1px dashed #cfcfcf; padding-bottom:15px; width:720px; margin-bottom:15px;">
|
||||||
<% end %>
|
|
||||||
<% if !@bids.first.nil? || !@homeworks.first.nil? %>
|
|
||||||
<ul class="wmail_ul" style="clear: both;margin-left:10px; border-bottom:1px dashed #cfcfcf; padding-bottom:15px; width:720px; margin-bottom:15px;">
|
|
||||||
|
|
||||||
<h4 class="wmail_h4" style="color:#474646; font-size:14px; margin-bottom:5px;"><%= l(:label_homework_overview) %><span class="wmail_num" style="color:#fe3f0c; margin-left:5px; font-weight:normal;">(<%= @bids.count %>)</span></h4>
|
<h4 class="wmail_h4" style="color:#474646; font-size:14px; margin-bottom:5px;" >
|
||||||
<% unless @bids.first.nil?%>
|
<%= l(:view_course_journals_for_messages) %>
|
||||||
<% @bids.each do |bid| %>
|
<span class="wmail_num" style="color:#fe3f0c; margin-left:5px; font-weight:normal;">(<%= @course_journal_messages.count %>)</span>
|
||||||
<li style="clear: both; list-style: none;">
|
</h4>
|
||||||
<span class="wmail_dis" style="float:left; color:#000000; margin-right:5px;">▪</span>
|
|
||||||
<span class="wmail_b" style="color:#1b55a7; font-weight:bold; float:left;">[</span>
|
|
||||||
|
|
||||||
<%= link_to truncate(bid.courses.first.name,length: 30,omission: '...'), course_url(bid.courses.first, :token => @token.value),
|
<% @course_journal_messages.each do |course_journal_message|%>
|
||||||
:class=> "wmail_column",
|
<li style="clear: both; list-style: none;">
|
||||||
:style=> " font-weight: bold; display:block; float:left; color:#1b55a7;overflow:hidden; white-space: nowrap; text-overflow:ellipsis;" %>
|
<span class="wmail_dis" style="float:left; color:#000000; margin-right:5px;">▪</span>
|
||||||
<span class="wmail_b" style="color:#1b55a7; font-weight:bold; float:left;">]</span>
|
<span class="wmail_b" style="color:#1b55a7; font-weight:bold; float:left;">[</span>
|
||||||
|
|
||||||
<%= link_to bid.author, user_activities_url(bid.author,:token => @token.value), :class => "wmail_name",
|
<%= link_to truncate(course_journal_message.course.name,length: 30,omission: '...'), course_url(course_journal_message.course, :token => @token.value),
|
||||||
:style => "color:#fe5722; float:left;display:block; margin-right:5px; margin-left:5px; overflow:hidden; white-space: nowrap; text-overflow:ellipsis;"%>
|
:class=> "wmail_column",
|
||||||
<span class="wmail_txt" style="float:left; margin-right:5px;color:#6e6e6e;"><%= l(:label_course_homework) %></span>
|
:style=> " font-weight: bold; display:block; float:left; color:#1b55a7;overflow:hidden; white-space: nowrap; text-overflow:ellipsis;" %>
|
||||||
|
<span class="wmail_b" style="color:#1b55a7; font-weight:bold; float:left;">]</span>
|
||||||
|
|
||||||
<%= link_to truncate(bid.name,length: 30,omission: '...'), course_for_bid_url(:id => bid.id,:token => @token.value),
|
<%= link_to course_journal_message.user, user_activities_url(course_journal_message.user,:token => @token.value), :class => "wmail_name",
|
||||||
:class => 'wmail_info',
|
:style => "color:#fe5722; float:left;display:block; margin-right:5px; margin-left:5px; overflow:hidden; white-space: nowrap; text-overflow:ellipsis;"%>
|
||||||
:style => "color:#5a5a5a; float:left; margin-right:5px; display:block;color:#1b55a7;overflow:hidden; white-space: nowrap; text-overflow:ellipsis;"
|
<span class="wmail_txt" style="float:left; margin-right:5px;color:#6e6e6e;"><%= l(:label_send_course_journals_for_messages) %></span>
|
||||||
%>
|
|
||||||
<span class="wmail_date" style="color:#6e6e6e; float:right;display:block; margin-left:10px;"><%= format_time(bid.created_on) %></span>
|
|
||||||
</li>
|
|
||||||
<% end %>
|
|
||||||
<% end %>
|
|
||||||
<% unless @homeworks.first.nil? %>
|
|
||||||
<% @homeworks.each do |homework| %>
|
|
||||||
<li style="clear: both; list-style: none;">
|
|
||||||
<span class="wmail_dis" style="float:left; color:#000000; margin-right:5px;">▪</span>
|
|
||||||
<span class="wmail_b" style="color:#1b55a7; font-weight:bold; float:left;">[</span>
|
|
||||||
|
|
||||||
<%= link_to truncate(homework.bid.courses.first.name,length: 30,omission: '...'), course_url(homework.bid.courses.first, :token => @token.value),
|
<%= link_to truncate(course_journal_message.notes,length: 30,omission: '...'), course_feedback_url(course_journal_message.course,:token => @token.value),
|
||||||
:class=> "wmail_column",
|
:class => 'wmail_info',
|
||||||
:style=> " font-weight: bold; display:block; float:left; color:#1b55a7;overflow:hidden; white-space: nowrap; text-overflow:ellipsis;" %>
|
:style => "color:#5a5a5a; float:left; margin-right:5px; display:block;color:#1b55a7;overflow:hidden; white-space: nowrap; text-overflow:ellipsis;"
|
||||||
<span class="wmail_b" style="color:#1b55a7; font-weight:bold; float:left;">]</span>
|
%>
|
||||||
|
<span class="wmail_date" style="color:#6e6e6e; float:right;display:block; margin-left:10px;"><%= format_time(course_journal_message.created_on) %></span>
|
||||||
|
</li>
|
||||||
|
<% end %>
|
||||||
|
|
||||||
<%= link_to homework.user, user_activities_url(homework.user,:token => @token.value), :class => "wmail_name",
|
<div class="cl"></div>
|
||||||
:style => "color:#fe5722; float:left;display:block; margin-right:5px; margin-left:5px; overflow:hidden; white-space: nowrap; text-overflow:ellipsis;"%>
|
</ul><!--课程留言 end-->
|
||||||
<span class="wmail_txt" style="float:left; margin-right:5px;color:#6e6e6e;"><%= l(:label_course_submit_homework) %></span>
|
|
||||||
|
|
||||||
<%= link_to truncate(homework.name,length: 30,omission: '...'), course_for_bid_url(:id => homework.bid.id,:token => @token.value),
|
|
||||||
:class => 'wmail_info',
|
|
||||||
:style => "color:#5a5a5a; float:left; margin-right:5px; display:block;color:#1b55a7;overflow:hidden; white-space: nowrap; text-overflow:ellipsis;"
|
|
||||||
%>
|
|
||||||
<span class="wmail_date" style="color:#6e6e6e; float:right;display:block; margin-left:10px;"><%= format_time(homework.created_at) %></span>
|
|
||||||
</li>
|
|
||||||
<% end %>
|
|
||||||
<% end %>
|
<% end %>
|
||||||
|
|
||||||
<div class="cl"></div>
|
<% unless @course_messages.first.nil? %>
|
||||||
</ul><!--作业动态 end-->
|
<ul class="wmail_ul" style="margin-left:10px; border-bottom:1px dashed #cfcfcf; padding-bottom:15px; width:720px; margin-bottom:15px;">
|
||||||
<% end %>
|
|
||||||
|
|
||||||
<% unless @course_journal_messages.first.nil? %>
|
<h4 class="wmail_h4" style="color:#474646; font-size:14px; margin-bottom:5px;" >
|
||||||
<ul class="wmail_ul" style="clear: both;margin-left:10px; border-bottom:1px dashed #cfcfcf; padding-bottom:15px; width:720px; margin-bottom:15px;">
|
<%= l(:view_borad_course) %>
|
||||||
|
<span class="wmail_num" style="color:#fe3f0c; margin-left:5px; font-weight:normal;">(<%= @course_journal_messages.count %>)</span>
|
||||||
|
</h4>
|
||||||
|
|
||||||
<h4 class="wmail_h4" style="color:#474646; font-size:14px; margin-bottom:5px;" >
|
<% @course_messages.each do |course_message|%>
|
||||||
<%= l(:view_course_journals_for_messages) %>
|
<li style="clear: both; list-style: none;">
|
||||||
<span class="wmail_num" style="color:#fe3f0c; margin-left:5px; font-weight:normal;">(<%= @course_journal_messages.count %>)</span>
|
<span class="wmail_dis" style="float:left; color:#000000; margin-right:5px;">▪</span>
|
||||||
</h4>
|
<span class="wmail_b" style="color:#1b55a7; font-weight:bold; float:left;">[</span>
|
||||||
|
|
||||||
<% @course_journal_messages.each do |course_journal_message|%>
|
<%= link_to truncate(course_message.course.name,length: 30,omission: '...'), course_url(course_message.course.id, :token => @token.value),
|
||||||
<li style="clear: both; list-style: none;">
|
:class=> "wmail_column",
|
||||||
<span class="wmail_dis" style="float:left; color:#000000; margin-right:5px;">▪</span>
|
:style=> " font-weight: bold; display:block; float:left; color:#1b55a7;overflow:hidden; white-space: nowrap; text-overflow:ellipsis;" %>
|
||||||
<span class="wmail_b" style="color:#1b55a7; font-weight:bold; float:left;">[</span>
|
<span class="wmail_b" style="color:#1b55a7; font-weight:bold; float:left;">]</span>
|
||||||
|
|
||||||
<%= link_to truncate(course_journal_message.course.name,length: 30,omission: '...'), course_url(course_journal_message.course, :token => @token.value),
|
<%= link_to course_message.author, user_activities_url(course_message.author,:token => @token.value), :class => "wmail_name",
|
||||||
:class=> "wmail_column",
|
:style => "color:#fe5722; float:left;display:block; margin-right:5px; margin-left:5px; overflow:hidden; white-space: nowrap; text-overflow:ellipsis;"%>
|
||||||
:style=> " font-weight: bold; display:block; float:left; color:#1b55a7;overflow:hidden; white-space: nowrap; text-overflow:ellipsis;" %>
|
<span class="wmail_txt" style="float:left; margin-right:5px;color:#6e6e6e;"><%= l(:label_send_course_messages) %></span>
|
||||||
<span class="wmail_b" style="color:#1b55a7; font-weight:bold; float:left;">]</span>
|
|
||||||
|
|
||||||
<%= link_to course_journal_message.user, user_activities_url(course_journal_message.user,:token => @token.value), :class => "wmail_name",
|
<%= link_to truncate(course_message.subject,length: 30,omission: '...'),board_message_url(course_message, :board_id => course_message.board_id,:token => @token.value),
|
||||||
:style => "color:#fe5722; float:left;display:block; margin-right:5px; margin-left:5px; overflow:hidden; white-space: nowrap; text-overflow:ellipsis;"%>
|
:class => 'wmail_info',
|
||||||
<span class="wmail_txt" style="float:left; margin-right:5px;color:#6e6e6e;"><%= l(:label_send_course_journals_for_messages) %></span>
|
:style => "color:#5a5a5a; float:left; margin-right:5px; display:block;color:#1b55a7;overflow:hidden; white-space: nowrap; text-overflow:ellipsis;"
|
||||||
|
%>
|
||||||
|
<span class="wmail_date" style="color:#6e6e6e; float:right;display:block; margin-left:10px;"><%= format_time(course_message.created_on) %></span>
|
||||||
|
</li>
|
||||||
|
<% end %>
|
||||||
|
|
||||||
<%= link_to truncate(course_journal_message.notes,length: 30,omission: '...'), course_feedback_url(course_journal_message.course,:token => @token.value),
|
<div class="cl"></div>
|
||||||
:class => 'wmail_info',
|
</ul><!--课程讨论 end-->
|
||||||
:style => "color:#5a5a5a; float:left; margin-right:5px; display:block;color:#1b55a7;overflow:hidden; white-space: nowrap; text-overflow:ellipsis;"
|
<% end %>
|
||||||
%>
|
|
||||||
<span class="wmail_date" style="color:#6e6e6e; float:right;display:block; margin-left:10px;"><%= format_time(course_journal_message.created_on) %></span>
|
|
||||||
</li>
|
|
||||||
<% end %>
|
|
||||||
|
|
||||||
<div class="cl"></div>
|
<% unless @attachments.first.nil? %>
|
||||||
</ul><!--课程留言 end-->
|
<ul class="wmail_ul" style="margin-left:10px; border-bottom:1px dashed #cfcfcf; padding-bottom:15px; width:720px; margin-bottom:15px;">
|
||||||
<% end %>
|
<h4 class="wmail_h4" style="color:#474646; font-size:14px; margin-bottom:5px;" >
|
||||||
|
<%= l(:label_course_attendingcontestwork_download) %>
|
||||||
|
<span class="wmail_num" style="color:#fe3f0c; margin-left:5px; font-weight:normal;">(<%= @attachments.count %>)</span>
|
||||||
|
</h4>
|
||||||
|
|
||||||
<% unless @course_messages.first.nil? %>
|
<% @attachments.each do |attachment|%>
|
||||||
<ul class="wmail_ul" style="margin-left:10px; border-bottom:1px dashed #cfcfcf; padding-bottom:15px; width:720px; margin-bottom:15px;">
|
<li style="clear: both; list-style: none;">
|
||||||
|
<span class="wmail_dis" style="float:left; color:#000000; margin-right:5px;">▪</span>
|
||||||
|
<span class="wmail_b" style="color:#1b55a7; font-weight:bold; float:left;">[</span>
|
||||||
|
|
||||||
<h4 class="wmail_h4" style="color:#474646; font-size:14px; margin-bottom:5px;" >
|
<%= link_to truncate(attachment.course.name,length: 30,omission: '...'), course_url(attachment.course, :token => @token.value),
|
||||||
<%= l(:view_borad_course) %>
|
:class=> "wmail_column",
|
||||||
<span class="wmail_num" style="color:#fe3f0c; margin-left:5px; font-weight:normal;">(<%= @course_journal_messages.count %>)</span>
|
:style=> " font-weight: bold; display:block; float:left; color:#1b55a7;overflow:hidden; white-space: nowrap; text-overflow:ellipsis;" %>
|
||||||
</h4>
|
<span class="wmail_b" style="color:#1b55a7; font-weight:bold; float:left;">]</span>
|
||||||
|
|
||||||
<% @course_messages.each do |course_message|%>
|
<%= link_to attachment.author, user_activities_url(attachment.author,:token => @token.value), :class => "wmail_name",
|
||||||
<li style="clear: both; list-style: none;">
|
:style => "color:#fe5722; float:left;display:block; margin-right:5px; margin-left:5px; overflow:hidden; white-space: nowrap; text-overflow:ellipsis;"%>
|
||||||
<span class="wmail_dis" style="float:left; color:#000000; margin-right:5px;">▪</span>
|
<span class="wmail_txt" style="float:left; margin-right:5px;color:#6e6e6e;"><%= l(:label_course_file_upload) %></span>
|
||||||
<span class="wmail_b" style="color:#1b55a7; font-weight:bold; float:left;">[</span>
|
|
||||||
|
|
||||||
<%= link_to truncate(course_message.course.name,length: 30,omission: '...'), course_url(course_message.course.id, :token => @token.value),
|
<%= link_to truncate(attachment.filename,length: 30,omission: '...'),course_files_url(attachment.course,:token => @token.value),
|
||||||
:class=> "wmail_column",
|
:class => 'wmail_info',
|
||||||
:style=> " font-weight: bold; display:block; float:left; color:#1b55a7;overflow:hidden; white-space: nowrap; text-overflow:ellipsis;" %>
|
:style => "color:#5a5a5a; float:left; margin-right:5px; display:block;color:#1b55a7;overflow:hidden; white-space: nowrap; text-overflow:ellipsis;"
|
||||||
<span class="wmail_b" style="color:#1b55a7; font-weight:bold; float:left;">]</span>
|
%>
|
||||||
|
<span class="wmail_date" style="color:#6e6e6e; float:right;display:block; margin-left:10px;"><%= format_time(attachment.created_on) %></span>
|
||||||
|
</li>
|
||||||
|
<% end %>
|
||||||
|
<div class="cl"></div>
|
||||||
|
</ul><!--课件下载 end-->
|
||||||
|
<% end %>
|
||||||
|
</div><!--课程动态 end-->
|
||||||
|
<% end %>
|
||||||
|
<% if @issues.first || @project_messages.first %>
|
||||||
|
<div class="wmail_main" style="padding:20px 10px 0px;">
|
||||||
|
<h2 class="wmail_h2" style="color:#15bccf; "><%= l(:label_project_overview_new)%></h2>
|
||||||
|
<% unless @issues.first.nil? %>
|
||||||
|
<ul class="wmail_ul" style="margin-left:10px; border-bottom:1px dashed #cfcfcf; padding-bottom:15px; width:720px; margin-bottom:15px;">
|
||||||
|
<h4 class="wmail_h4" style="color:#474646; font-size:14px; margin-bottom:5px;" >
|
||||||
|
<%= l(:label_issue_tracking) %>
|
||||||
|
<span class="wmail_num" style="color:#fe3f0c; margin-left:5px; font-weight:normal;">(<%= @issues.count %>)</span>
|
||||||
|
</h4>
|
||||||
|
<% @issues.each do |issue|%>
|
||||||
|
<li style="clear: both; list-style: none;">
|
||||||
|
<span class="wmail_dis" style="float:left; color:#000000; margin-right:5px;">▪</span>
|
||||||
|
<span class="wmail_b" style="color:#1b55a7; font-weight:bold; float:left;">[</span>
|
||||||
|
|
||||||
<%= link_to course_message.author, user_activities_url(course_message.author,:token => @token.value), :class => "wmail_name",
|
<%= link_to truncate(issue.project.name,length: 30,omission: '...'), project_url(issue.project, :token => @token.value),
|
||||||
:style => "color:#fe5722; float:left;display:block; margin-right:5px; margin-left:5px; overflow:hidden; white-space: nowrap; text-overflow:ellipsis;"%>
|
:class=> "wmail_column",
|
||||||
<span class="wmail_txt" style="float:left; margin-right:5px;color:#6e6e6e;"><%= l(:label_send_course_messages) %></span>
|
:style=> " font-weight: bold; display:block; float:left; color:#1b55a7;overflow:hidden; white-space: nowrap; text-overflow:ellipsis;" %>
|
||||||
|
<span class="wmail_b" style="color:#1b55a7; font-weight:bold; float:left;">]</span>
|
||||||
|
|
||||||
<%= link_to truncate(course_message.subject,length: 30,omission: '...'),board_message_url(course_message, :board_id => course_message.board_id,:token => @token.value),
|
<%= link_to issue.author, user_activities_url(issue.author,:token => @token.value), :class => "wmail_name",
|
||||||
:class => 'wmail_info',
|
:style => "color:#fe5722; float:left;display:block; margin-right:5px; margin-left:5px; overflow:hidden; white-space: nowrap; text-overflow:ellipsis;"%>
|
||||||
:style => "color:#5a5a5a; float:left; margin-right:5px; display:block;color:#1b55a7;overflow:hidden; white-space: nowrap; text-overflow:ellipsis;"
|
<span class="wmail_txt" style="float:left; margin-right:5px;color:#6e6e6e;"><%= l(:label_project_issue) %></span>
|
||||||
%>
|
|
||||||
<span class="wmail_date" style="color:#6e6e6e; float:right;display:block; margin-left:10px;"><%= format_time(course_message.created_on) %></span>
|
|
||||||
</li>
|
|
||||||
<% end %>
|
|
||||||
|
|
||||||
<div class="cl"></div>
|
<%= link_to truncate(issue.subject,length: 30,omission: '...'),issue_url(issue, :token => @token.value),
|
||||||
</ul><!--课程讨论 end-->
|
:class => 'wmail_info',
|
||||||
<% end %>
|
:style => "color:#5a5a5a; float:left; margin-right:5px; display:block;color:#1b55a7;overflow:hidden; white-space: nowrap; text-overflow:ellipsis;"
|
||||||
|
%>
|
||||||
|
<span class="wmail_date" style="color:#6e6e6e; float:right;display:block; margin-left:10px;"><%= format_time(issue.created_on) %></span>
|
||||||
|
</li>
|
||||||
|
<% end %>
|
||||||
|
|
||||||
<% unless @attachments.first.nil? %>
|
<div class="cl"></div>
|
||||||
<ul class="wmail_ul" style="margin-left:10px; border-bottom:1px dashed #cfcfcf; padding-bottom:15px; width:720px; margin-bottom:15px;">
|
</ul><!--问题跟踪 end-->
|
||||||
<h4 class="wmail_h4" style="color:#474646; font-size:14px; margin-bottom:5px;" >
|
<% end %>
|
||||||
<%= l(:label_course_attendingcontestwork_download) %>
|
|
||||||
<span class="wmail_num" style="color:#fe3f0c; margin-left:5px; font-weight:normal;">(<%= @attachments.count %>)</span>
|
|
||||||
</h4>
|
|
||||||
|
|
||||||
<% @attachments.each do |attachment|%>
|
<% unless @project_messages.first.nil? %>
|
||||||
<li style="clear: both; list-style: none;">
|
<ul class="wmail_ul" style="margin-left:10px; border-bottom:1px dashed #cfcfcf; padding-bottom:15px; width:720px; margin-bottom:15px;">
|
||||||
<span class="wmail_dis" style="float:left; color:#000000; margin-right:5px;">▪</span>
|
<h4 class="wmail_h4" style="color:#474646; font-size:14px; margin-bottom:5px;" >
|
||||||
<span class="wmail_b" style="color:#1b55a7; font-weight:bold; float:left;">[</span>
|
<%= l(:project_moule_boards_show) %>
|
||||||
|
<span class="wmail_num" style="color:#fe3f0c; margin-left:5px; font-weight:normal;">(<%= @project_messages.count %>)</span>
|
||||||
|
</h4>
|
||||||
|
|
||||||
<%= link_to truncate(attachment.course.name,length: 30,omission: '...'), course_url(attachment.course, :token => @token.value),
|
<% @project_messages.each do |project_message|%>
|
||||||
:class=> "wmail_column",
|
<li style="clear: both; list-style: none;">
|
||||||
:style=> " font-weight: bold; display:block; float:left; color:#1b55a7;overflow:hidden; white-space: nowrap; text-overflow:ellipsis;" %>
|
<span class="wmail_dis" style="float:left; color:#000000; margin-right:5px;">▪</span>
|
||||||
<span class="wmail_b" style="color:#1b55a7; font-weight:bold; float:left;">]</span>
|
<span class="wmail_b" style="color:#1b55a7; font-weight:bold; float:left;">[</span>
|
||||||
|
|
||||||
<%= link_to attachment.author, user_activities_url(attachment.author,:token => @token.value), :class => "wmail_name",
|
<%= link_to truncate(project_message.project.name,length: 30,omission: '...'), project_url(project_message.project, :token => @token.value),
|
||||||
:style => "color:#fe5722; float:left;display:block; margin-right:5px; margin-left:5px; overflow:hidden; white-space: nowrap; text-overflow:ellipsis;"%>
|
:class=> "wmail_column",
|
||||||
<span class="wmail_txt" style="float:left; margin-right:5px;color:#6e6e6e;"><%= l(:label_course_file_upload) %></span>
|
:style=> " font-weight: bold; display:block; float:left; color:#1b55a7;overflow:hidden; white-space: nowrap; text-overflow:ellipsis;" %>
|
||||||
|
<span class="wmail_b" style="color:#1b55a7; font-weight:bold; float:left;">]</span>
|
||||||
|
|
||||||
<%= link_to truncate(attachment.filename,length: 30,omission: '...'),course_files_url(attachment.course,:token => @token.value),
|
<%= link_to project_message.author, user_activities_url(project_message.author,:token => @token.value), :class => "wmail_name",
|
||||||
:class => 'wmail_info',
|
:style => "color:#fe5722; float:left;display:block; margin-right:5px; margin-left:5px; overflow:hidden; white-space: nowrap; text-overflow:ellipsis;"%>
|
||||||
:style => "color:#5a5a5a; float:left; margin-right:5px; display:block;color:#1b55a7;overflow:hidden; white-space: nowrap; text-overflow:ellipsis;"
|
<span class="wmail_txt" style="float:left; margin-right:5px;color:#6e6e6e;"><%= l(:label_send_course_messages) %></span>
|
||||||
%>
|
|
||||||
<span class="wmail_date" style="color:#6e6e6e; float:right;display:block; margin-left:10px;"><%= format_time(attachment.created_on) %></span>
|
|
||||||
</li>
|
|
||||||
<% end %>
|
|
||||||
<div class="cl"></div>
|
|
||||||
</ul><!--课件下载 end-->
|
|
||||||
<% end %>
|
|
||||||
</div><!--课程动态 end-->
|
|
||||||
<% end %>
|
|
||||||
<% if @issues.first || @project_messages.first %>
|
|
||||||
<div class="wmail_main" style="padding:20px 10px 0px;">
|
|
||||||
<h2 class="wmail_h2" style="color:#15bccf; "><%= l(:label_project_overview_new)%></h2>
|
|
||||||
<% unless @issues.first.nil? %>
|
|
||||||
<ul class="wmail_ul" style="margin-left:10px; border-bottom:1px dashed #cfcfcf; padding-bottom:15px; width:720px; margin-bottom:15px;">
|
|
||||||
<h4 class="wmail_h4" style="color:#474646; font-size:14px; margin-bottom:5px;" >
|
|
||||||
<%= l(:label_issue_tracking) %>
|
|
||||||
<span class="wmail_num" style="color:#fe3f0c; margin-left:5px; font-weight:normal;">(<%= @issues.count %>)</span>
|
|
||||||
</h4>
|
|
||||||
|
|
||||||
<% @issues.each do |issue|%>
|
<%= link_to truncate(project_message.subject,length: 30,omission: '...'),board_message_url(project_message, :board_id => project_message.board_id,:token => @token.value),
|
||||||
<li style="clear: both; list-style: none;">
|
:class => 'wmail_info',
|
||||||
<span class="wmail_dis" style="float:left; color:#000000; margin-right:5px;">▪</span>
|
:style => "color:#5a5a5a; float:left; margin-right:5px; display:block;color:#1b55a7;overflow:hidden; white-space: nowrap; text-overflow:ellipsis;"
|
||||||
<span class="wmail_b" style="color:#1b55a7; font-weight:bold; float:left;">[</span>
|
%>
|
||||||
|
<span class="wmail_date" style="color:#6e6e6e; float:right;display:block; margin-left:10px;"><%= format_time(project_message.created_on) %></span>
|
||||||
|
</li>
|
||||||
|
<% end %>
|
||||||
|
|
||||||
<%= link_to truncate(issue.project.name,length: 30,omission: '...'), project_url(issue.project, :token => @token.value),
|
<div class="cl"></div>
|
||||||
:class=> "wmail_column",
|
</ul><!--项目论坛 end-->
|
||||||
:style=> " font-weight: bold; display:block; float:left; color:#1b55a7;overflow:hidden; white-space: nowrap; text-overflow:ellipsis;" %>
|
<% end %>
|
||||||
<span class="wmail_b" style="color:#1b55a7; font-weight:bold; float:left;">]</span>
|
|
||||||
|
|
||||||
<%= link_to issue.author, user_activities_url(issue.author,:token => @token.value), :class => "wmail_name",
|
|
||||||
:style => "color:#fe5722; float:left;display:block; margin-right:5px; margin-left:5px; overflow:hidden; white-space: nowrap; text-overflow:ellipsis;"%>
|
|
||||||
<span class="wmail_txt" style="float:left; margin-right:5px;color:#6e6e6e;"><%= l(:label_project_issue) %></span>
|
|
||||||
|
|
||||||
<%= link_to truncate(issue.subject,length: 30,omission: '...'),issue_url(issue, :token => @token.value),
|
|
||||||
:class => 'wmail_info',
|
|
||||||
:style => "color:#5a5a5a; float:left; margin-right:5px; display:block;color:#1b55a7;overflow:hidden; white-space: nowrap; text-overflow:ellipsis;"
|
|
||||||
%>
|
|
||||||
<span class="wmail_date" style="color:#6e6e6e; float:right;display:block; margin-left:10px;"><%= format_time(issue.created_on) %></span>
|
|
||||||
</li>
|
|
||||||
<% end %>
|
|
||||||
|
|
||||||
<div class="cl"></div>
|
|
||||||
</ul><!--问题跟踪 end-->
|
|
||||||
<% end %>
|
|
||||||
|
|
||||||
<% unless @project_messages.first.nil? %>
|
|
||||||
<ul class="wmail_ul" style="margin-left:10px; border-bottom:1px dashed #cfcfcf; padding-bottom:15px; width:720px; margin-bottom:15px;">
|
|
||||||
<h4 class="wmail_h4" style="color:#474646; font-size:14px; margin-bottom:5px;" >
|
|
||||||
<%= l(:project_moule_boards_show) %>
|
|
||||||
<span class="wmail_num" style="color:#fe3f0c; margin-left:5px; font-weight:normal;">(<%= @project_messages.count %>)</span>
|
|
||||||
</h4>
|
|
||||||
|
|
||||||
<% @project_messages.each do |project_message|%>
|
|
||||||
<li style="clear: both; list-style: none;">
|
|
||||||
<span class="wmail_dis" style="float:left; color:#000000; margin-right:5px;">▪</span>
|
|
||||||
<span class="wmail_b" style="color:#1b55a7; font-weight:bold; float:left;">[</span>
|
|
||||||
|
|
||||||
<%= link_to truncate(project_message.project.name,length: 30,omission: '...'), project_url(project_message.project, :token => @token.value),
|
|
||||||
:class=> "wmail_column",
|
|
||||||
:style=> " font-weight: bold; display:block; float:left; color:#1b55a7;overflow:hidden; white-space: nowrap; text-overflow:ellipsis;" %>
|
|
||||||
<span class="wmail_b" style="color:#1b55a7; font-weight:bold; float:left;">]</span>
|
|
||||||
|
|
||||||
<%= link_to project_message.author, user_activities_url(project_message.author,:token => @token.value), :class => "wmail_name",
|
|
||||||
:style => "color:#fe5722; float:left;display:block; margin-right:5px; margin-left:5px; overflow:hidden; white-space: nowrap; text-overflow:ellipsis;"%>
|
|
||||||
<span class="wmail_txt" style="float:left; margin-right:5px;color:#6e6e6e;"><%= l(:label_send_course_messages) %></span>
|
|
||||||
|
|
||||||
<%= link_to truncate(project_message.subject,length: 30,omission: '...'),board_message_url(project_message, :board_id => project_message.board_id,:token => @token.value),
|
|
||||||
:class => 'wmail_info',
|
|
||||||
:style => "color:#5a5a5a; float:left; margin-right:5px; display:block;color:#1b55a7;overflow:hidden; white-space: nowrap; text-overflow:ellipsis;"
|
|
||||||
%>
|
|
||||||
<span class="wmail_date" style="color:#6e6e6e; float:right;display:block; margin-left:10px;"><%= format_time(project_message.created_on) %></span>
|
|
||||||
</li>
|
|
||||||
<% end %>
|
|
||||||
|
|
||||||
<div class="cl"></div>
|
|
||||||
</ul><!--项目论坛 end-->
|
|
||||||
<% end %>
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</div><!--项目动态 end-->
|
</div><!--项目动态 end-->
|
||||||
<% end %>
|
<% end %>
|
||||||
<% unless @user_journal_messages.first.nil? %>
|
<% unless @user_journal_messages.first.nil? %>
|
||||||
<div class="wmail_main" style="padding:20px 10px 0px;">
|
<div class="wmail_main" style="padding:20px 10px 0px;">
|
||||||
<h2 class="wmail_h2" style="color:#15bccf; "><%= l(:label_activities) %></h2>
|
<h2 class="wmail_h2" style="color:#15bccf; "><%= l(:label_activities) %></h2>
|
||||||
|
|
||||||
<ul class="wmail_ul" style="margin-left:10px; border-bottom:1px dashed #cfcfcf; padding-bottom:15px; width:720px; margin-bottom:15px;">
|
<ul class="wmail_ul" style="margin-left:10px; border-bottom:1px dashed #cfcfcf; padding-bottom:15px; width:720px; margin-bottom:15px;">
|
||||||
<h4 class="wmail_h4" style="color:#474646; font-size:14px; margin-bottom:5px;" >
|
<h4 class="wmail_h4" style="color:#474646; font-size:14px; margin-bottom:5px;" >
|
||||||
<%= l(:label_user_message) %>
|
<%= l(:label_user_message) %>
|
||||||
<span class="wmail_num" style="color:#fe3f0c; margin-left:5px; font-weight:normal;">(<%= @user_journal_messages.count %>)</span>
|
<span class="wmail_num" style="color:#fe3f0c; margin-left:5px; font-weight:normal;">(<%= @user_journal_messages.count %>)</span>
|
||||||
</h4>
|
</h4>
|
||||||
|
|
||||||
<% @user_journal_messages.each do |user_journal_message|%>
|
<% @user_journal_messages.each do |user_journal_message|%>
|
||||||
<li style="clear: both; list-style: none;">
|
<li style="clear: both; list-style: none;">
|
||||||
<span class="wmail_dis" style="float:left; color:#000000; margin-right:5px;">▪</span>
|
<span class="wmail_dis" style="float:left; color:#000000; margin-right:5px;">▪</span>
|
||||||
|
|
||||||
<%= link_to user_journal_message.user, user_activities_url(user_journal_message.user,:token => @token.value),
|
<%= link_to user_journal_message.user, user_activities_url(user_journal_message.user,:token => @token.value),
|
||||||
:class => "wmail_name",
|
:class => "wmail_name",
|
||||||
:style => "color:#fe5722; float:left;display:block; margin-right:5px; margin-left:5px; overflow:hidden; white-space: nowrap; text-overflow:ellipsis;" %>
|
:style => "color:#fe5722; float:left;display:block; margin-right:5px; margin-left:5px; overflow:hidden; white-space: nowrap; text-overflow:ellipsis;" %>
|
||||||
<span class="wmail_txt" style="float:left; margin-right:5px;color:#6e6e6e;"><%= l(:label_show_your_message) %></span>
|
<span class="wmail_txt" style="float:left; margin-right:5px;color:#6e6e6e;"><%= l(:label_show_your_message) %></span>
|
||||||
|
|
||||||
<%= link_to truncate(user_journal_message.notes,length: 30,omission: '...'),feedback_url(@user,:token => @token.value),
|
<%= link_to truncate(user_journal_message.notes,length: 30,omission: '...'),feedback_url(@user,:token => @token.value),
|
||||||
:class => 'wmail_info',
|
:class => 'wmail_info',
|
||||||
:style => "color:#5a5a5a; float:left; margin-right:5px; display:block;color:#1b55a7;overflow:hidden; white-space: nowrap; text-overflow:ellipsis;"
|
:style => "color:#5a5a5a; float:left; margin-right:5px; display:block;color:#1b55a7;overflow:hidden; white-space: nowrap; text-overflow:ellipsis;"
|
||||||
%>
|
%>
|
||||||
<span class="wmail_date" style="color:#6e6e6e; float:right;display:block; margin-left:10px;"><%= format_time(user_journal_message.created_on) %></span></li>
|
<span class="wmail_date" style="color:#6e6e6e; float:right;display:block; margin-left:10px;"><%= format_time(user_journal_message.created_on) %></span></li>
|
||||||
|
|
||||||
<% end %>
|
<% end %>
|
||||||
|
|
||||||
<div class="cl"></div>
|
<div class="cl"></div>
|
||||||
</ul><!--课程动态 end-->
|
</ul><!--课程动态 end-->
|
||||||
|
|
||||||
</div><!--个人动态 end-->
|
</div><!--个人动态 end-->
|
||||||
<% end %>
|
<% end %>
|
||||||
<% if @forums.first || @memos.first %>
|
<% if @forums.first || @memos.first %>
|
||||||
<div class="wmail_main" style="padding:20px 10px 0px;">
|
<div class="wmail_main" style="padding:20px 10px 0px;">
|
||||||
<h2 class="wmail_h2" style="color:#15bccf; "><%= l(:lable_bar_active) %></h2>
|
<h2 class="wmail_h2" style="color:#15bccf; "><%= l(:lable_bar_active) %></h2>
|
||||||
<% unless @forums.first.nil? %>
|
<% unless @forums.first.nil? %>
|
||||||
<ul class="wmail_ul" style="margin-left:10px; border-bottom:1px dashed #cfcfcf; padding-bottom:15px; width:720px; margin-bottom:15px;">
|
<ul class="wmail_ul" style="margin-left:10px; border-bottom:1px dashed #cfcfcf; padding-bottom:15px; width:720px; margin-bottom:15px;">
|
||||||
<h4 class="wmail_h4" style="color:#474646; font-size:14px; margin-bottom:5px;" >
|
<h4 class="wmail_h4" style="color:#474646; font-size:14px; margin-bottom:5px;" >
|
||||||
<%= l(:label_user_forum) %>
|
<%= l(:label_user_forum) %>
|
||||||
<span class="wmail_num" style="color:#fe3f0c; margin-left:5px; font-weight:normal;">(<%= @forums.count %>)</span>
|
<span class="wmail_num" style="color:#fe3f0c; margin-left:5px; font-weight:normal;">(<%= @forums.count %>)</span>
|
||||||
</h4>
|
</h4>
|
||||||
|
|
||||||
<% @forums.each do |forum|%>
|
<% @forums.each do |forum|%>
|
||||||
<li style="clear: both; list-style: none;">
|
<li style="clear: both; list-style: none;">
|
||||||
<span class="wmail_dis" style="float:left; color:#000000; margin-right:5px;">▪</span>
|
<span class="wmail_dis" style="float:left; color:#000000; margin-right:5px;">▪</span>
|
||||||
|
|
||||||
<%= link_to forum.creator, user_activities_url(forum.creator,:token => @token.value),
|
<%= link_to forum.creator, user_activities_url(forum.creator,:token => @token.value),
|
||||||
:class => "wmail_name",
|
:class => "wmail_name",
|
||||||
:style => "color:#fe5722; float:left;display:block; margin-right:5px; margin-left:5px; overflow:hidden; white-space: nowrap; text-overflow:ellipsis;" %>
|
:style => "color:#fe5722; float:left;display:block; margin-right:5px; margin-left:5px; overflow:hidden; white-space: nowrap; text-overflow:ellipsis;" %>
|
||||||
<span class="wmail_txt" style="float:left; margin-right:5px;color:#6e6e6e;"><%= l(:label_forum_new) %></span>
|
<span class="wmail_txt" style="float:left; margin-right:5px;color:#6e6e6e;"><%= l(:label_forum_new) %></span>
|
||||||
|
|
||||||
<%= link_to truncate(forum.name,length: 30,omission: '...'),forum_url(forum,:token => @token.value),
|
<%= link_to truncate(forum.name,length: 30,omission: '...'),forum_url(forum,:token => @token.value),
|
||||||
:class => 'wmail_info',
|
:class => 'wmail_info',
|
||||||
:style => "color:#5a5a5a; float:left; margin-right:5px; display:block;color:#1b55a7;overflow:hidden; white-space: nowrap; text-overflow:ellipsis;"
|
:style => "color:#5a5a5a; float:left; margin-right:5px; display:block;color:#1b55a7;overflow:hidden; white-space: nowrap; text-overflow:ellipsis;"
|
||||||
%>
|
%>
|
||||||
<span class="wmail_date" style="color:#6e6e6e; float:right;display:block; margin-left:10px;"><%= format_time(forum.created_at) %></span></li>
|
<span class="wmail_date" style="color:#6e6e6e; float:right;display:block; margin-left:10px;"><%= format_time(forum.created_at) %></span></li>
|
||||||
|
|
||||||
<% end %>
|
<% end %>
|
||||||
|
|
||||||
<div class="cl"></div>
|
<div class="cl"></div>
|
||||||
</ul><!-- 新建贴吧 end-->
|
</ul><!-- 新建贴吧 end-->
|
||||||
<% end %>
|
<% end %>
|
||||||
<% unless @memos.first.nil? %>
|
<% unless @memos.first.nil? %>
|
||||||
<ul class="wmail_ul" style="margin-left:10px; border-bottom:1px dashed #cfcfcf; padding-bottom:15px; width:720px; margin-bottom:15px;">
|
<ul class="wmail_ul" style="margin-left:10px; border-bottom:1px dashed #cfcfcf; padding-bottom:15px; width:720px; margin-bottom:15px;">
|
||||||
|
@ -366,14 +356,14 @@
|
||||||
<% end %>
|
<% end %>
|
||||||
</div><!--贴吧动态 end-->
|
</div><!--贴吧动态 end-->
|
||||||
<% end %>
|
<% end %>
|
||||||
<div class="wmail_foot" style="margin-top:20px;color:#2775d2; margin-left:10px;">
|
<div class="wmail_foot" style="margin-top:20px;color:#2775d2; margin-left:10px;">
|
||||||
<% [:label_user_mail_option_all, :label_user_mail_option_day, :label_user_mail_option_none].each do |mail_option| %>
|
<% [:label_user_mail_option_all, :label_user_mail_option_day, :label_user_mail_option_none].each do |mail_option| %>
|
||||||
<% if Hash[*User::MAIL_NOTIFICATION_OPTIONS.flatten][@user.mail_notification] == mail_option %>
|
<% if Hash[*User::MAIL_NOTIFICATION_OPTIONS.flatten][@user.mail_notification] == mail_option %>
|
||||||
<label style="margin-top:20px;color:gray; margin-left:10px;"><%= l(mail_option) %></label>
|
<label style="margin-top:20px;color:gray; margin-left:10px;"><%= l(mail_option) %></label>
|
||||||
<% else %>
|
<% else %>
|
||||||
<%= link_to l(mail_option), my_change_mail_notification_url(token: @token.value,mail_notification: Hash[*User::MAIL_NOTIFICATION_OPTIONS.flatten].invert[mail_option]), :style => "margin-top:20px;color:#2775d2; margin-left:10px;" %>
|
<%= link_to l(mail_option), my_change_mail_notification_url(token: @token.value,mail_notification: Hash[*User::MAIL_NOTIFICATION_OPTIONS.flatten].invert[mail_option]), :style => "margin-top:20px;color:#2775d2; margin-left:10px;" %>
|
||||||
<% end %>
|
<% end %>
|
||||||
<% end %>
|
<% end %>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue