Merge pull request #2546 from marshmalien/fix/2206-relaunch-text-translation

Send relaunch value instead of name in POST request
This commit is contained in:
Marliana Lara
2018-07-16 13:26:52 -04:00
committed by GitHub

View File

@@ -81,7 +81,7 @@ function atRelaunchCtrl (
}, },
launchOptions: launchOptions.data, launchOptions: launchOptions.data,
job: vm.job.id, job: vm.job.id,
relaunchHostType: option ? (option.name).toLowerCase() : null, relaunchHostType: option ? (option.value) : null,
prompts: { prompts: {
credentials: { credentials: {
value: populatedJob.summary_fields.credentials ? value: populatedJob.summary_fields.credentials ?
@@ -125,9 +125,9 @@ function atRelaunchCtrl (
id: vm.job.id, id: vm.job.id,
}; };
if (_.has(option, 'name')) { if (_.has(option, 'value')) {
launchParams.relaunchData = { launchParams.relaunchData = {
hosts: (option.name).toLowerCase() hosts: option.value
}; };
} }
@@ -155,11 +155,13 @@ function atRelaunchCtrl (
vm.dropdownOptions = [ vm.dropdownOptions = [
{ {
name: strings.get('relaunch.ALL'), name: strings.get('relaunch.ALL'),
icon: 'icon-host-all' icon: 'icon-host-all',
value: 'all'
}, },
{ {
name: strings.get('relaunch.FAILED'), name: strings.get('relaunch.FAILED'),
icon: 'icon-host-failed' icon: 'icon-host-failed',
value: 'failed'
} }
]; ];