<%= labelled_form_for @issue, :html => {:id => 'issue-form', :multipart => true} do |f| %> <%= error_messages_for 'issue', 'time_entry' %> <%= render :partial => 'conflict' if @conflict %>
<% if @edit_allowed || !@allowed_statuses.empty? %>
<%= l(:label_change_properties) %>
<%= render :partial => 'form', :locals => {:f => f} %>
<% end %> <% if User.current.allowed_to?(:log_time, @project) %>
<%= l(:button_log_time) %> <%= labelled_fields_for :time_entry, @time_entry do |time_entry| %>

<%= time_entry.text_field :hours, :size => 6, :label => :label_spent_time %> <%= l(:field_hours) %>

<%= time_entry.select :activity_id, activity_collection_for_select_options %>

<%= time_entry.text_field :comments, :size => 60 %>

<% @time_entry.custom_field_values.each do |value| %>

<%= custom_field_tag_with_label :time_entry, value %>

<% end %> <% end %>
<% end %>
<%= l(:field_notes) %> <%= text_area_tag 'notes', @notes, :cols => 60, :rows => 10, :class => 'wiki-edit' %> <%= wikitoolbar_for 'notes' %> <%= call_hook(:view_issues_edit_notes_bottom, { :issue => @issue, :notes => @notes, :form => f }) %>

<%=l(:label_attachment_plural)%>
<%= render :partial => 'attachments/form', :locals => {:container => @issue} %>

<%= f.hidden_field :lock_version %> <%= hidden_field_tag 'last_journal_id', params[:last_journal_id] || @issue.last_journal_id %> <%= submit_tag l(:button_submit) %> <%= preview_link preview_edit_issue_path(:project_id => @project, :id => @issue), 'issue-form' %> <% end %>