Feature: Lessons-Learned-Vorlage beim Projekt-Abschluss

Der Abschluss verlangte eine URL + freie Vermerk-Textarea, half aber nicht beim
Strukturieren der Retro. Jetzt gefuehrte Felder (Ziel erreicht? / Aufwand vs.
Plan / was lief gut / was nicht), gespeichert als JSONB project.lessons_learned
(Migration 0018). Anzeige im Projekt-Detail als "Retrospektive"; Altprojekte
fallen auf den freien Abschlussvermerk zurueck.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
Raffael SheikhandClaude Opus 4.8 committed 2026-06-07 12:45:19 +02:00
1 parent 3e66ba3156
commit 62945201b1
7 files changed
+3443 -20

No files matched your search

@@ -0,0 +1 @@
ALTER TABLE "project" ADD COLUMN "lessons_learned" jsonb;
File diff suppressed because it is too large. Load diff
@@ -127,6 +127,13 @@
"when": 1780826387755,
"tag": "0017_rare_oracle",
"breakpoints": true
},
{
"idx": 18,
"version": "7",
"when": 1780828837324,
"tag": "0018_last_lake",
"breakpoints": true
}
]
}
+8
View File
@@ -166,6 +166,14 @@ export const project = pgTable(
lessonsLearnedUrl: text('lessons_learned_url'),
// Abschluss (Leitfaden Phase 4): kurzer Abschlussvermerk — Ziel erreicht? Aufwand vs. Plan?
abschlussvermerk: text('abschlussvermerk'),
// Strukturierte Retrospektive (Lessons-Learned-Vorlage). Ersetzt die freie
// Vermerk-Textarea durch geführte Felder; alte Einträge nutzen abschlussvermerk.
lessonsLearned: jsonb('lessons_learned').$type<{
zielErreicht: string;
aufwand: string;
liefGut: string;
liefSchlecht: string;
} | null>(),
createdBy: uuid('created_by').references(() => user.id, { onDelete: 'set null' }),
createdAt: timestamp('created_at', { withTimezone: true }).notNull().defaultNow(),
updatedAt: timestamp('updated_at', { withTimezone: true }).notNull().defaultNow(),
+10
View File
@@ -44,10 +44,20 @@ export const createProjectInput = z.object({
});
export type CreateProjectInput = z.infer<typeof createProjectInput>;
export const lessonsLearnedSchema = z.object({
zielErreicht: z.string().max(2000),
aufwand: z.string().max(2000),
liefGut: z.string().max(2000),
liefSchlecht: z.string().max(2000),
});
export type LessonsLearned = z.infer<typeof lessonsLearnedSchema>;
export const archiveProjectInput = z.object({
projectId: z.string().uuid(),
lessonsLearnedUrl: z.string().url(),
abschlussvermerk: z.string().max(2000).optional(),
// Strukturierte Retrospektive (Lessons-Learned-Vorlage), optional.
lessonsLearned: lessonsLearnedSchema.optional(),
});
export type ArchiveProjectInput = z.infer<typeof archiveProjectInput>;