AP2.2a: Archetyp-Starter-Kits und MVP Execution Plan v0.2.
Deploy Development / deploy (push) Successful in 45s
Test Suite / pytest-backend (push) Successful in 2m40s
Test Suite / lint-backend (push) Successful in 3s
Test Suite / compose-smoke (push) Has been skipped
Test Suite / k6 /api/health Baseline (push) Successful in 18s
Test Suite / playwright-smoke (push) Successful in 13s
Deploy Development / deploy (push) Successful in 45s
Test Suite / pytest-backend (push) Successful in 2m40s
Test Suite / lint-backend (push) Successful in 3s
Test Suite / compose-smoke (push) Has been skipped
Test Suite / k6 /api/health Baseline (push) Successful in 18s
Test Suite / playwright-smoke (push) Successful in 13s
Referenz-Vorhaben A1/A2/B2b/B2a per UI anlegbar mit gefuehrter Starter-Struktur; Dogfooding-Seed deprecated. Plan-Korrektur: Execution Plan v0.2 statt Seed-Spiegel als Prioritaet. Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
1 parent
a097a82e17
commit
2b0d5dd3d9
18 files changed
+1050
-87
No files matched your search
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "kairo-jinkendo-frontend",
|
||||
"version": "0.18.0-ap2.0",
|
||||
"version": "0.20.0-ap2.2a",
|
||||
"private": true,
|
||||
"type": "module",
|
||||
"scripts": {
|
||||
|
||||
@@ -4,3 +4,10 @@ export function listEntityArchetypes(entityType) {
|
||||
const qs = entityType ? `?entity_type=${encodeURIComponent(entityType)}` : ''
|
||||
return apiFetch(`/api/entity-archetypes${qs}`)
|
||||
}
|
||||
|
||||
export function getArchetypeStarterPreview(archetypeKey, methodProfileKey) {
|
||||
const params = new URLSearchParams()
|
||||
if (methodProfileKey) params.set('method_profile_key', methodProfileKey)
|
||||
const qs = params.toString() ? `?${params}` : ''
|
||||
return apiFetch(`/api/entity-archetypes/${encodeURIComponent(archetypeKey)}/starter-preview${qs}`)
|
||||
}
|
||||
@@ -2,7 +2,7 @@ import { useEffect, useState } from 'react'
|
||||
import { INITIATIVE_STATUSES, PRIORITIES } from '../constants/status.js'
|
||||
import { INITIATIVE_STATUS_LABELS, PRIORITY_LABELS } from '../constants/status.js'
|
||||
import { INITIATIVE_ARCHETYPE_LABELS } from '../constants/initiativeArchetypes.js'
|
||||
import { listEntityArchetypes } from '../api/entityArchetypes.js'
|
||||
import { listEntityArchetypes, getArchetypeStarterPreview } from '../api/entityArchetypes.js'
|
||||
import {
|
||||
getInitiativeFields,
|
||||
listArchetypeFieldDefinitions,
|
||||
@@ -23,6 +23,9 @@ export function InitiativeForm({
|
||||
const [fieldDefinitions, setFieldDefinitions] = useState([])
|
||||
const [dynamicValues, setDynamicValues] = useState({})
|
||||
const [fieldsLoading, setFieldsLoading] = useState(false)
|
||||
const [starterPreview, setStarterPreview] = useState(null)
|
||||
const [starterLoading, setStarterLoading] = useState(false)
|
||||
const isCreate = !initiativeId
|
||||
|
||||
useEffect(() => {
|
||||
let cancelled = false
|
||||
@@ -81,6 +84,28 @@ export function InitiativeForm({
|
||||
}
|
||||
}, [initiativeId, archetypeKey])
|
||||
|
||||
useEffect(() => {
|
||||
if (!isCreate || !archetypeKey) {
|
||||
setStarterPreview(null)
|
||||
return undefined
|
||||
}
|
||||
let cancelled = false
|
||||
setStarterLoading(true)
|
||||
getArchetypeStarterPreview(archetypeKey)
|
||||
.then((preview) => {
|
||||
if (!cancelled) setStarterPreview(preview)
|
||||
})
|
||||
.catch(() => {
|
||||
if (!cancelled) setStarterPreview(null)
|
||||
})
|
||||
.finally(() => {
|
||||
if (!cancelled) setStarterLoading(false)
|
||||
})
|
||||
return () => {
|
||||
cancelled = true
|
||||
}
|
||||
}, [isCreate, archetypeKey])
|
||||
|
||||
async function handleSubmit(e) {
|
||||
e.preventDefault()
|
||||
const form = e.target
|
||||
@@ -94,6 +119,7 @@ export function InitiativeForm({
|
||||
priority: form.priority.value,
|
||||
owner_actor_id: form.owner_actor_id?.value || undefined,
|
||||
dynamicFields: dynamicValues,
|
||||
apply_starter_kit: isCreate && starterPreview?.supported !== false,
|
||||
})
|
||||
}
|
||||
|
||||
@@ -130,6 +156,19 @@ export function InitiativeForm({
|
||||
<span className="muted form-hint">{selectedArchetype.description}</span>
|
||||
)}
|
||||
</label>
|
||||
{isCreate && starterPreview?.supported && (
|
||||
<div className="starter-kit-preview card-list-item compact">
|
||||
<p className="muted form-hint">
|
||||
<strong>Starter-Struktur:</strong>{' '}
|
||||
{starterLoading
|
||||
? ' wird geladen …'
|
||||
: starterPreview.items.map((item) => item.title).join(' · ')}
|
||||
</p>
|
||||
{starterPreview.guidance && (
|
||||
<p className="muted form-hint">{starterPreview.guidance}</p>
|
||||
)}
|
||||
</div>
|
||||
)}
|
||||
{actors.length > 0 && (
|
||||
<label>
|
||||
Verantwortlich (Owner)
|
||||
|
||||
@@ -60,6 +60,7 @@ export function SteeringSnapshotPanel({
|
||||
counts,
|
||||
upcoming_milestones = [],
|
||||
next_actions = [],
|
||||
active_work_cycle = null,
|
||||
} = snapshot
|
||||
const displayLabel =
|
||||
lifecycle_label ||
|
||||
@@ -143,6 +144,19 @@ export function SteeringSnapshotPanel({
|
||||
</p>
|
||||
)}
|
||||
|
||||
{active_work_cycle && (
|
||||
<p className="steering-work-cycle-row">
|
||||
<span className="muted">Aktive Zeitbox: </span>
|
||||
<strong>{active_work_cycle.title}</strong>
|
||||
{active_work_cycle.goal_description && (
|
||||
<span className="steering-method-description muted">
|
||||
{' '}
|
||||
— {active_work_cycle.goal_description}
|
||||
</span>
|
||||
)}
|
||||
</p>
|
||||
)}
|
||||
|
||||
<ul className="steering-stat-pills" aria-label="Kurzüberblick">
|
||||
{statPills.map((pill) => (
|
||||
<li
|
||||
|
||||
Reference in new issue
Block a user