Skip to content
Snippets Groups Projects
Commit adf49470 authored by Nithya Santhanam's avatar Nithya Santhanam
Browse files

Workflow Issue

TMSS-998: Fixed issue opening wrong workflow view from workflow list.
Task drafts only in SU draft view
TMSS-993: Showing only Task drafts in SU draft view.
parent cba24483
No related branches found
No related tags found
2 merge requests!634WIP: COBALT commissioning delta,!566Resolves TMSS-938
...@@ -481,30 +481,6 @@ class ViewSchedulingUnit extends Component { ...@@ -481,30 +481,6 @@ class ViewSchedulingUnit extends Component {
scheduletask.type_value = task.specifications_template.type_value; scheduletask.type_value = task.specifications_template.type_value;
scheduletask.produced_by = task.produced_by; scheduletask.produced_by = task.produced_by;
scheduletask.produced_by_ids = task.produced_by_ids; scheduletask.produced_by_ids = task.produced_by_ids;
for (const blueprint of task['task_blueprints']) {
let taskblueprint = {};
taskblueprint['tasktype'] = 'Blueprint';
taskblueprint['actionpath'] = '/task/view/blueprint/' + blueprint['id'];
taskblueprint['blueprint_draft'] = this.getLinksList(blueprint['draft_id'], 'draft');;
taskblueprint['status'] = blueprint['status'];
for (const key of commonkeys) {
taskblueprint[key] = blueprint[key];
}
taskblueprint['created_at'] = moment(blueprint['created_at'], moment.ISO_8601).format(UIConstants.CALENDAR_DATETIME_FORMAT);
taskblueprint['updated_at'] = moment(blueprint['updated_at'], moment.ISO_8601).format(UIConstants.CALENDAR_DATETIME_FORMAT);
taskblueprint.duration = moment.utc((taskblueprint.duration || 0) * 1000).format(UIConstants.CALENDAR_TIME_FORMAT);
taskblueprint.relative_start_time = moment.utc(taskblueprint.relative_start_time * 1000).format(UIConstants.CALENDAR_TIME_FORMAT);
taskblueprint.relative_stop_time = moment.utc(taskblueprint.relative_stop_time * 1000).format(UIConstants.CALENDAR_TIME_FORMAT);
taskblueprint.template = scheduletask.template;
taskblueprint.subTasks = blueprint.subtasks;
for (const subtask of taskblueprint.subTasks) {
subtask.subTaskTemplate = _.find(this.subtaskTemplates, ['id', subtask.specifications_template_id]);
}
//Add Blue print details to array
scheduletasklist.push(taskblueprint);
}
//Add Task Draft details to array //Add Task Draft details to array
scheduletasklist.push(scheduletask); scheduletasklist.push(scheduletask);
} }
......
...@@ -182,7 +182,7 @@ class WorkflowList extends Component{ ...@@ -182,7 +182,7 @@ class WorkflowList extends Component{
}); });
assignedTo = assignedTo.slice(0, -2); assignedTo = assignedTo.slice(0, -2);
wfSU['assignedTo'] = assignedTo; */ wfSU['assignedTo'] = assignedTo; */
wfSU['actionpath'] = `/schedulingunit/${wfSU.id}/workflow`; wfSU['actionpath'] = `/schedulingunit/${wfSU.su}/workflow`;
workflowProcessList.push(wfSU); workflowProcessList.push(wfSU);
} }
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment