Add reservation flow: BilletBuyer, guest checkout, Stripe payment

- Create BilletBuyer entity: event, user (nullable for guests), firstName,
  lastName, email, reference (ETICKET-XXXX-XXXX-XXXX), totalHT, status,
  stripeSessionId, paidAt, items (OneToMany)
- Create BilletBuyerItem entity: billet, billetName (snapshot), quantity,
  unitPriceHT, line total helpers
- OrderController with full checkout flow:
  - POST /evenement/{id}/commander: create order from cart JSON
  - GET/POST /commande/{id}/informations: guest form (name, email)
  - GET /commande/{id}/paiement: payment page with recap
  - POST /commande/{id}/stripe: Stripe Checkout on connected account
    with application_fee, productId, and quantities
  - GET /commande/{id}/confirmation: success page
- Cart JS: POST cart data on Commander click, redirect to guest/payment
- Templates: guest form, payment page, order summary partial, success page
- Stripe payment uses organizer connected account, application_fee based
  on commissionRate, existing productId when available
- Tests: BilletBuyerTest (12), BilletBuyerItemTest (6), cart.test.js (13)

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
Serreau Jovann
2026-03-21 13:54:17 +01:00
parent 5e099b8af6
commit 7167a58c7c
16 changed files with 1128 additions and 4 deletions

View File

@@ -6,7 +6,7 @@ parameters:
- src/Kernel.php
ignoreErrors:
-
message: '#Property App\\Entity\\(EmailTracking|MessengerLog|User|Payout|Event|Category|Billet|BilletDesign)::\$id .* never assigned#'
message: '#Property App\\Entity\\(EmailTracking|MessengerLog|User|Payout|Event|Category|Billet|BilletDesign|BilletBuyer|BilletBuyerItem)::\$id .* never assigned#'
paths:
- src/Entity/EmailTracking.php
- src/Entity/MessengerLog.php
@@ -16,3 +16,5 @@ parameters:
- src/Entity/Category.php
- src/Entity/Billet.php
- src/Entity/BilletDesign.php
- src/Entity/BilletBuyer.php
- src/Entity/BilletBuyerItem.php