55 lines
1.6 KiB
Dart
55 lines
1.6 KiB
Dart
import 'package:flutter/material.dart';
|
|
import 'package:p_tits_pas/widgets/admin/gestionnaire_card.dart';
|
|
|
|
class GestionnaireManagementWidget extends StatelessWidget {
|
|
const GestionnaireManagementWidget({Key? key}) : super(key: key);
|
|
|
|
@override
|
|
Widget build(BuildContext context) {
|
|
return Padding(
|
|
padding: const EdgeInsets.all(16),
|
|
child: Column(
|
|
crossAxisAlignment: CrossAxisAlignment.stretch,
|
|
children: [
|
|
// 🔹 Barre du haut avec bouton
|
|
Row(
|
|
children: [
|
|
const Expanded(
|
|
child: TextField(
|
|
decoration: InputDecoration(
|
|
hintText: "Rechercher un gestionnaire...",
|
|
prefixIcon: Icon(Icons.search),
|
|
border: OutlineInputBorder(),
|
|
),
|
|
),
|
|
),
|
|
const SizedBox(width: 16),
|
|
ElevatedButton.icon(
|
|
onPressed: () {
|
|
// Rediriger vers la page de création
|
|
},
|
|
icon: const Icon(Icons.add),
|
|
label: const Text("Créer un gestionnaire"),
|
|
),
|
|
],
|
|
),
|
|
const SizedBox(height: 24),
|
|
|
|
// 🔹 Liste des gestionnaires
|
|
Expanded(
|
|
child: ListView.builder(
|
|
itemCount: 5, // À remplacer par liste dynamique
|
|
itemBuilder: (context, index) {
|
|
return GestionnaireCard(
|
|
name: "Dupont $index",
|
|
email: "dupont$index@mail.com",
|
|
);
|
|
},
|
|
),
|
|
)
|
|
],
|
|
),
|
|
);
|
|
}
|
|
}
|