Files
vikunja/pkg/db/fixtures/task_relations.yml
kolaente ac76bce5cd fix: use recursive CTE in accessibleProjectIDsSubquery for inherited project permissions
Resolves #2490. Users with team access on a parent project were not seeing
subtask relations for tasks in child projects because getUserProjectsStatement
does not walk the project hierarchy. The fix wraps the base query in a
recursive CTE that traverses child projects via parent_project_id.
2026-04-05 12:20:35 +00:00

100 lines
2.1 KiB
YAML

- id: 1
task_id: 1
other_task_id: 29
relation_kind: 'subtask'
created_by_id: 1
created: 2018-12-01 15:13:12
- id: 2
task_id: 29
other_task_id: 1
relation_kind: 'parenttask'
created_by_id: 1
created: 2018-12-01 15:13:12
- id: 3
task_id: 35
other_task_id: 1
relation_kind: 'related'
created_by_id: 1
created: 2018-12-01 15:13:12
- id: 4
task_id: 35
other_task_id: 1
relation_kind: 'related'
created_by_id: 1
created: 2018-12-01 15:13:12
- id: 5
task_id: 36
other_task_id: 1
relation_kind: 'related'
created_by_id: 1
created: 2018-12-01 15:13:12
- id: 6
task_id: 36
other_task_id: 1
relation_kind: 'related'
created_by_id: 1
created: 2018-12-01 15:13:12
- id: 7
task_id: 41
other_task_id: 43
relation_kind: 'subtask'
created_by_id: 15
created: 2018-12-01 15:13:12
- id: 8
task_id: 43
other_task_id: 41
relation_kind: 'parenttask'
created_by_id: 15
created: 2018-12-01 15:13:12
- id: 9
task_id: 41
other_task_id: 44
relation_kind: 'subtask'
created_by_id: 15
created: 2018-12-01 15:13:12
- id: 10
task_id: 44
other_task_id: 41
relation_kind: 'parenttask'
created_by_id: 15
created: 2018-12-01 15:13:12
- id: 11
task_id: 45
other_task_id: 46
relation_kind: 'subtask'
created_by_id: 15
created: 2018-12-01 15:13:12
- id: 12
task_id: 46
other_task_id: 45
relation_kind: 'parenttask'
created_by_id: 15
created: 2018-12-01 15:13:12
# Cross-project relation: task 1 (project 1, user 1) -> task 41 (project 36, user 15)
# User 1 should NOT see task 41 in the related tasks response
- id: 13
task_id: 1
other_task_id: 41
relation_kind: 'related'
created_by_id: 1
created: 2018-12-01 15:13:12
- id: 14
task_id: 41
other_task_id: 1
relation_kind: 'related'
created_by_id: 1
created: 2018-12-01 15:13:12
# Subtask relation: task 49 -> task 50 (cross parent/child project, hierarchy test)
- id: 15
task_id: 49
other_task_id: 50
relation_kind: 'subtask'
created_by_id: 6
created: 2018-12-01 15:13:12
- id: 16
task_id: 50
other_task_id: 49
relation_kind: 'parenttask'
created_by_id: 6
created: 2018-12-01 15:13:12