Build APK Android fonctionnel - Corrections finales

- Ajout de Java 21 dans Dockerfile pour compatibilité Capacitor
- Création de fichiers de types séparés (lib/types/) pour éviter dépendances API routes
- Configuration next.config.export.js pour export statique
- Exclusion temporaire des routes API pendant le build
- Correction configuration Gradle (Java 17/21)
- Script build-apk.sh amélioré avec gestion des routes API
- APK généré avec succès (4.5MB) dans dist/compagnon-admin-debug.apk

Fichiers de types créés:
- lib/types/place.ts
- lib/types/infos.ts
- lib/types/tides.ts
- lib/types/excursions.ts
- lib/types/sun-times.ts
- lib/types/notifications.ts

Tous les imports mis à jour pour utiliser les nouveaux fichiers de types.
This commit is contained in:
2025-11-23 10:07:34 +01:00
parent 51a74342f4
commit 115d8c05a7
83 changed files with 1143 additions and 679 deletions

View File

@ -1,26 +0,0 @@
import { NextResponse } from "next/server";
import { getClientByToken } from "@/lib/admin/client-utils";
export async function GET(
request: Request,
{ params }: { params: Promise<{ token: string }> }
) {
const { token } = await params;
const client = getClientByToken(token);
if (!client) {
return NextResponse.json(
{ error: "Token invalide ou expiré" },
{ status: 404 }
);
}
// Retourner uniquement les informations nécessaires (sans le token)
return NextResponse.json({
bungalowNumber: client.bungalowNumber,
wifiName: client.wifiName,
wifiPassword: client.wifiPassword,
gerantMessage: client.gerantMessage,
});
}