|
@@ -143,7 +143,7 @@ App.WizardStep14Controller = Em.Controller.extend({
|
|
|
if (this.get('tasks')[0].status == 'INITIALIZE') {
|
|
|
this.stopService();
|
|
|
}
|
|
|
- else if (this.get('tasks')[1].status == 'INITIALIZE') {
|
|
|
+ else if (this.taskIsReady(1)) {
|
|
|
this.createMasterComponent();
|
|
|
}
|
|
|
else if (this.taskIsReady(2)) {
|
|
@@ -175,8 +175,7 @@ App.WizardStep14Controller = Em.Controller.extend({
|
|
|
if (this.get('tasks')[task].status != 'INITIALIZE') {
|
|
|
return false;
|
|
|
}
|
|
|
- var startIndex = (task == 4) ? 0 : 1;
|
|
|
- var tempArr = this.get('tasks').mapProperty('status').slice(startIndex, task).uniq();
|
|
|
+ var tempArr = this.get('tasks').mapProperty('status').slice(0, task).uniq();
|
|
|
return tempArr.length == 1 && tempArr[0] == 'COMPLETED';
|
|
|
},
|
|
|
|
|
@@ -756,9 +755,9 @@ App.WizardStep14Controller = Em.Controller.extend({
|
|
|
this.setTasksStatus(task, 'COMPLETED');
|
|
|
}
|
|
|
stopPolling = true;
|
|
|
- } else if (polledData.someProperty('Tasks.status', 'IN_PROGRESS')) {
|
|
|
- if (task == 5) {
|
|
|
- this.get('tasks')[5].set('progress', 50);
|
|
|
+ } else {
|
|
|
+ if (polledData.length == 1) {
|
|
|
+ this.get('tasks')[task].set('progress', 50);
|
|
|
} else {
|
|
|
var progress = polledData.filterProperty('Tasks.status', 'COMPLETED').length / polledData.length * 100;
|
|
|
this.get('tasks')[task].set('progress', Math.round(progress));
|