summaryrefslogtreecommitdiffstats
path: root/app/views/timelog/edit.rhtml
diff options
context:
space:
mode:
Diffstat (limited to 'app/views/timelog/edit.rhtml')
-rw-r--r--app/views/timelog/edit.rhtml7
1 files changed, 6 insertions, 1 deletions
diff --git a/app/views/timelog/edit.rhtml b/app/views/timelog/edit.rhtml
index 79a95b572..5ab977460 100644
--- a/app/views/timelog/edit.rhtml
+++ b/app/views/timelog/edit.rhtml
@@ -1,6 +1,11 @@
<h2><%= l(:label_spent_time) %></h2>
-<% labelled_tabular_form_for :time_entry, @time_entry, :url => {:action => (@time_entry.new_record? ? 'create' : 'edit'), :id => @time_entry, :project_id => @time_entry.project} do |f| %>
+<% labelled_tabular_form_for(:time_entry, @time_entry, :url => {
+ :action => (@time_entry.new_record? ? 'create' : 'update'),
+ :id => @time_entry,
+ :project_id => @time_entry.project
+ },
+ :html => {:method => @time_entry.new_record? ? :post : :put}) do |f| %>
<%= error_messages_for 'time_entry' %>
<%= back_url_hidden_field_tag %>