fix(#112): afficher photos enfants en reprise + consentement cohérent
Charge existingPhotoUrl dans les cartes enfant (étapes 3 et 5) et pré-coche le consentement photo lorsqu'une photo est déjà en base. Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
@@ -30,6 +30,7 @@ class ParentData {
|
||||
class ChildData {
|
||||
static const Object _unsetImage = Object();
|
||||
static const Object _unsetImageBytes = Object();
|
||||
static const Object _unsetExistingPhotoUrl = Object();
|
||||
|
||||
String firstName;
|
||||
String lastName;
|
||||
@@ -75,7 +76,7 @@ class ChildData {
|
||||
Object? imageBytes = _unsetImageBytes,
|
||||
CardColorVertical? cardColor,
|
||||
String? repriseChildId,
|
||||
String? existingPhotoUrl,
|
||||
Object? existingPhotoUrl = _unsetExistingPhotoUrl,
|
||||
}) {
|
||||
return ChildData(
|
||||
firstName: firstName ?? this.firstName,
|
||||
@@ -90,7 +91,9 @@ class ChildData {
|
||||
identical(imageBytes, _unsetImageBytes) ? this.imageBytes : imageBytes as Uint8List?,
|
||||
cardColor: cardColor ?? this.cardColor,
|
||||
repriseChildId: repriseChildId ?? this.repriseChildId,
|
||||
existingPhotoUrl: existingPhotoUrl ?? this.existingPhotoUrl,
|
||||
existingPhotoUrl: identical(existingPhotoUrl, _unsetExistingPhotoUrl)
|
||||
? this.existingPhotoUrl
|
||||
: existingPhotoUrl as String?,
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user