Skip to content

Commit

Permalink
Fix todolists and order steps on the project management page in the o…
Browse files Browse the repository at this point in the history
…rder in which they were created (#692)

* Trigger angular scope apply when Promise.all resolves

* Order the task creation by id

Co-authored-by: Aditya Bharadwaj <aditya@b12.io>
Co-authored-by: paopow <ksiangliulue@gmail.com>
  • Loading branch information
3 people committed Oct 7, 2020
1 parent a10355f commit e2c9930
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 1 deletion.
1 change: 1 addition & 0 deletions orchestra/static/dist/main.js
Original file line number Diff line number Diff line change
Expand Up @@ -66740,6 +66740,7 @@ function todoList(orchestraApi) {
todoList.todoQas = todoQas;
todoList.todos = todoList.transformToTree(todos);
todoList.ready = true;
$scope.$apply();
});
});
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -162,6 +162,7 @@ export default function todoList (orchestraApi) {
todoList.todoQas = todoQas
todoList.todos = todoList.transformToTree(todos)
todoList.ready = true
$scope.$apply()
})
})
}
Expand Down
2 changes: 1 addition & 1 deletion orchestra/utils/task_lifecycle.py
Original file line number Diff line number Diff line change
Expand Up @@ -1198,7 +1198,7 @@ def create_subsequent_tasks(project):
The modified project object.
"""
workflow_version = project.workflow_version
all_steps = workflow_version.steps.all()
all_steps = workflow_version.steps.all().order_by('id')

# get all completed tasks associated with a given project
completed_tasks = Task.objects.filter(status=Task.Status.COMPLETE,
Expand Down

0 comments on commit e2c9930

Please sign in to comment.