Patch #730 » ticketize-new-issue.patch
| app/views/issues/_form.rhtml | ||
|---|---|---|
|
<% if @issue.new_record? %>
|
||
|
<div class="issue new">
|
||
|
<p><%= f.select :tracker_id, @project.trackers.collect {|t| [t.name, t.id]}, :required => true %></p>
|
||
|
<%= observe_field :issue_tracker_id, :url => { :action => :new },
|
||
|
:update => :content,
|
||
|
:with => "Form.serialize('issue-form')" %>
|
||
|
<hr />
|
||
|
<% end %>
|
||
|
<div id="issue_descr_fields" <%= 'style="display:none"' unless @issue.new_record? || @issue.errors.any? %>>
|
||
| ... | ... | |
|
<p id="attachments_p"><label for="attachment_file"><%=l(:label_attachment)%>
|
||
|
<%= image_to_function "add.png", "addFileField();return false" %></label>
|
||
|
<%= file_field_tag 'attachments[]', :size => 30 %> <em>(<%= l(:label_max_size) %>: <%= number_to_human_size(Setting.attachment_max_size.to_i.kilobytes) %>)</em></p>
|
||
|
</div>
|
||
|
<% end %>
|
||
|
<%= wikitoolbar_for 'issue_description' %>
|
||
| app/views/issues/new.rhtml | ||
|---|---|---|
|
<% labelled_tabular_form_for :issue, @issue,
|
||
|
:html => {:multipart => true, :id => 'issue-form'} do |f| %>
|
||
|
<%= error_messages_for 'issue' %>
|
||
|
<div class="box">
|
||
|
<%= render :partial => 'issues/form', :locals => {:f => f} %>
|
||
|
</div>
|
||
|
<%= submit_tag l(:button_create) %>
|
||
|
<%= link_to_remote l(:label_preview),
|
||
|
{ :url => { :controller => 'issues', :action => 'preview', :project_id => @project, :id => @issue },
|
||