Mercurial > hg > soundsoftware-site
comparison app/views/issues/.svn/text-base/_relations.rhtml.svn-base @ 0:513646585e45
* Import Redmine trunk SVN rev 3859
author | Chris Cannam |
---|---|
date | Fri, 23 Jul 2010 15:52:44 +0100 |
parents | |
children | 1d32c0a0efbf |
comparison
equal
deleted
inserted
replaced
-1:000000000000 | 0:513646585e45 |
---|---|
1 <div class="contextual"> | |
2 <% if authorize_for('issue_relations', 'new') %> | |
3 <%= toggle_link l(:button_add), 'new-relation-form'%> | |
4 <% end %> | |
5 </div> | |
6 | |
7 <p><strong><%=l(:label_related_issues)%></strong></p> | |
8 | |
9 <% if @issue.relations.any? %> | |
10 <table style="width:100%"> | |
11 <% @issue.relations.select {|r| r.other_issue(@issue).visible? }.each do |relation| %> | |
12 <tr> | |
13 <td><%= l(relation.label_for(@issue)) %> <%= "(#{l('datetime.distance_in_words.x_days', :count => relation.delay)})" if relation.delay && relation.delay != 0 %> | |
14 <%= h(relation.other_issue(@issue).project) + ' - ' if Setting.cross_project_issue_relations? %> | |
15 <%= link_to_issue(relation.other_issue(@issue), :truncate => 60) %> | |
16 </td> | |
17 <td><%= relation.other_issue(@issue).status.name %></td> | |
18 <td><%= format_date(relation.other_issue(@issue).start_date) %></td> | |
19 <td><%= format_date(relation.other_issue(@issue).due_date) %></td> | |
20 <td><%= link_to_remote(image_tag('delete.png'), { :url => {:controller => 'issue_relations', :action => 'destroy', :issue_id => @issue, :id => relation}, | |
21 :method => :post | |
22 }, :title => l(:label_relation_delete)) if authorize_for('issue_relations', 'destroy') %></td> | |
23 </tr> | |
24 <% end %> | |
25 </table> | |
26 <% end %> | |
27 | |
28 <% remote_form_for(:relation, @relation, | |
29 :url => {:controller => 'issue_relations', :action => 'new', :issue_id => @issue}, | |
30 :method => :post, | |
31 :html => {:id => 'new-relation-form', :style => (@relation ? '' : 'display: none;')}) do |f| %> | |
32 <%= render :partial => 'issue_relations/form', :locals => {:f => f}%> | |
33 <% end %> |