Module: Tracking::Base
Constant Summary
collapse
- TIME_CONVERTERS =
{
'h' => lambda { |estimate| estimate },
'd' => lambda { |estimate| estimate * 8 },
'g' => lambda { |estimate| estimate * 8 },
'p' => lambda { |estimate| estimate / 2 }
}
- DURATION_REGEXP =
'(\d+\.?\d*[phdg])'
- DATE_REGEXP =
/(\d{2})\.(\d{2})\.(\d{4})/
Instance Method Summary
collapse
#authorization_params_from_config_file, #tracker_username
Instance Method Details
#date ⇒ Object
23
24
25
|
# File 'lib/trello_effort_tracker/tracking/base.rb', line 23
def date
Chronic.parse(date_as_string).to_date
end
|
#initialize(tracking_notification) ⇒ Object
19
20
21
|
# File 'lib/trello_effort_tracker/tracking/base.rb', line 19
def initialize(tracking_notification)
@tracking_notification = tracking_notification
end
|
#to_s ⇒ Object
27
28
29
|
# File 'lib/trello_effort_tracker/tracking/base.rb', line 27
def to_s
"[#{date}] From #{notifier.username.color(:green)}\t on card '#{trello_card.name.color(:yellow)}': #{raw_text}"
end
|