Added Money System

This commit is contained in:
2026-01-22 19:25:25 +01:00
parent d5d0d5aaf4
commit bb5c3058b1
12 changed files with 703 additions and 266 deletions

View File

@@ -45,7 +45,9 @@ export async function GET(request: NextRequest) {
nom: true,
prenom: true,
telephone: true,
telephoneSecondaire: true,
email: true,
forfait: true,
},
},
chauffeur: {
@@ -80,7 +82,7 @@ export async function POST(request: NextRequest) {
}
const body = await request.json();
const { date, adresseDepart, adresseArrivee, commentaire, statut, adherentId, chauffeurId } = body;
const { date, adresseDepart, adresseArrivee, commentaire, instructions, statut, adherentId, chauffeurId } = body;
if (!date || !adresseDepart || !adresseArrivee || !adherentId) {
return NextResponse.json(
@@ -95,6 +97,7 @@ export async function POST(request: NextRequest) {
adresseDepart,
adresseArrivee,
commentaire: commentaire || null,
instructions: instructions || null,
statut: statut || 'Planifié',
adherentId,
chauffeurId: chauffeurId || null,
@@ -106,7 +109,9 @@ export async function POST(request: NextRequest) {
nom: true,
prenom: true,
telephone: true,
telephoneSecondaire: true,
email: true,
forfait: true,
},
},
chauffeur: {