diff --git a/app/controllers/timelog_controller.rb b/app/controllers/timelog_controller.rb index 58df1f5..60cc391 100644 --- a/app/controllers/timelog_controller.rb +++ b/app/controllers/timelog_controller.rb @@ -197,6 +197,9 @@ class TimelogController < ApplicationController render_403 and return if @time_entry && !@time_entry.editable_by?(User.current) @time_entry ||= TimeEntry.new(:project => @project, :issue => @issue, :user => User.current, :spent_on => Date.today) @time_entry.attributes = params[:time_entry] + + call_hook(:controller_timelog_edit_before_save, { :params => params, :time_entry => @time_entry }) + if request.post? and @time_entry.save flash[:notice] = l(:notice_successful_update) redirect_back_or_default :action => 'details', :project_id => @time_entry.project