##// END OF EJS Templates
Project field disappears when target project disallows user to edit the project (#24311)....
Jean-Philippe Lang -
r15577:e6130a1e0d95
parent child
Show More

The requested changes are too big and content was truncated. Show full diff

@@ -1,56 +1,56
1 1 <%= labelled_fields_for :issue, @issue do |f| %>
2 2 <%= call_hook(:view_issues_form_details_top, { :issue => @issue, :form => f }) %>
3 3 <%= hidden_field_tag 'form_update_triggered_by', '' %>
4 4
5 5 <% if @issue.safe_attribute? 'is_private' %>
6 6 <p id="issue_is_private_wrap">
7 7 <%= f.check_box :is_private, :no_label => true %><label class="inline" for="issue_is_private" id="issue_is_private_label"><%= l(:field_is_private) %></label>
8 8 </p>
9 9 <% end %>
10 10
11 <% if @issue.safe_attribute?('project_id') && (!@issue.new_record? || @project.nil? || @issue.copy?) %>
11 <% if (@issue.safe_attribute?('project_id') || @issue.project_id_changed?) && (!@issue.new_record? || @project.nil? || @issue.copy?) %>
12 12 <p><%= f.select :project_id, project_tree_options_for_select(@issue.allowed_target_projects, :selected => @issue.project), {:required => true},
13 13 :onchange => "updateIssueFrom('#{escape_javascript update_issue_form_path(@project, @issue)}', this)" %></p>
14 14 <% end %>
15 15
16 16 <% if @issue.safe_attribute? 'tracker_id' %>
17 17 <p><%= f.select :tracker_id, trackers_options_for_select(@issue), {:required => true},
18 18 :onchange => "updateIssueFrom('#{escape_javascript update_issue_form_path(@project, @issue)}', this)" %></p>
19 19 <% end %>
20 20
21 21 <% if @issue.safe_attribute? 'subject' %>
22 22 <p><%= f.text_field :subject, :size => 80, :maxlength => 255, :required => true %></p>
23 23 <% end %>
24 24
25 25 <% if @issue.safe_attribute? 'description' %>
26 26 <p>
27 27 <%= f.label_for_field :description, :required => @issue.required_attribute?('description') %>
28 28 <%= link_to_function content_tag(:span, l(:button_edit), :class => 'icon icon-edit'), '$(this).hide(); $("#issue_description_and_toolbar").show()' unless @issue.new_record? %>
29 29 <%= content_tag 'span', :id => "issue_description_and_toolbar", :style => (@issue.new_record? ? nil : 'display:none') do %>
30 30 <%= f.text_area :description,
31 31 :cols => 60,
32 32 :rows => [[10, @issue.description.to_s.length / 50].max, 20].min,
33 33 :accesskey => accesskey(:edit),
34 34 :class => 'wiki-edit',
35 35 :no_label => true %>
36 36 <% end %>
37 37 </p>
38 38 <%= wikitoolbar_for 'issue_description' %>
39 39 <% end %>
40 40
41 41 <div id="attributes" class="attributes">
42 42 <%= render :partial => 'issues/attributes' %>
43 43 </div>
44 44
45 45 <%= call_hook(:view_issues_form_details_bottom, { :issue => @issue, :form => f }) %>
46 46 <% end %>
47 47
48 48 <% heads_for_wiki_formatter %>
49 49
50 50 <%= javascript_tag do %>
51 51 $(document).ready(function(){
52 52 $("#issue_tracker_id, #issue_status_id").each(function(){
53 53 $(this).val($(this).find("option[selected=selected]").val());
54 54 });
55 55 });
56 56 <% end %>
1 NO CONTENT: modified file
The requested commit or file is too big and content was truncated. Show full diff
General Comments 0
You need to be logged in to leave comments. Login now