修正了用户列表里“参与了xx个项目”改为“参与了XX个项目”和“参与了XX个课程”
This commit is contained in:
parent
3966e0bc0b
commit
a52944811b
|
@ -116,12 +116,25 @@
|
||||||
|
|
||||||
<div class="user-bottom">
|
<div class="user-bottom">
|
||||||
<% unless user.memberships.empty? %>
|
<% unless user.memberships.empty? %>
|
||||||
<%= l(:label_x_contribute_to, :count => user.memberships.count) %>
|
<% cond = Project.visible_condition(User.current) + "AND projects.project_type <> 1" %>
|
||||||
<% for member in user.memberships %>
|
<% memberships = user.memberships.all(:conditions => cond) %>
|
||||||
|
<%= l(:label_x_contribute_to, :count => memberships.count) %>
|
||||||
|
<% for member in memberships %>
|
||||||
<%= link_to_project(member.project) %><%= (user.memberships.last == member) ? '' : ',' %>
|
<%= link_to_project(member.project) %><%= (user.memberships.last == member) ? '' : ',' %>
|
||||||
<% end %>
|
<% end %>
|
||||||
<% end %>
|
<% end %>
|
||||||
<%= user.changesets.count == 0 ? '' : ",#{l(:label_x_total_commit, :count => user.changesets.count)}" %>
|
|
||||||
|
<p><% unless user.memberships.empty? %>
|
||||||
|
<% cond = Project.visible_condition(User.current) + "AND projects.project_type = 1" %>
|
||||||
|
<% memberships = user.memberships.all(:conditions => cond) %>
|
||||||
|
<%= l(:label_x_course_contribute_to, :count => memberships.count) %>
|
||||||
|
<% for member in memberships %>
|
||||||
|
<%= link_to_project(member.project) %><%= (user.memberships.last == member) ? '' : ',' %>
|
||||||
|
<% end %>
|
||||||
|
<% end %>
|
||||||
|
</p>
|
||||||
|
|
||||||
|
<%= user.changesets.count == 0 ? '' : "#{l(:label_x_total_commit, :count => user.changesets.count)}" %>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<% end -%>
|
<% end -%>
|
||||||
|
|
|
@ -1572,6 +1572,11 @@ zh:
|
||||||
label_class_period: 整体课时
|
label_class_period: 整体课时
|
||||||
label_class_hour: 学时
|
label_class_hour: 学时
|
||||||
|
|
||||||
|
label_course_contribute_to: 参与了 %{project_count} 个项目:
|
||||||
|
label_x_course_contribute_to:
|
||||||
|
zero: "参与了 %{count} 个课程:"
|
||||||
|
one: "参与了 %{count} 个课程:"
|
||||||
|
other: "参与了 %{count} 个课程:"
|
||||||
|
|
||||||
#end
|
#end
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue