mirror of
https://github.com/ansible/awx.git
synced 2024-11-02 01:21:21 +03:00
Merge pull request #2762 from kialam/fix-2554-converted-jts-from-sjt
UI WF results relaunch: handle any relaunch errors. Reviewed-by: https://github.com/softwarefactory-project-zuul[bot]
This commit is contained in:
commit
bb1473f67f
@ -5,7 +5,7 @@
|
||||
*************************************************/
|
||||
|
||||
|
||||
export default ['$q', 'Prompt', '$filter', 'Wait', 'Rest', '$state', 'ProcessErrors', 'WorkflowJobModel', '$interval', 'moment', function ($q, Prompt, $filter, Wait, Rest, $state, ProcessErrors, WorkflowJob, $interval, moment) {
|
||||
export default ['$q', 'Prompt', '$filter', 'Wait', 'Rest', '$state', 'ProcessErrors', 'WorkflowJobModel', '$interval', 'moment', 'ComponentsStrings', function ($q, Prompt, $filter, Wait, Rest, $state, ProcessErrors, WorkflowJob, $interval, moment, strings) {
|
||||
var val = {
|
||||
getCounts: function(workflowNodes){
|
||||
var nodeArr = [];
|
||||
@ -113,6 +113,11 @@ export default ['$q', 'Prompt', '$filter', 'Wait', 'Rest', '$state', 'ProcessErr
|
||||
id: scope.workflow.id
|
||||
}).then((launchRes) => {
|
||||
$state.go('workflowResults', { id: launchRes.data.id }, { reload: true });
|
||||
}).catch(({ data, status, config }) => {
|
||||
ProcessErrors(scope, data, status, null, {
|
||||
hdr: strings.get('error.HEADER'),
|
||||
msg: strings.get('error.CALL', { path: `${config.url}`, status })
|
||||
});
|
||||
});
|
||||
},
|
||||
createOneSecondTimer: function(startTime, fn) {
|
||||
|
@ -18,7 +18,7 @@ describe('Controller: workflowResults', () => {
|
||||
|
||||
beforeEach(angular.mock.module('workflowResults', ($provide) => {
|
||||
['PromptDialog', 'Prompt', 'Wait', 'Rest', '$state', 'ProcessErrors',
|
||||
'jobLabels', 'workflowNodes', 'count', 'WorkflowJobModel',
|
||||
'jobLabels', 'workflowNodes', 'count', 'WorkflowJobModel', 'ComponentsStrings'
|
||||
].forEach((item) => {
|
||||
$provide.value(item, {});
|
||||
});
|
||||
|
@ -6,7 +6,7 @@ describe('workflowResultsService', () => {
|
||||
let $interval;
|
||||
|
||||
beforeEach(angular.mock.module('workflowResults', ($provide) => {
|
||||
['PromptDialog', 'Prompt', 'Wait', 'Rest', 'ProcessErrors', '$state', 'WorkflowJobModel']
|
||||
['PromptDialog', 'Prompt', 'Wait', 'Rest', 'ProcessErrors', '$state', 'WorkflowJobModel', 'ComponentsStrings']
|
||||
.forEach(function(item) {
|
||||
$provide.value(item, {});
|
||||
});
|
||||
|
Loading…
Reference in New Issue
Block a user