fix 500 after buying ticket #53
@ -54,12 +54,15 @@ class TicketService
|
||||
|
||||
private function saveTicketData(TicketFormData $data, string $sessionId): void
|
||||
{
|
||||
$customer = $this->createEntityFromData($data);
|
||||
$payment = (new Payment())
|
||||
->setSessionId($sessionId)
|
||||
->setCompleted(false)
|
||||
->setCustomer($this->createEntityFromData($data))
|
||||
->setDonation($data->personal->donation);
|
||||
|
||||
$customer->setPayment($payment);
|
||||
|
||||
$this->em->persist($customer);
|
||||
$this->em->persist($payment);
|
||||
$this->em->flush();
|
||||
}
|
||||
|
Reference in New Issue
Block a user