| OLD | NEW |
| 1 <!-- | 1 <!-- |
| 2 Copyright 2016 The LUCI Authors. All rights reserved. | 2 Copyright 2016 The LUCI Authors. All rights reserved. |
| 3 Use of this source code is governed under the Apache License, Version 2.0 | 3 Use of this source code is governed under the Apache License, Version 2.0 |
| 4 that can be found in the LICENSE file. | 4 that can be found in the LICENSE file. |
| 5 | 5 |
| 6 This in an HTML Import-able file that contains the definition | 6 This in an HTML Import-able file that contains the definition |
| 7 of the following elements: | 7 of the following elements: |
| 8 | 8 |
| 9 <bot-list-data> | 9 <bot-list-data> |
| 10 | 10 |
| (...skipping 239 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 250 t.tagMap = tagMap; | 250 t.tagMap = tagMap; |
| 251 | 251 |
| 252 TIMES.forEach(function(time) { | 252 TIMES.forEach(function(time) { |
| 253 swarming.sanitizeAndHumanizeTime(t, time); | 253 swarming.sanitizeAndHumanizeTime(t, time); |
| 254 }); | 254 }); |
| 255 // Running tasks have no duration set, so we can figure it out. | 255 // Running tasks have no duration set, so we can figure it out. |
| 256 if (!t.duration && t.state === this.RUNNING && t.started_ts){ | 256 if (!t.duration && t.state === this.RUNNING && t.started_ts){ |
| 257 t.duration = (now - t.started_ts) / 1000; | 257 t.duration = (now - t.started_ts) / 1000; |
| 258 } | 258 } |
| 259 // Make the duration human readable | 259 // Make the duration human readable |
| 260 if (t.duration){ | 260 t.human_duration = this._humanDuration(t.duration); |
| 261 t.human_duration = this._humanDuration(t.duration); | |
| 262 } | |
| 263 }.bind(this)); | 261 }.bind(this)); |
| 264 return json.items; | 262 return json.items; |
| 265 } | 263 } |
| 266 }); | 264 }); |
| 267 })(); | 265 })(); |
| 268 </script> | 266 </script> |
| 269 </dom-module> | 267 </dom-module> |
| OLD | NEW |