summaryrefslogtreecommitdiffstats
path: root/app/views/issue_relations
diff options
context:
space:
mode:
authorGo MAEDA <maeda@farend.jp>2020-12-25 02:25:41 +0000
committerGo MAEDA <maeda@farend.jp>2020-12-25 02:25:41 +0000
commit30e80d82ce189b4232e143b054f78870afd076da (patch)
tree5fe7e869f72af34cf6af07e1e0e1d5cadbdbdd99 /app/views/issue_relations
parentd11f8edc2d87ae1c0db8cbdfb0dd101d9cb5c645 (diff)
downloadredmine-30e80d82ce189b4232e143b054f78870afd076da.tar.gz
redmine-30e80d82ce189b4232e143b054f78870afd076da.zip
Bulk addition of related issues (#33418).
Patch by Dmitry Makurin and Marius BALTEANU. git-svn-id: http://svn.redmine.org/redmine/trunk@20689 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'app/views/issue_relations')
-rw-r--r--app/views/issue_relations/_form.html.erb15
1 files changed, 12 insertions, 3 deletions
diff --git a/app/views/issue_relations/_form.html.erb b/app/views/issue_relations/_form.html.erb
index 3a1018c1b..5987ac7f8 100644
--- a/app/views/issue_relations/_form.html.erb
+++ b/app/views/issue_relations/_form.html.erb
@@ -1,7 +1,16 @@
-<%= error_messages_for 'relation' %>
-
+<% unsaved_relations_ids = '' %>
+<% if @unsaved_relations && @unsaved_relations.any? %>
+ <% unsaved_relations_ids = @unsaved_relations.map(&:issue_to_id).compact.join(", ") %>
+ <div id="errorExplanation">
+ <ul>
+ <% relation_error_messages(@unsaved_relations).each do |message| %>
+ <li><%= message %></li>
+ <% end %>
+ </ul>
+ </div>
+<% end %>
<p><%= f.select :relation_type, collection_for_relation_type_select, {}, :onchange => "setPredecessorFieldsVisibility();" %>
-<%= l(:label_issue) %> #<%= f.text_field :issue_to_id, :size => 10 %>
+<%= l(:label_issue) %> #<%= f.text_field :issue_to_id, :value => unsaved_relations_ids, :size => 10 %>
<span id="predecessor_fields" style="display:none;">
<%= l(:field_delay) %>: <%= f.text_field :delay, :size => 3 %> <%= l(:label_day_plural) %>
</span>