feat(#95): implémenter la gestion Relais admin et le rattachement gestionnaire
Ajoute la section Paramètres territoriaux avec CRUD Relais, modale de saisie structurée, états visuels harmonisés, et rattachement d'un relais principal aux gestionnaires via l'API. Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
@@ -0,0 +1,33 @@
|
||||
class RelaisModel {
|
||||
final String id;
|
||||
final String nom;
|
||||
final String adresse;
|
||||
final Map<String, dynamic>? horairesOuverture;
|
||||
final String? ligneFixe;
|
||||
final bool actif;
|
||||
final String? notes;
|
||||
|
||||
const RelaisModel({
|
||||
required this.id,
|
||||
required this.nom,
|
||||
required this.adresse,
|
||||
this.horairesOuverture,
|
||||
this.ligneFixe,
|
||||
required this.actif,
|
||||
this.notes,
|
||||
});
|
||||
|
||||
factory RelaisModel.fromJson(Map<String, dynamic> json) {
|
||||
return RelaisModel(
|
||||
id: (json['id'] ?? '').toString(),
|
||||
nom: (json['nom'] ?? '').toString(),
|
||||
adresse: (json['adresse'] ?? '').toString(),
|
||||
horairesOuverture: json['horaires_ouverture'] is Map<String, dynamic>
|
||||
? json['horaires_ouverture'] as Map<String, dynamic>
|
||||
: null,
|
||||
ligneFixe: json['ligne_fixe'] as String?,
|
||||
actif: json['actif'] as bool? ?? true,
|
||||
notes: json['notes'] as String?,
|
||||
);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user