mirror of
https://github.com/shumaiOne/shumai.git
synced 2026-11-24 04:08:40 +00:00
feat(kanban): update task status permissions, reporter defaults, and participant access (#345)
* feat(kanban): allow editors to change task status and default reporter to creator * fix(kanban): hide create task button for reviewers and eliminate duplicate error toast
This commit is contained in:
@@ -123,7 +123,7 @@ const route = new Hono<{ Variables: { user: User } }>()
|
||||
})
|
||||
|
||||
const existing = await kanbanService.getTask(taskId)
|
||||
const role = await resolveEffectiveRole(teamId, undefined, user.id)
|
||||
const role = await resolveEffectiveRole(teamId, existing.projectId ?? undefined, user.id)
|
||||
const task = await kanbanService.updateTask(taskId, req, user.id, role)
|
||||
|
||||
const hasMeaningfulChanges =
|
||||
@@ -210,8 +210,8 @@ const route = new Hono<{ Variables: { user: User } }>()
|
||||
id: taskId,
|
||||
})
|
||||
|
||||
const role = await resolveEffectiveRole(teamId, undefined, user.id)
|
||||
const existing = await kanbanService.getTask(taskId)
|
||||
const role = await resolveEffectiveRole(teamId, existing.projectId ?? undefined, user.id)
|
||||
|
||||
notificationService.notifyKanbanTaskEvent({
|
||||
type: 'kanban_task_deleted',
|
||||
|
||||
Reference in New Issue
Block a user