mirror of https://github.com/apache/cloudstack.git
migratewizard: Fix fetching jobid from api response (#913)
* migratewizard: Display error and unfreeze form when api call fails * migratewizard: Fix fetching jobid from api response Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
This commit is contained in:
parent
123291fd04
commit
beeb34b007
|
|
@ -153,14 +153,15 @@ export default {
|
|||
hostid: this.selectedHost.id,
|
||||
virtualmachineid: this.resource.id
|
||||
}).then(response => {
|
||||
const jobid = this.selectedHost.requiresStorageMotion ? response.migratevirtualmachinewithvolumeresponse.jobid : response.migratevirtualmachineresponse.jobid
|
||||
this.$store.dispatch('AddAsyncJob', {
|
||||
title: `${this.$t('label.migrating')} ${this.resource.name}`,
|
||||
jobid: response.migratevirtualmachineresponse.jobid,
|
||||
jobid: jobid,
|
||||
description: this.resource.name,
|
||||
status: 'progress'
|
||||
})
|
||||
this.$pollJob({
|
||||
jobId: response.migratevirtualmachineresponse.jobid,
|
||||
jobId: jobid,
|
||||
successMessage: `${this.$t('message.success.migrating')} ${this.resource.name}`,
|
||||
successMethod: () => {
|
||||
this.$parent.$parent.close()
|
||||
|
|
|
|||
Loading…
Reference in New Issue