From c19b6296edcbf192f0c91cec7b71296cbee78ca8 Mon Sep 17 00:00:00 2001 From: Lars Date: Sun, 12 Jul 2026 19:30:36 +0200 Subject: [PATCH] fix: Sprint-Zuordnung im Eingang sichtbarer machen. Ziel-Sprint-Dropdown immer wenn Sprint existiert, Setup-Hinweis ohne Sprint, Planen fuer alle commit-faehigen Backlog-Status. Co-authored-by: Cursor --- frontend/src/components/BacklogSection.jsx | 51 +++++++++++++--------- frontend/src/styles/program-chrome.css | 12 +++++ 2 files changed, 43 insertions(+), 20 deletions(-) diff --git a/frontend/src/components/BacklogSection.jsx b/frontend/src/components/BacklogSection.jsx index abf25b2..7fa6838 100644 --- a/frontend/src/components/BacklogSection.jsx +++ b/frontend/src/components/BacklogSection.jsx @@ -10,6 +10,8 @@ import { computeDropPatches, computeMovePatches, sortByOrder } from '../utils/re import { useMinWidth } from '../hooks/useMinWidth.js' const PLANNING_STATUSES = new Set(['planned', 'active', 'at_risk']) +/** Backend erlaubt Convert für diese Status — UI war nur bei „Freigegeben“ sichtbar. */ +const COMMITTABLE_STATUSES = new Set(['accepted', 'triaged', 'new']) export function BacklogSection({ items, @@ -137,8 +139,8 @@ export function BacklogSection({ const modalTitle = modalMode?.kind === 'create' ? 'Backlog-Item anlegen' : 'Backlog-Item bearbeiten' - const acceptedItems = sortedItems.filter((item) => item.status === 'accepted') - const selectedAccepted = acceptedItems.filter((item) => selectedIds.has(item.id)) + const committableItems = sortedItems.filter((item) => COMMITTABLE_STATUSES.has(item.status)) + const selectedCommittable = committableItems.filter((item) => selectedIds.has(item.id)) function toggleSelected(itemId) { setSelectedIds((prev) => { @@ -163,14 +165,14 @@ export function BacklogSection({ } async function handleBulkPlan() { - if (!selectedAccepted.length) return + if (!selectedCommittable.length) return if (typeof onBulkConvert === 'function') { await onBulkConvert( - selectedAccepted.map((item) => item.id), + selectedCommittable.map((item) => item.id), convertOptions(), ) } else { - for (const item of selectedAccepted) { + for (const item of selectedCommittable) { await onConvert(item.id, convertOptions()) } } @@ -195,10 +197,22 @@ export function BacklogSection({ )} - {showSprintPlanning && canManage && acceptedItems.length > 0 && ( + {sprintPlanningEnabled && canManage && !showSprintPlanning && ( +
+

+ Sprint-Planung: Lege zuerst einen Sprint an. +

+

+ Plan → Sprint → „Sprint anlegen“ (optional „Sofort aktivieren“). Danach erscheint hier + die Sprint-Auswahl zum Committen aus dem Eingang. +

+
+ )} + + {showSprintPlanning && canManage && (
- {selectedAccepted.length > 0 && ( + {selectedCommittable.length > 0 && ( )}

- Items markieren und in den gewählten Sprint committen — Planung unter Plan → Sprint. + {committableItems.length === 0 + ? 'Lege Backlog-Items an — dann per Checkbox markieren und in den Sprint committen.' + : 'Checkbox am Item → „In Sprint planen“. Committen erzeugt ein Arbeitspaket mit Sprint-Zuweisung.'}

)} - {sprintPlanningEnabled && canManage && acceptedItems.length > 0 && planableSprints.length === 0 && ( -

- Lege zuerst einen Sprint unter Plan → Sprint an, um Backlog-Items zu planen. -

- )} - {items.length === 0 && }
    @@ -262,7 +273,7 @@ export function BacklogSection({ ⋮⋮ )} - {showSprintPlanning && canManage && item.status === 'accepted' && ( + {showSprintPlanning && canManage && COMMITTABLE_STATUSES.has(item.status) && (