Merge branch 'szzh' into develop

This commit is contained in:
sw 2015-06-26 17:06:28 +08:00
commit 1ad96c1654
8 changed files with 44 additions and 35 deletions

View File

@ -1,6 +1,6 @@
#added by baiyu #added by baiyu
class GitUsageController < ApplicationController class GitUsageController < ApplicationController
layout "base_projects" layout "new_base"
def ch_usage def ch_usage
end end

View File

@ -35,7 +35,7 @@ module CoursesHelper
#生成课程老师成员链接 #生成课程老师成员链接
def course_teacher_link teacher_num def course_teacher_link teacher_num
if User.current.member_of_course?(@course) if User.current.member_of_course?(@course) || User.current.admin?
link_to "#{teacher_num}", course_member_path(@course, :role => 1), :class => 'info_foot_num c_blue' link_to "#{teacher_num}", course_member_path(@course, :role => 1), :class => 'info_foot_num c_blue'
else else
content_tag 'span',teacher_num, :class => 'info_foot_num c_blue' content_tag 'span',teacher_num, :class => 'info_foot_num c_blue'
@ -44,7 +44,7 @@ module CoursesHelper
#生成课程学生列表连接 #生成课程学生列表连接
def course_student_link student_num def course_student_link student_num
if (User.current.logged? && @course.open_student == 1) || (User.current.member_of_course?(@course)) if (User.current.logged? && @course.open_student == 1) || (User.current.member_of_course?(@course)) || User.current.admin?
link_to "#{student_num}", course_member_path(@course, :role => 2), :class => 'info_foot_num c_blue' link_to "#{student_num}", course_member_path(@course, :role => 2), :class => 'info_foot_num c_blue'
else else
content_tag 'span',student_num, :class => 'info_foot_num c_blue' content_tag 'span',student_num, :class => 'info_foot_num c_blue'

View File

@ -18,6 +18,7 @@
<p> <p>
<%= journal.notes.html_safe %> <%= journal.notes.html_safe %>
</p> </p>
<div class="cl"></div>
</div> </div>
<div class="ping_disfoot"> <div class="ping_disfoot">
<% ids = 'project_respond_form_'+ journal.id.to_s%> <% ids = 'project_respond_form_'+ journal.id.to_s%>

View File

@ -4,7 +4,10 @@
<% if memos.any? %> <% if memos.any? %>
<% memos.each do |topic| %> <% memos.each do |topic| %>
<table class="content-text-list"> <table class="content-text-list">
<tr><td colspan="2" valign="top" width="50" ><%= link_to image_tag(url_to_avatar(topic.author), :class => "avatar"), user_path(topic.author) if topic.author%></td> <tr>
<td colspan="2" valign="top" style="width: 50px;">
<%= link_to image_tag(url_to_avatar(topic.author), :class => "avatar"), user_path(topic.author) if topic.author%>
</td>
<td> <td>
<table width="630px" border="0"> <table width="630px" border="0">
<tr> <tr>
@ -33,7 +36,8 @@
<br /> <br />
</span></td> </span></td>
</tr> </tr>
</table></td> </table>
</td>
</tr> </tr>
</table> </table>
<% end %> <% end %>

View File

@ -49,7 +49,7 @@
:style => "color:#2E8DD7; float:left;display:block; margin-right:5px; margin-left:5px; overflow:hidden; white-space: nowrap; text-overflow:ellipsis;"%> :style => "color:#2E8DD7; 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:#ACAEB1;"><%= l(:label_project_notice_reply) %></span> <span class="wmail_txt" style="float:left; margin-right:5px;color:#ACAEB1;"><%= l(:label_project_notice_reply) %></span>
<%= link_to truncate(course_news_comment.comments.html_safe,length: 30,omission: '...'), news_url(course_news_comment.commented,:token => @token.value), <%= link_to truncate(l(:label_course_notice_point),length: 30,omission: '...'), news_url(course_news_comment.commented,:token => @token.value),
:class => 'wmail_info', :class => 'wmail_info',
:style => "color:#2E8DD7;float:left; font-weight:normal;margin-right:5px; display:block;overflow:hidden; white-space: nowrap; text-overflow:ellipsis;" :style => "color:#2E8DD7;float:left; font-weight:normal;margin-right:5px; display:block;overflow:hidden; white-space: nowrap; text-overflow:ellipsis;"
%> %>
@ -342,7 +342,7 @@
:style => "color:#2E8DD7; float:left;display:block; margin-right:5px; margin-left:5px; overflow:hidden; white-space: nowrap; text-overflow:ellipsis;"%> :style => "color:#2E8DD7; 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:#ACAEB1;"><%= l(:lable_project_mail_notice_reply) %></span> <span class="wmail_txt" style="float:left; margin-right:5px;color:#ACAEB1;"><%= l(:lable_project_mail_notice_reply) %></span>
<%= link_to truncate(project_news_comment.comments.html_safe,length: 30,omission: '...'), news_url(project_news_comment.commented,:token => @token.value), <%= link_to truncate(l(:lable_project_notice_point),length: 30,omission: '...'), news_url(project_news_comment.commented,:token => @token.value),
:class => 'wmail_info', :class => 'wmail_info',
:style => "color:#2E8DD7;float:left; font-weight:normal;margin-right:5px; display:block;overflow:hidden; white-space: nowrap; text-overflow:ellipsis;" %> :style => "color:#2E8DD7;float:left; font-weight:normal;margin-right:5px; display:block;overflow:hidden; white-space: nowrap; text-overflow:ellipsis;" %>
<span class="wmail_date" style="color:#6e6e6e; float:left;display:block; margin-left:40px;"><%= format_time(project_news_comment.created_on) %></span> <span class="wmail_date" style="color:#6e6e6e; float:left;display:block; margin-left:40px;"><%= format_time(project_news_comment.created_on) %></span>

View File

@ -24,6 +24,7 @@
<p> <p>
<%= reply.notes.html_safe %> <%= reply.notes.html_safe %>
</p> </p>
<div class="cl"></div>
<span class="c_grey fl"> <span class="c_grey fl">
<%= format_time reply.created_on %> <%= format_time reply.created_on %>
</span> </span>

View File

@ -784,6 +784,8 @@ zh:
label_project_newshare: "分享了" label_project_newshare: "分享了"
label_project_notice: "发布了通知:" label_project_notice: "发布了通知:"
label_project_notice_reply: "回复了通知:" label_project_notice_reply: "回复了通知:"
label_course_notice_point: "通知有了新的回复!"
lable_project_notice_point: "新闻有了新的回复!"
label_project_mail_notice: "发布了新闻:" label_project_mail_notice: "发布了新闻:"
lable_project_mail_notice_reply: "回复了新闻:" lable_project_mail_notice_reply: "回复了新闻:"
label_project_issue: "发布了问题:" label_project_issue: "发布了问题:"

View File

@ -1635,6 +1635,7 @@ img.avatar {
display: block; display: block;
width: 38px; width: 38px;
height: 38px; height: 38px;
max-width: none;
} }