Content
View differences
Updated by Oliver Günther almost 6 years ago
* Add "subtasks" type action board
* Each column will contain a work package
* The cards in the column are filtered to show only the selected work package's children
* All work packages in the project that are elligable to be a parent may be selected as a column (no milestones)
* Work packages can be dragged and dropped between parents
**Open for discussion**
* ~~Permission Permission handling if selected work package is located in a subproject~~ only subproject
**Related pull request**: https://github.com/opf/openproject/pull/8504
**Notes**
* Create a new action service
* To change the parent relation: frontend/src/app/components/wp-relations/wp-relations-hierarchy/wp-relations-hierarchy.service.ts
* Column creation modal should contain a typeahead
**TODO**
* [ ] Oliver:
* [ ] Why putFromPromiseIfPristine on subtasks-action.service?
* [ ] What is subtask input for?
* [x] Upgrade account to have access to boards
* [x] Translation not shown (missing "en.js.boards.board\_type.action\_type.subtask")
**MORE INFO**
You will need two things:
1. The actual filter value for the columns, this is `parent = <selected ID for the colum>` meaning: Give me all children of <selected ID>
2. The applicable work packages. This will be all work packages from in the current project can that CAN be selected a parent. Which is every work package except for milestones
**Related pull request**: https://github.com/opf/openproject/pull/8504 ~~The second one is a bit more complicated. You will have to~~
* ~~Load all Types to find out the IDs of all types which are not milestones~~
* ~~Load all work packages in the current project which have a type ID contained in one of the above~~
~~The first one: Inject~~ `~~TypeDmService~~` ~~and get the types~~ `~~typeDmService.loadAll().then(types => types.filter(type => !type.isMilestone))~~` ~~(this should be moved into a \`TypeCacheService\` but there isn't one at the momentThe second one then is rather easy~~
~~this.halResourceService~~
~~.get(~~
~~this.pathHelper.api.v3.withOptionalProject(currentProjectId).work\_packages.toPath()~~
~~{ filters: buildApiV3Filter('type', '=', types.map(type => type.id)).toJson() }~~
~~)~~
~~it calls a~~ `~~GET /api/v3/projects/<current project id>/work_packages?filter=[{ type: { operator: '=', values: [1,2,3...] }]~~`
~~and this will get all work packages of the project that are eligable to be a parent - they might also already be a parent but that shouldn't matter (editado)~~
Finding out all applicable parents is easy now with the `is_milestone` filter.
now the problem is that this call might result in a large number of work packages, which is why in the Add List ... Modal we need to use this query with an autocompleter
* Each column will contain a work package
* The cards in the column are filtered to show only the selected work package's children
* All work packages in the project that are elligable to be a parent may be selected as a column (no milestones)
* Work packages can be dragged and dropped between parents
**Open for discussion**
* ~~Permission
**Related pull request**: https://github.com/opf/openproject/pull/8504
**Notes**
* Create a new action service
* To change the parent relation: frontend/src/app/components/wp-relations/wp-relations-hierarchy/wp-relations-hierarchy.service.ts
* Column creation modal should contain a typeahead
**TODO**
* [ ] Oliver:
* [ ] Why putFromPromiseIfPristine on subtasks-action.service?
* [ ] What is subtask input for?
* [x] Upgrade account to have access to boards
* [x] Translation not shown (missing "en.js.boards.board\_type.action\_type.subtask")
**MORE INFO**
You will need two things:
1. The actual filter value for the columns, this is `parent = <selected ID for the colum>` meaning: Give me all children of <selected ID>
2. The applicable
**Related pull request**: https://github.com/opf/openproject/pull/8504
* ~~Load all Types to find out the IDs of all types which are not milestones~~
* ~~Load all work packages in the current project which have a type ID contained in one of the above~~
~~The first one: Inject~~ `~~TypeDmService~~` ~~and get the types~~ `~~typeDmService.loadAll().then(types => types.filter(type => !type.isMilestone))~~` ~~(this should be moved into a \`TypeCacheService\` but there isn't one at the momentThe second one then is rather easy~~
~~this.halResourceService~~
~~.get(~~
~~this.pathHelper.api.v3.withOptionalProject(currentProjectId).work\_packages.toPath()~~
~~{ filters: buildApiV3Filter('type', '=', types.map(type => type.id)).toJson() }~~
~~)~~
~~it calls a~~ `~~GET /api/v3/projects/<current project id>/work_packages?filter=[{ type: { operator: '=', values: [1,2,3...] }]~~`
~~and this will get all work packages of the project that are eligable to be a parent - they might also already be a parent but that shouldn't matter (editado)~~
Finding out all applicable parents is easy now with the `is_milestone` filter.
now the problem is that this call might result in a large number of work packages, which is why in the Add List ... Modal we need to use this query with an autocompleter