diff --git a/app/Http/Controllers/ClientPortal/PaymentHookController.php b/app/Http/Controllers/ClientPortal/PaymentHookController.php new file mode 100644 index 000000000000..abfac3b30dc8 --- /dev/null +++ b/app/Http/Controllers/ClientPortal/PaymentHookController.php @@ -0,0 +1,30 @@ +input()); + + } + +} \ No newline at end of file diff --git a/app/PaymentDrivers/PayPalExpressPaymentDriver.php b/app/PaymentDrivers/PayPalExpressPaymentDriver.php index 97be177e7c2e..2b04e3da27d0 100644 --- a/app/PaymentDrivers/PayPalExpressPaymentDriver.php +++ b/app/PaymentDrivers/PayPalExpressPaymentDriver.php @@ -53,7 +53,7 @@ class PayPalExpressPaymentDriver extends BasePaymentDriver */ public function processPaymentView(array $data) { - + $this->purchase(); } public function processPaymentResponse($request) @@ -77,4 +77,9 @@ class PayPalExpressPaymentDriver extends BasePaymentDriver return $data; } + + private function buildReturnUrl() + { + $url = $this->client->company->domain . "/payment_hook/{$this->company_gateway->id}/{GatewayType::PAYPAL}"; + } } \ No newline at end of file diff --git a/routes/client.php b/routes/client.php index b9ac33d9ffcf..fa9d449541e4 100644 --- a/routes/client.php +++ b/routes/client.php @@ -46,6 +46,7 @@ Route::group(['middleware' => ['domain_db'], 'prefix' => 'client', 'as' => 'clie /*Invitation catches*/ Route::get('invoice/{invitation_id}','ClientPortal\InvitationController@invoiceRouter'); + Route::get('payment_hook/{invitation_id}','ClientPortal\PaymentHookController@process'); });