Method: Doing::WWID#get_interval
- Defined in:
-
lib/doing/wwid/timers.rb,
lib/doing/wwid/timers.rb
Gets the interval between entry's start date and @done date
152 153 154 155 156 157 158 159 160 161 162 |
# File 'lib/doing/wwid/timers.rb', line 152 def get_interval(item, formatted: true, record: true) if item.interval seconds = item.interval record_tag_times(item, seconds) if record return seconds.positive? ? seconds : false unless formatted return seconds.positive? ? seconds.time_string(format: :clock) : false end false end |