Fix some of the issues with duration sometimes not showing up
* duration was not actually defined in Travis.Job, which may have caused bugs when combined with partial record loading (so for example it was ok on a refresh, but may have been broken on update) * notStarted was not a dependency of duration
This commit is contained in:
parent
615edb5686
commit
2ccade46a4
assets/scripts/app/models
|
@ -6,7 +6,7 @@ Travis.DurationCalculations = Ember.Mixin.create
|
||||||
duration
|
duration
|
||||||
else
|
else
|
||||||
Travis.Helpers.durationFrom(@get('startedAt'), @get('finishedAt'))
|
Travis.Helpers.durationFrom(@get('startedAt'), @get('finishedAt'))
|
||||||
).property('_duration', 'finishedAt', 'startedAt')
|
).property('_duration', 'finishedAt', 'startedAt', 'notStarted')
|
||||||
|
|
||||||
updateTimes: ->
|
updateTimes: ->
|
||||||
unless @get('isFinished')
|
unless @get('isFinished')
|
||||||
|
|
|
@ -21,6 +21,7 @@ require 'travis/model'
|
||||||
annotations: Ember.hasMany('Travis.Annotation')
|
annotations: Ember.hasMany('Travis.Annotation')
|
||||||
|
|
||||||
_config: Ember.attr('object', key: 'config')
|
_config: Ember.attr('object', key: 'config')
|
||||||
|
_duration: Ember.attr(Number, key: 'duration')
|
||||||
|
|
||||||
log: ( ->
|
log: ( ->
|
||||||
@set('isLogAccessed', true)
|
@set('isLogAccessed', true)
|
||||||
|
|
Loading…
Reference in New Issue
Block a user