socialforge/app/views/users/_project_issue.html.erb

72 lines
3.8 KiB
Plaintext
Raw Normal View History

2015-12-15 15:00:24 +08:00
<div class="resources mt10" id="user_activity_<%= user_activity_id%>">
<div class="homepagePostBrief">
<div class="homepagePostPortrait">
<%= link_to image_tag(url_to_avatar(activity.author), :width => "50", :height => "50"), user_path(activity.author_id), :alt => "用户头像" %>
<%= render :partial => 'users/show_detail_info', :locals => {:user => activity.author} %>
2015-12-15 15:00:24 +08:00
</div>
<div class="homepagePostDes">
<div class="homepagePostTo break_word mt-4">
<% if activity.try(:author).try(:realname) == ' ' %>
<%= link_to activity.try(:author), user_path(activity.author_id), :class => "newsBlue mr15" %>
<% else %>
<%= link_to activity.try(:author).try(:realname), user_path(activity.author_id), :class => "newsBlue mr15" %>
<% end %> TO
<%= link_to activity.project.name.to_s+" | 项目问题", project_issues_path(activity.project), :class => "newsBlue ml15"%>
</div>
<div class="homepagePostTitle break_word">
2015-12-18 14:38:04 +08:00
<% case activity.tracker_id %>
<% when 1%>
<span class="issues fl" title="缺陷"></span>
<% when 2%>
<span class="function fl" title="功能"></span>
<% when 3%>
<span class="support fl" title="支持"></span>
<% when 4%>
<span class="duty fl" title="任务"></span>
<% when 5%>
<span class="weekly fl" title="周报"></span>
<% end %>
<%= link_to activity.subject.to_s, issue_path(activity), :class => "postGrey ml5" %>
2015-12-15 15:00:24 +08:00
<span class='<%= get_issue_priority(activity.priority_id)[0] %>'>
<%= get_issue_priority(activity.priority_id)[1] %>
</span>
</div>
<div class="homepagePostSubmitContainer">
<div class="homepagePostAssignTo"><span class="fontGrey3">指派给</span>&nbsp;&nbsp;
<% unless activity.assigned_to_id.nil? %>
<% if activity.try(:assigned_to).try(:realname) == ' ' %>
<%= link_to activity.try(:assigned_to), user_path(activity.assigned_to_id), :class => "newsBlue mr15" %>
<% else %>
<%= link_to activity.try(:assigned_to).try(:realname), user_path(activity.assigned_to_id), :class => "newsBlue mr15" %>
<% end %>
<% end %>
</div>
<div class="homepagePostDeadline fl">
发布时间:
2015-12-15 15:00:24 +08:00
<%=format_time(activity.created_on) %>
</div>
<div class="homepagePostDate fl ml15">
更新时间:<%= format_time(ForgeActivity.where("forge_act_type='#{activity.class}' and forge_act_id =#{activity.id}").first.updated_at) %>
</div>
<div class="cl"></div>
2015-12-15 15:00:24 +08:00
</div>
2016-01-19 16:53:34 +08:00
<%=render :partial =>"users/intro_content", :locals=>{:user_activity_id =>user_activity_id, :content=>activity.description} %>
2016-01-20 18:28:27 +08:00
<%# 局部刷新修改xissue属性 %>
2016-01-22 14:21:17 +08:00
<div id="div_user_issue_detail_<%=activity.id %>">
<%= render :partial => 'users/project_issue_detail', :locals => {:activity => activity} %>
</div>
2015-12-15 15:00:24 +08:00
<div class="cl"></div>
<div id="intro_content_show_<%= user_activity_id%>" class="fr" style="display:none;"><a href="javascript:void(0);" class="linkBlue">[展开]</a></div>
<div id="intro_content_hide_<%= user_activity_id%>" class="fr" style="display:none;"><a href="javascript:void(0);" class="linkBlue">[收起]</a></div>
<div class="cl"></div>
<div class="mt10" style="font-weight:normal;">
<%= render :partial=>"attachments/activity_attach", :locals=>{:activity => activity} %>
2015-12-15 15:00:24 +08:00
</div>
</div>
<div class="cl"></div>
</div>
<div id="div_user_issue_reply_<%=user_activity_id%>">
<%= render :partial => 'users/project_issue_reply', :locals => {:activity => activity, :user_activity_id => user_activity_id} %>
2015-12-15 15:00:24 +08:00
</div>
</div>