2018-01-25 22:18:53 +00:00
|
|
|
import AbstractJobPage from './abstract';
|
2018-01-26 22:32:11 +00:00
|
|
|
import { inject as service } from '@ember/service';
|
2018-01-25 22:18:53 +00:00
|
|
|
|
2018-01-26 22:32:11 +00:00
|
|
|
export default AbstractJobPage.extend({
|
|
|
|
store: service(),
|
2018-03-21 00:44:16 +00:00
|
|
|
|
|
|
|
errorMessage: '',
|
|
|
|
|
2018-01-26 22:32:11 +00:00
|
|
|
actions: {
|
|
|
|
forceLaunch() {
|
|
|
|
this.get('job')
|
|
|
|
.forcePeriodic()
|
2018-03-21 00:44:16 +00:00
|
|
|
.catch(error => {
|
|
|
|
this.set('errorMessage', `Could not force launch: ${error}`);
|
2018-01-26 22:32:11 +00:00
|
|
|
});
|
|
|
|
},
|
2018-03-21 00:44:16 +00:00
|
|
|
clearErrorMessage() {
|
|
|
|
this.set('errorMessage', '');
|
|
|
|
},
|
2018-01-26 22:32:11 +00:00
|
|
|
},
|
|
|
|
});
|