mirror of
https://github.com/redmine/redmine.git
synced 2025-12-17 05:50:29 +01:00
cleanup: rubocop: fix Layout/BlockAlignment in app/models/time_entry.rb
git-svn-id: http://svn.redmine.org/redmine/trunk@19028 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
@@ -14,13 +14,6 @@
|
|||||||
Layout/AlignHash:
|
Layout/AlignHash:
|
||||||
Enabled: false
|
Enabled: false
|
||||||
|
|
||||||
# Cop supports --auto-correct.
|
|
||||||
# Configuration parameters: EnforcedStyleAlignWith.
|
|
||||||
# SupportedStylesAlignWith: either, start_of_block, start_of_line
|
|
||||||
Layout/BlockAlignment:
|
|
||||||
Exclude:
|
|
||||||
- 'app/models/time_entry.rb'
|
|
||||||
|
|
||||||
# Cop supports --auto-correct.
|
# Cop supports --auto-correct.
|
||||||
Layout/BlockEndNewline:
|
Layout/BlockEndNewline:
|
||||||
Exclude:
|
Exclude:
|
||||||
|
|||||||
@@ -28,11 +28,12 @@ class TimeEntry < ActiveRecord::Base
|
|||||||
belongs_to :activity, :class_name => 'TimeEntryActivity'
|
belongs_to :activity, :class_name => 'TimeEntryActivity'
|
||||||
|
|
||||||
acts_as_customizable
|
acts_as_customizable
|
||||||
acts_as_event :title => Proc.new { |o|
|
acts_as_event :title =>
|
||||||
related = o.issue if o.issue && o.issue.visible?
|
Proc.new {|o|
|
||||||
related ||= o.project
|
related = o.issue if o.issue && o.issue.visible?
|
||||||
"#{l_hours(o.hours)} (#{related.event_title})"
|
related ||= o.project
|
||||||
},
|
"#{l_hours(o.hours)} (#{related.event_title})"
|
||||||
|
},
|
||||||
:url => Proc.new {|o| {:controller => 'timelog', :action => 'index', :project_id => o.project, :issue_id => o.issue}},
|
:url => Proc.new {|o| {:controller => 'timelog', :action => 'index', :project_id => o.project, :issue_id => o.issue}},
|
||||||
:author => :user,
|
:author => :user,
|
||||||
:group => :issue,
|
:group => :issue,
|
||||||
|
|||||||
Reference in New Issue
Block a user