From e1fb368d3a40662623f02199f528540a073055b7 Mon Sep 17 00:00:00 2001 From: Dorian Vabre Date: Mon, 12 Apr 2021 16:50:56 +0200 Subject: [PATCH] wip --- .../public/eventorganization/attendee_subscription.php | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/htdocs/public/eventorganization/attendee_subscription.php b/htdocs/public/eventorganization/attendee_subscription.php index 172e6cee798..0adf783ee05 100644 --- a/htdocs/public/eventorganization/attendee_subscription.php +++ b/htdocs/public/eventorganization/attendee_subscription.php @@ -274,7 +274,7 @@ if (empty($reshook) && $action == 'add') { $error++; $errmsg .= $project->error; } else { - var_dump($project->price_registration); + global $dolibarr_main_url_root; if (!empty(floatval($project->price_registration))){ $facture = new Facture($db); //$facture->rowid = ; @@ -288,12 +288,15 @@ if (empty($reshook) && $action == 'add') { //$facture->tms = ; //$facture->fk_statut = ; $facture->date = dol_now(); - $resultfacture = $facture->create($user); + $resultfacture = $facture->create($user); + //@todo rediriger page paiement + $redirection = $dolibarr_main_url_root.'/public/payment/newpayment.php'; + Header("Location: ".$redirection); + exit; } else { // No price has been set // Validating the subscription $confattendee->setStatut(1); - global $dolibarr_main_url_root; $redirection = $dolibarr_main_url_root.'/public/eventorganization/subscriptionok.php'; Header("Location: ".$redirection); exit;