feat(production): exposer SujetData dans Production + FTD-21 persistance session
This commit is contained in:
parent
b16dbfa1c8
commit
e130d3792e
3 changed files with 42 additions and 0 deletions
|
|
@ -17,6 +17,25 @@ export type Tache = 'EE_T1' | 'EE_T2' | 'EE_T3' | 'EO_T1' | 'EO_T3'
|
|||
/** Mode de la simulation — examen uniquement accessible au plan Premium. */
|
||||
export type Mode = 'entrainement' | 'examen'
|
||||
|
||||
/**
|
||||
* Sujet d'examen (consigne + documents) associé à une production.
|
||||
*
|
||||
* Retourné par `POST /simulations` depuis la table `sujets` (filtrage actif + tâche).
|
||||
* `null` lorsque la table ne contient aucun sujet actif pour la tâche, ou pour `EO_T2_LIVE`
|
||||
* (interaction live sans sujet pré-défini). Voir TECH_DEBT FTD-21 pour la persistance
|
||||
* via `GET /simulations/:id` (pas encore branchée).
|
||||
*/
|
||||
export interface SujetData {
|
||||
id: string
|
||||
consigne: string
|
||||
role: string | null
|
||||
contexte: string | null
|
||||
doc1_titre: string | null
|
||||
doc1_texte: string | null
|
||||
doc2_titre: string | null
|
||||
doc2_texte: string | null
|
||||
}
|
||||
|
||||
/**
|
||||
* Réponse du backend pour `POST /simulations` (HTTP 201) et `GET /simulations/:id`.
|
||||
* Format confirmé par l'audit backend 2026-04-17 (cf. ARCHITECTURE.md §5).
|
||||
|
|
@ -26,6 +45,7 @@ export interface Production {
|
|||
tache: Tache
|
||||
mode: Mode
|
||||
created_at: string
|
||||
sujet: SujetData | null
|
||||
}
|
||||
|
||||
/** Corps de la requête `POST /simulations`. */
|
||||
|
|
|
|||
|
|
@ -31,6 +31,7 @@ const mockProduction: Production = {
|
|||
tache: 'EE_T1',
|
||||
mode: 'entrainement',
|
||||
created_at: '2026-04-19T00:00:00Z',
|
||||
sujet: null,
|
||||
}
|
||||
|
||||
const mockReport: Report = {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue