docs: Update ticket list and cleanup obsolete files (Closes #79, Closes #80)

- Delete obsolete nanny_registration_data.dart and nanny_register_confirmation_screen.dart
- Update 23_LISTE-TICKETS.md with #79 and #80 status

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
MARTIN Julien 2026-02-07 17:09:19 +01:00
parent b956f94ad2
commit 39814c76b1
3 changed files with 38 additions and 188 deletions

View File

@ -3,7 +3,7 @@
**Version** : 1.0 **Version** : 1.0
**Date** : 25 Novembre 2025 **Date** : 25 Novembre 2025
**Auteur** : Équipe PtitsPas **Auteur** : Équipe PtitsPas
**Estimation totale** : ~173h **Estimation totale** : ~179h
--- ---
@ -913,6 +913,39 @@ Créer une infrastructure générique pour gérer les formulaires en modes multi
--- ---
### Ticket #79 : [Frontend] Renommer "Nanny" en "Assistante Maternelle" (AM) ✅
**Estimation** : 2h
**Labels** : `frontend`, `p3`, `refactoring`, `cdc`
**Statut** : ✅ TERMINÉ (Fermé le 2026-02-07)
**Description** :
Renommage complet de "Nanny" en "AM" dans le frontend pour cohérence avec le CDC.
**Tâches** :
- [x] Modèles : nanny_registration_data.dart -> am_registration_data.dart
- [x] Écrans : nanny_register_*.dart -> am_register_*.dart
- [x] Routes : /nanny-register -> /am-register
- [x] Suppression fichiers obsolètes
---
### Ticket #80 : [Frontend] Architecture widgets génériques réutilisables ✅
**Estimation** : 4h
**Labels** : `frontend`, `p3`, `refactoring`
**Statut** : ✅ TERMINÉ (Fermé le 2026-02-07)
**Description** :
Création de widgets génériques pour réduire duplication de code (intégré à la refonte #78).
**Tâches** :
- [x] PersonalInfoFormScreen
- [x] PresentationFormScreen
- [x] ProfessionalInfoFormScreen
- [x] ChildCardWidget
- [x] SummaryScreen/SummaryCard
---
## 🔵 PRIORITÉ 4 : Tests & Documentation ## 🔵 PRIORITÉ 4 : Tests & Documentation
### Ticket #52 : [Tests] Tests unitaires Backend ### Ticket #52 : [Tests] Tests unitaires Backend
@ -1130,14 +1163,14 @@ Rédiger les documents légaux génériques (CGU et Politique de confidentialit
## 📊 Résumé final ## 📊 Résumé final
**Total** : 61 tickets **Total** : 63 tickets
**Estimation** : ~173h de développement **Estimation** : ~179h de développement
### Par priorité ### Par priorité
- **P0 (Bloquant BDD)** : 7 tickets (~5h) - **P0 (Bloquant BDD)** : 7 tickets (~5h)
- **P1 (Bloquant Config)** : 7 tickets (~22h) - **P1 (Bloquant Config)** : 7 tickets (~22h)
- **P2 (Backend)** : 18 tickets (~50h) - **P2 (Backend)** : 18 tickets (~50h)
- **P3 (Frontend)** : 18 tickets (~60h) ← +1 ticket logs admin, +1 ticket refonte formulaires - **P3 (Frontend)** : 20 tickets (~66h) ← +1 logs admin, +3 refactoring (78, 79, 80)
- **P4 (Tests/Doc)** : 4 tickets (~24h) - **P4 (Tests/Doc)** : 4 tickets (~24h)
- **Critiques** : 6 tickets (~13h) ← -2 email, +1 logs, +1 CDC - **Critiques** : 6 tickets (~13h) ← -2 email, +1 logs, +1 CDC
- **Juridique** : 1 ticket (~8h) - **Juridique** : 1 ticket (~8h)
@ -1145,7 +1178,7 @@ Rédiger les documents légaux génériques (CGU et Politique de confidentialit
### Par domaine ### Par domaine
- **BDD** : 7 tickets - **BDD** : 7 tickets
- **Backend** : 23 tickets ← +1 logs - **Backend** : 23 tickets ← +1 logs
- **Frontend** : 18 tickets ← +1 logs admin, +1 refonte formulaires - **Frontend** : 20 tickets ← +1 logs admin, +3 refactoring
- **Tests** : 3 tickets - **Tests** : 3 tickets
- **Documentation** : 5 tickets ← +1 amendement CDC - **Documentation** : 5 tickets ← +1 amendement CDC
- **Infra** : 2 tickets - **Infra** : 2 tickets

View File

@ -1,136 +0,0 @@
import 'package:flutter/foundation.dart';
class NannyRegistrationData extends ChangeNotifier {
// Step 1: Identity Info
String firstName = '';
String lastName = '';
String streetAddress = ''; // Nouveau pour N° et Rue
String postalCode = ''; // Nouveau
String city = ''; // Nouveau
String phone = '';
String email = '';
String password = '';
// String? photoPath; // Déplacé ou géré à l'étape 2
// bool photoConsent = false; // Déplacé ou géré à l'étape 2
// Step 2: Professional Info
String? photoPath; // Ajouté pour l'étape 2
bool photoConsent = false; // Ajouté pour l'étape 2
DateTime? dateOfBirth;
String birthCity = ''; // Nouveau
String birthCountry = ''; // Nouveau
// String placeOfBirth = ''; // Remplacé par birthCity et birthCountry
String nir = ''; // Numéro de Sécurité Sociale
String agrementNumber = ''; // Numéro d'agrément
int? capacity; // Number of children the nanny can look after
// Step 3: Presentation & CGU
String presentationText = '';
bool cguAccepted = false;
// --- Methods to update data and notify listeners ---
void updateIdentityInfo({
String? firstName,
String? lastName,
String? streetAddress, // Modifié
String? postalCode, // Nouveau
String? city, // Nouveau
String? phone,
String? email,
String? password,
}) {
this.firstName = firstName ?? this.firstName;
this.lastName = lastName ?? this.lastName;
this.streetAddress = streetAddress ?? this.streetAddress; // Modifié
this.postalCode = postalCode ?? this.postalCode; // Nouveau
this.city = city ?? this.city; // Nouveau
this.phone = phone ?? this.phone;
this.email = email ?? this.email;
this.password = password ?? this.password;
// if (photoPath != null || this.photoPath != null) { // Supprimé de l'étape 1
// this.photoPath = photoPath;
// }
// this.photoConsent = photoConsent ?? this.photoConsent; // Supprimé de l'étape 1
notifyListeners();
}
void updateProfessionalInfo({
String? photoPath,
bool? photoConsent,
DateTime? dateOfBirth,
String? birthCity, // Nouveau
String? birthCountry, // Nouveau
// String? placeOfBirth, // Remplacé
String? nir,
String? agrementNumber,
int? capacity,
}) {
// Allow setting photoPath to null explicitly
if (photoPath != null || this.photoPath != null) {
this.photoPath = photoPath;
}
this.photoConsent = photoConsent ?? this.photoConsent;
this.dateOfBirth = dateOfBirth ?? this.dateOfBirth;
this.birthCity = birthCity ?? this.birthCity; // Nouveau
this.birthCountry = birthCountry ?? this.birthCountry; // Nouveau
// this.placeOfBirth = placeOfBirth ?? this.placeOfBirth; // Remplacé
this.nir = nir ?? this.nir;
this.agrementNumber = agrementNumber ?? this.agrementNumber;
this.capacity = capacity ?? this.capacity;
notifyListeners();
}
void updatePresentationAndCgu({
String? presentationText,
bool? cguAccepted,
}) {
this.presentationText = presentationText ?? this.presentationText;
this.cguAccepted = cguAccepted ?? this.cguAccepted;
notifyListeners();
}
// --- Getters for validation or display ---
bool get isStep1Complete =>
firstName.isNotEmpty &&
lastName.isNotEmpty &&
streetAddress.isNotEmpty && // Modifié
postalCode.isNotEmpty && // Nouveau
city.isNotEmpty && // Nouveau
phone.isNotEmpty &&
email.isNotEmpty &&
password.isNotEmpty;
bool get isStep2Complete =>
// photoConsent is mandatory if a photo is system-required, otherwise optional.
// For now, let's assume if photoPath is present, consent should ideally be true.
// Or, make consent always mandatory if photo section exists.
// Based on new mockup, photo is present, so consent might be implicitly or explicitly needed.
(photoPath != null ? photoConsent == true : true) && // Ajuster selon la logique de consentement désirée
dateOfBirth != null &&
birthCity.isNotEmpty &&
birthCountry.isNotEmpty &&
nir.isNotEmpty && // Basic check, could add validation
agrementNumber.isNotEmpty &&
capacity != null && capacity! > 0;
bool get isStep3Complete =>
// presentationText is optional as per CDC (message au gestionnaire)
cguAccepted;
bool get isRegistrationComplete =>
isStep1Complete && isStep2Complete && isStep3Complete;
@override
String toString() {
return 'NannyRegistrationData('
'firstName: $firstName, lastName: $lastName, '
'streetAddress: $streetAddress, postalCode: $postalCode, city: $city, '
'phone: $phone, email: $email, '
// 'photoPath: $photoPath, photoConsent: $photoConsent, ' // Commenté car déplacé/modifié
'dateOfBirth: $dateOfBirth, birthCity: $birthCity, birthCountry: $birthCountry, '
'nir: $nir, agrementNumber: $agrementNumber, capacity: $capacity, '
'photoPath (step2): $photoPath, photoConsent (step2): $photoConsent, '
'presentationText: $presentationText, cguAccepted: $cguAccepted)';
}
}

View File

@ -1,47 +0,0 @@
import 'package:flutter/material.dart';
import 'package:go_router/go_router.dart';
class NannyRegisterConfirmationScreen extends StatelessWidget {
const NannyRegisterConfirmationScreen({super.key});
@override
Widget build(BuildContext context) {
return Scaffold(
appBar: AppBar(
title: const Text('Inscription Soumise'),
automaticallyImplyLeading: false, // Remove back button
),
body: Center(
child: Padding(
padding: const EdgeInsets.all(20.0),
child: Column(
mainAxisAlignment: MainAxisAlignment.center,
crossAxisAlignment: CrossAxisAlignment.center,
children: [
const Icon(Icons.check_circle_outline, color: Colors.green, size: 80),
const SizedBox(height: 20),
const Text(
'Votre demande d\'inscription a été soumise avec succès !',
style: TextStyle(fontSize: 20, fontWeight: FontWeight.bold),
textAlign: TextAlign.center,
),
const SizedBox(height: 15),
const Text(
'Votre compte est en attente de validation par un gestionnaire. Vous recevrez une notification par e-mail une fois votre compte activé.',
textAlign: TextAlign.center,
),
const SizedBox(height: 30),
ElevatedButton(
onPressed: () {
// Navigate back to the login screen
context.go('/login');
},
child: const Text('Retour à la connexion'),
),
],
),
),
),
);
}
}