merge: v1 student polish
This commit is contained in:
@@ -0,0 +1,10 @@
|
||||
/// Identité simulée utilisée tant que l'authentification Azure AD n'est pas branchée.
|
||||
class DemoIdentity {
|
||||
DemoIdentity._();
|
||||
|
||||
static const userName = "Lucas Martin";
|
||||
static const userInitials = "LM";
|
||||
static const userSubtitle = "Étudiant · B2 Informatique · Ensitech Cergy";
|
||||
static const campusTag = "Saint-Christophe · Cergy";
|
||||
static const loginCampusTag = "Ensitech · Cergy";
|
||||
}
|
||||
@@ -1,7 +1,8 @@
|
||||
import "package:flutter/material.dart";
|
||||
import "../demo_identity.dart";
|
||||
|
||||
/// Représentation d'un matériel affiché dans le catalogue et son détail
|
||||
/// (données statiques pour l'instant ; sera alimenté par l'API plus tard).
|
||||
/// à partir des réponses API.
|
||||
class MaterielItem {
|
||||
const MaterielItem({
|
||||
required this.id,
|
||||
@@ -30,7 +31,9 @@ class MaterielItem {
|
||||
marque: json["marque"] as String,
|
||||
modele: json["modele"] as String,
|
||||
reference: json["reference"] as String,
|
||||
campus: campus == null ? "Saint-Christophe · Cergy" : "${campus["nom"]} · ${campus["ville"]}",
|
||||
campus: campus == null
|
||||
? DemoIdentity.campusTag
|
||||
: "${campus["nom"]} · ${campus["ville"]}",
|
||||
etatGeneral: json["etatGeneral"] as String,
|
||||
disponible: json["statut"] == "DISPONIBLE",
|
||||
accessoires: accessoires == null ? const <String>[] : accessoires.cast<String>(),
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
import "package:flutter/material.dart";
|
||||
import "package:google_fonts/google_fonts.dart";
|
||||
import "../demo_identity.dart";
|
||||
import "../theme/ensup_colors.dart";
|
||||
import "../models/materiel_item.dart";
|
||||
import "../services/materiel_service.dart";
|
||||
@@ -98,9 +99,9 @@ class _CatalogueScreenState extends State<CatalogueScreen> {
|
||||
children: [
|
||||
EnsupTopBar(
|
||||
brandText: "Catalogue matériel",
|
||||
campusTag: "Paris · Ensitech",
|
||||
userName: "Lucas Martin",
|
||||
userInitials: "LM",
|
||||
campusTag: DemoIdentity.campusTag,
|
||||
userName: DemoIdentity.userName,
|
||||
userInitials: DemoIdentity.userInitials,
|
||||
onBack: () => Navigator.of(context).pop(),
|
||||
),
|
||||
Expanded(
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
import "package:flutter/material.dart";
|
||||
import "package:google_fonts/google_fonts.dart";
|
||||
import "../demo_identity.dart";
|
||||
import "../theme/ensup_colors.dart";
|
||||
import "../models/materiel_item.dart";
|
||||
import "../services/emprunt_service.dart";
|
||||
@@ -122,9 +123,9 @@ class _ChecklistDepartScreenState extends State<ChecklistDepartScreen> {
|
||||
children: [
|
||||
EnsupTopBar(
|
||||
brandText: "Checklist de départ",
|
||||
campusTag: "Paris · Ensitech",
|
||||
userName: "Lucas Martin",
|
||||
userInitials: "LM",
|
||||
campusTag: DemoIdentity.campusTag,
|
||||
userName: DemoIdentity.userName,
|
||||
userInitials: DemoIdentity.userInitials,
|
||||
onBack: () => Navigator.of(context).pop(),
|
||||
),
|
||||
Expanded(
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
import "package:flutter/material.dart";
|
||||
import "package:google_fonts/google_fonts.dart";
|
||||
import "../demo_identity.dart";
|
||||
import "../theme/ensup_colors.dart";
|
||||
import "../models/emprunt_item.dart";
|
||||
import "../models/anomalie_retour.dart";
|
||||
@@ -127,9 +128,9 @@ class _ChecklistRetourScreenState extends State<ChecklistRetourScreen> {
|
||||
children: [
|
||||
EnsupTopBar(
|
||||
brandText: "Checklist de retour",
|
||||
campusTag: "Paris · Ensitech",
|
||||
userName: "Lucas Martin",
|
||||
userInitials: "LM",
|
||||
campusTag: DemoIdentity.campusTag,
|
||||
userName: DemoIdentity.userName,
|
||||
userInitials: DemoIdentity.userInitials,
|
||||
onBack: () => Navigator.of(context).pop(),
|
||||
),
|
||||
Expanded(
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
import "package:flutter/material.dart";
|
||||
import "package:google_fonts/google_fonts.dart";
|
||||
import "../demo_identity.dart";
|
||||
import "../theme/ensup_colors.dart";
|
||||
import "../models/emprunt_response.dart";
|
||||
import "../models/materiel_item.dart";
|
||||
@@ -49,7 +50,7 @@ class ConfirmationScreen extends StatelessWidget {
|
||||
children: [
|
||||
const EnsupTopBar(
|
||||
brandText: "EME · Confirmation",
|
||||
campusTag: "Paris · Ensitech",
|
||||
campusTag: DemoIdentity.campusTag,
|
||||
),
|
||||
Expanded(
|
||||
child: DecoratedBox(
|
||||
@@ -186,7 +187,7 @@ class ConfirmationScreen extends StatelessWidget {
|
||||
_rrow("Matériel", item.nom),
|
||||
_rrow("Référence", item.reference),
|
||||
_rrow("N° emprunt", "#${emprunt.id}"),
|
||||
_rrow("Emprunteur", "Lucas Martin"),
|
||||
_rrow("Emprunteur", DemoIdentity.userName),
|
||||
_rrow("Date d'emprunt", date),
|
||||
_rrow("Heure", heure),
|
||||
_rrow("Campus", item.campus),
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
import "package:flutter/material.dart";
|
||||
import "package:google_fonts/google_fonts.dart";
|
||||
import "../demo_identity.dart";
|
||||
import "../theme/ensup_colors.dart";
|
||||
import "../models/materiel_item.dart";
|
||||
import "../widgets/ensup_top_bar.dart";
|
||||
@@ -47,9 +48,9 @@ class DetailScreen extends StatelessWidget {
|
||||
children: [
|
||||
EnsupTopBar(
|
||||
brandText: "Détail matériel",
|
||||
campusTag: "Paris · Ensitech",
|
||||
userName: "Lucas Martin",
|
||||
userInitials: "LM",
|
||||
campusTag: DemoIdentity.campusTag,
|
||||
userName: DemoIdentity.userName,
|
||||
userInitials: DemoIdentity.userInitials,
|
||||
onBack: () => Navigator.of(context).pop(),
|
||||
),
|
||||
Expanded(
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
import "package:flutter/material.dart";
|
||||
import "package:google_fonts/google_fonts.dart";
|
||||
import "../demo_identity.dart";
|
||||
import "../theme/ensup_colors.dart";
|
||||
import "../widgets/ensup_top_bar.dart";
|
||||
import "../widgets/profile_card.dart";
|
||||
@@ -38,9 +39,9 @@ class HomeScreen extends StatelessWidget {
|
||||
child: Column(
|
||||
children: [
|
||||
EnsupTopBar(
|
||||
campusTag: "Paris · Ensitech",
|
||||
userName: "Lucas Martin",
|
||||
userInitials: "LM",
|
||||
campusTag: DemoIdentity.campusTag,
|
||||
userName: DemoIdentity.userName,
|
||||
userInitials: DemoIdentity.userInitials,
|
||||
onBack: () => Navigator.of(context).pop(),
|
||||
),
|
||||
Expanded(
|
||||
@@ -50,9 +51,9 @@ class HomeScreen extends StatelessWidget {
|
||||
crossAxisAlignment: CrossAxisAlignment.start,
|
||||
children: [
|
||||
const ProfileCard(
|
||||
name: "Lucas Martin",
|
||||
subtitle: "Étudiant · BTS SIO 2ème année · Ensitech Paris",
|
||||
initials: "LM",
|
||||
name: DemoIdentity.userName,
|
||||
subtitle: DemoIdentity.userSubtitle,
|
||||
initials: DemoIdentity.userInitials,
|
||||
),
|
||||
const SizedBox(height: 24),
|
||||
Text(
|
||||
@@ -89,7 +90,9 @@ class HomeScreen extends StatelessWidget {
|
||||
"Restituer un matériel que vous avez emprunté",
|
||||
color: EnsupColors.teal,
|
||||
onTap: () => Navigator.of(context).push(
|
||||
MaterialPageRoute(builder: (_) => const RestitutionSelectScreen()),
|
||||
MaterialPageRoute(
|
||||
builder: (_) => const RestitutionSelectScreen(),
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
import "package:flutter/material.dart";
|
||||
import "package:google_fonts/google_fonts.dart";
|
||||
import "../demo_identity.dart";
|
||||
import "../theme/ensup_colors.dart";
|
||||
import "../widgets/ensup_top_bar.dart";
|
||||
import "../widgets/identification_option.dart";
|
||||
@@ -46,7 +47,7 @@ class LoginScreen extends StatelessWidget {
|
||||
children: [
|
||||
const EnsupTopBar(
|
||||
brandText: "EME — Emprunt Matériel ENSUP",
|
||||
campusTag: "Ensitech · Paris",
|
||||
campusTag: DemoIdentity.loginCampusTag,
|
||||
),
|
||||
Expanded(
|
||||
child: DecoratedBox(
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
import "package:flutter/material.dart";
|
||||
import "package:google_fonts/google_fonts.dart";
|
||||
import "../demo_identity.dart";
|
||||
import "../theme/ensup_colors.dart";
|
||||
import "../models/emprunt_item.dart";
|
||||
import "../services/emprunt_service.dart";
|
||||
@@ -83,9 +84,9 @@ class _RestitutionSelectScreenState extends State<RestitutionSelectScreen> {
|
||||
children: [
|
||||
EnsupTopBar(
|
||||
brandText: "Restitution",
|
||||
campusTag: "Paris · Ensitech",
|
||||
userName: "Lucas Martin",
|
||||
userInitials: "LM",
|
||||
campusTag: DemoIdentity.campusTag,
|
||||
userName: DemoIdentity.userName,
|
||||
userInitials: DemoIdentity.userInitials,
|
||||
onBack: () => Navigator.of(context).pop(),
|
||||
),
|
||||
Expanded(
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
import "package:flutter/material.dart";
|
||||
import "package:google_fonts/google_fonts.dart";
|
||||
import "../demo_identity.dart";
|
||||
import "../theme/ensup_colors.dart";
|
||||
import "../models/emprunt_item.dart";
|
||||
import "../models/anomalie_retour.dart";
|
||||
@@ -49,7 +50,7 @@ class ResultatRetourScreen extends StatelessWidget {
|
||||
children: [
|
||||
const EnsupTopBar(
|
||||
brandText: "EME · Résultat du contrôle",
|
||||
campusTag: "Paris · Ensitech",
|
||||
campusTag: DemoIdentity.campusTag,
|
||||
),
|
||||
Expanded(
|
||||
child: DecoratedBox(
|
||||
@@ -227,7 +228,7 @@ class ResultatRetourScreen extends StatelessWidget {
|
||||
valeurCouleur: EnsupColors.red,
|
||||
),
|
||||
_drow("Matériel", "${emprunt.materiel.nom} · ${emprunt.materiel.reference}"),
|
||||
_drow("Emprunteur", "Lucas Martin"),
|
||||
_drow("Emprunteur", DemoIdentity.userName),
|
||||
_drow("Date détection", date),
|
||||
],
|
||||
),
|
||||
|
||||
+10
-10
@@ -29,10 +29,10 @@ packages:
|
||||
dependency: transitive
|
||||
description:
|
||||
name: characters
|
||||
sha256: f71061c654a3380576a52b451dd5532377954cf9dbd272a78fc8479606670803
|
||||
sha256: faf38497bda5ead2a8c7615f4f7939df04333478bf32e4173fcb06d428b5716b
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "1.4.0"
|
||||
version: "1.4.1"
|
||||
clock:
|
||||
dependency: transitive
|
||||
description:
|
||||
@@ -175,26 +175,26 @@ packages:
|
||||
dependency: transitive
|
||||
description:
|
||||
name: matcher
|
||||
sha256: dc58c723c3c24bf8d3e2d3ad3f2f9d7bd9cf43ec6feaa64181775e60190153f2
|
||||
sha256: dc0b7dc7651697ea4ff3e69ef44b0407ea32c487a39fff6a4004fa585e901861
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "0.12.17"
|
||||
version: "0.12.19"
|
||||
material_color_utilities:
|
||||
dependency: transitive
|
||||
description:
|
||||
name: material_color_utilities
|
||||
sha256: f7142bb1154231d7ea5f96bc7bde4bda2a0945d2806bb11670e30b850d56bdec
|
||||
sha256: "9c337007e82b1889149c82ed242ed1cb24a66044e30979c44912381e9be4c48b"
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "0.11.1"
|
||||
version: "0.13.0"
|
||||
meta:
|
||||
dependency: transitive
|
||||
description:
|
||||
name: meta
|
||||
sha256: "23f08335362185a5ea2ad3a4e597f1375e78bce8a040df5c600c8d3552ef2394"
|
||||
sha256: "1741988757a65eb6b36abe716829688cf01910bbf91c34354ff7ec1c3de2b349"
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "1.17.0"
|
||||
version: "1.18.0"
|
||||
package_config:
|
||||
dependency: transitive
|
||||
description:
|
||||
@@ -324,10 +324,10 @@ packages:
|
||||
dependency: transitive
|
||||
description:
|
||||
name: test_api
|
||||
sha256: ab2726c1a94d3176a45960b6234466ec367179b87dd74f1611adb1f3b5fb9d55
|
||||
sha256: "949a932224383300f01be9221c39180316445ecb8e7547f70a41a35bf421fb9e"
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "0.7.7"
|
||||
version: "0.7.11"
|
||||
typed_data:
|
||||
dependency: transitive
|
||||
description:
|
||||
|
||||
@@ -252,6 +252,13 @@ En terminal interactif (VS Code), `migrate dev` fonctionne normalement (taper `y
|
||||
- Flux non conforme validé en réel : création emprunt -> restitution avec élément absent -> statut `RETOUR_NON_CONFORME` -> matériel retiré du catalogue disponible.
|
||||
- Aucun correctif code nécessaire après ces tests ; backend `build` et `lint` restent verts.
|
||||
|
||||
### Étape 32 — Polish V1 étudiant
|
||||
- Branche dédiée `feat/v1-student-polish` créée après merge de `feat/student-flow-stabilization` dans `develop`.
|
||||
- Identité simulée et campus MVP centralisés dans `lib/demo_identity.dart` tant que l'auth Azure AD n'est pas branchée.
|
||||
- Libellés UI harmonisés sur le contexte réel du MVP : `Saint-Christophe · Cergy` / `Ensitech Cergy` au lieu de `Paris · Ensitech`.
|
||||
- Commentaire obsolète du modèle `MaterielItem` corrigé : les données viennent maintenant de l'API.
|
||||
- `TODO.md` mis à jour : les parcours emprunt et restitution étudiant sont maintenant branchés API.
|
||||
|
||||
---
|
||||
|
||||
*Dernière mise à jour : 2026-07-08 — Parcours étudiant complet testé en réel avec SQL Server Docker.*
|
||||
*Dernière mise à jour : 2026-07-08 — Parcours étudiant complet testé et libellés V1 harmonisés.*
|
||||
|
||||
Reference in New Issue
Block a user