Scrum4Me/components/ideas
Janpeter Visser 5cb3abbd3d
Sprint: Idee regril mogelijkheid (#144)
* feat(ST-cmovhveef): add PLANNED to GRILL_TRIGGERABLE_FROM and PLANNED→GRILLING transition

- GRILL_TRIGGERABLE_FROM now includes 'PLANNED' in actions/ideas.ts
- ALLOWED_TRANSITIONS PLANNED entry extended with 'GRILLING' in lib/idea-status.ts
- Updated canTransition test to reflect the new re-grill-from-PLANNED behavior

* test(ST-cmovhvef3): add exhaustive re-grill canTransition test covering PLANNED

Adds a loop test that asserts canTransition(status, 'GRILLING') for all
statuses in GRILL_TRIGGERABLE_FROM that support the transition, explicitly
documenting PLANNED as a valid re-grill entry point.

* feat(ST-cmovhvegf): add existingPbi pre-check in materializeIdeaPlanAction

- Adds options.allowAlongside parameter to control behaviour when a PBI
  with executed tasks already exists.
- Returns 409 PBI_HAS_ACTIVE_TASKS:<code> when tasks are DONE/IN_PROGRESS
  and allowAlongside is not set.
- Auto-deletes the old PBI inside the transaction when no tasks have been
  executed (atomic replace).
- Alongside mode (allowAlongside=true) skips deletion and creates a new PBI.

* test(ST-cmovhveh3): add pre-check integration tests for materializeIdeaPlanAction

Three new scenarios in ideas-crud.test.ts:
- auto-vervang: old PBI deleted in transaction when no executed tasks
- conflict-409: returns PBI_HAS_ACTIVE_TASKS:<code> with active tasks
- alongside: skips delete and creates new PBI when allowAlongside=true
Also adds task.count, pbi.findUnique, pbi.delete to prisma mock.

* feat(ST-cmovhveih): remove PLANNED-blokkering in idea-row-actions, add inline Bekijk-PBI button

- Removed grillBlockedReason guard for status==='planned', enabling re-grill from PLANNED
- Removed the early return for PLANNED that hid all standard buttons
- Added conditional 'Bekijk <code>' button at the start of the standard button set,
  visible only when status==='planned' and PBI + product_id are present

* feat(ST-cmovhvej7): add PBI_HAS_ACTIVE_TASKS alongside-dialoog in materialize handler

When materializeIdeaPlanAction returns code 409 with PBI_HAS_ACTIVE_TASKS:<code>,
a confirm dialog offers the user a choice: create new PBI alongside the existing one
or cancel. Alongside=true retries the action; cancel leaves the idea in PLAN_READY.
2026-05-07 15:27:43 +02:00
..
download-md-button.tsx ui: idea-timeline + pbi-link-card + download-md-button (M12 T-512) 2026-05-04 21:39:33 +02:00
idea-detail-layout.tsx feat(PBI-34 ST-1213): UI — multi-select badges + lijst-filter (#111) 2026-05-06 03:18:50 +02:00
idea-list.tsx ST-iiybtinq: voeg Snel idee-knop en inline form toe aan IdeaList (#129) 2026-05-06 09:31:10 +02:00
idea-md-editor.tsx ui: idea-md-editor with yaml-validate + wire into detail tabs (M12 T-511) 2026-05-04 21:37:49 +02:00
idea-pbi-link-card.tsx fix(m12): drop bogus /backlog#pbi-{code} route on PBI-link 2026-05-05 14:06:24 +02:00
idea-row-actions.tsx Sprint: Idee regril mogelijkheid (#144) 2026-05-07 15:27:43 +02:00
idea-sync-tab.tsx feat(T-562): IdeaSyncTab component met StoryLog-hergebruik 2026-05-06 00:20:12 +02:00
idea-timeline.tsx fix(m12): hydration mismatch on IdeaTimeline timestamps 2026-05-05 13:29:43 +02:00