Squash merge de develop vers master. Livrables principaux (ticket #101 et mise au point associée) : - Branchement du formulaire d'inscription parent sur POST /api/v1/auth/register/parent - Payload DTO (parents, enfants, photos base64, CGU) et services Auth - Parcours gestionnaire : cartes dossiers, wizard validation famille, images authentifiées - Scripts d'inscription test (Martin, Durand/Rousseau, Lecomte) ; .gitignore .cursor/ Inclut également les ajustements develop fusionnés dans ce lot (inscription AM, champs relais, etc.). Closes #101 Made-with: Cursor
48 lines
1.5 KiB
Dart
48 lines
1.5 KiB
Dart
import 'package:flutter/material.dart';
|
|
import 'package:provider/provider.dart';
|
|
import 'package:go_router/go_router.dart';
|
|
|
|
import '../../models/am_registration_data.dart';
|
|
import '../../widgets/personal_info_form_screen.dart';
|
|
import '../../models/card_assets.dart';
|
|
|
|
class AmRegisterStep1Screen extends StatelessWidget {
|
|
const AmRegisterStep1Screen({super.key});
|
|
|
|
@override
|
|
Widget build(BuildContext context) {
|
|
final registrationData = Provider.of<AmRegistrationData>(context, listen: false);
|
|
|
|
final initialData = PersonalInfoData(
|
|
firstName: registrationData.firstName,
|
|
lastName: registrationData.lastName,
|
|
phone: registrationData.phone,
|
|
email: registrationData.email,
|
|
address: registrationData.streetAddress,
|
|
postalCode: registrationData.postalCode,
|
|
city: registrationData.city,
|
|
);
|
|
|
|
return PersonalInfoFormScreen(
|
|
stepText: 'Étape 1/4',
|
|
title: 'Vos informations personnelles',
|
|
cardColor: CardColorHorizontal.blue,
|
|
initialData: initialData,
|
|
previousRoute: '/register-choice',
|
|
onSubmit: (data, {hasSecondPerson, sameAddress}) {
|
|
registrationData.updateIdentityInfo(
|
|
firstName: data.firstName,
|
|
lastName: data.lastName,
|
|
phone: data.phone,
|
|
email: data.email,
|
|
streetAddress: data.address,
|
|
postalCode: data.postalCode,
|
|
city: data.city,
|
|
password: '',
|
|
);
|
|
context.go('/am-register-step2');
|
|
},
|
|
);
|
|
}
|
|
}
|