feat(16-03): update all three KanbanBoard call sites to pass etapes

- tablos.templ TasksTabFragment: add etapes as 5th argument to @KanbanBoard
- handlers_tasks.go reorder (single): capture etapes from loadTasksTabData; pass to KanbanBoard
- handlers_tasks.go reorder (batch): capture etapes from loadTasksTabData; pass to KanbanBoard
- go build ./backend/... exits 0; go test ./backend/internal/web/... -count=1 passes
This commit is contained in:
Arthur Belleville 2026-05-16 23:42:46 +02:00
parent 084fc0ebba
commit e2ee4349f8
No known key found for this signature in database
2 changed files with 5 additions and 5 deletions

View file

@ -586,12 +586,12 @@ func TaskReorderHandler(deps TasksDeps) http.HandlerFunc {
}
}
}
tasks, _, _, filter, ok := loadTasksTabData(w, r, deps.Queries, tablo)
tasks, etapes, _, filter, ok := loadTasksTabData(w, r, deps.Queries, tablo)
if !ok {
return
}
w.Header().Set("Content-Type", "text/html; charset=utf-8")
_ = templates.KanbanBoard(tablo.ID, csrf.Token(r), tasks, filter).Render(ctx, w)
_ = templates.KanbanBoard(tablo.ID, csrf.Token(r), tasks, filter, etapes).Render(ctx, w)
return
}
}
@ -636,12 +636,12 @@ func TaskReorderHandler(deps TasksDeps) http.HandlerFunc {
}
}
tasks, _, _, filter, ok := loadTasksTabData(w, r, deps.Queries, tablo)
tasks, etapes, _, filter, ok := loadTasksTabData(w, r, deps.Queries, tablo)
if !ok {
return
}
w.Header().Set("Content-Type", "text/html; charset=utf-8")
_ = templates.KanbanBoard(tablo.ID, csrf.Token(r), tasks, filter).Render(ctx, w)
_ = templates.KanbanBoard(tablo.ID, csrf.Token(r), tasks, filter, etapes).Render(ctx, w)
}
}

View file

@ -428,7 +428,7 @@ templ TabloOverviewTabFragment(tablo sqlc.Tablo, csrfToken string) {
// Lives in tablos.templ (tablo-level concern) per plan D-07.
templ TasksTabFragment(tablo sqlc.Tablo, tasks []sqlc.Task, etapes []sqlc.Etape, counts EtapeTaskCounts, filter EtapeFilter, csrfToken string) {
<div id="tasks-tab">
@KanbanBoard(tablo.ID, csrfToken, tasks, filter)
@KanbanBoard(tablo.ID, csrfToken, tasks, filter, etapes)
</div>
}