diff --git a/app/Http/Controllers/iLinkTransactionController.php b/app/Http/Controllers/iLinkTransactionController.php index 1169886..8c41882 100755 --- a/app/Http/Controllers/iLinkTransactionController.php +++ b/app/Http/Controllers/iLinkTransactionController.php @@ -257,7 +257,7 @@ class iLinkTransactionController extends Controller ['id_transaction' => $transaction->id_transaction, 'amount' => $this->toMoney($transaction->montant, $init_country), 'net' => $this->toMoney($montantDepot, $init_country), 'fees' => $this->toMoney($frais, $init_country), 'sender_code' => $user->user_code, 'cart_number' => wordwrap($transaction->numero_carte, 4, ' ', true)]); -// $this->sendMail($user->email, trans('messages.successful_transaction'), $message); + $this->sendMail($user->email, trans('messages.successful_transaction'), $message); return $this->successResponse($message . trans('messages.sent_by_mail')); } else { @@ -627,7 +627,7 @@ class iLinkTransactionController extends Controller // $body['expiry_date'] = $expiration_date->format('Y-m'); $body['expiry_date'] = $expiration_date->format('m/y'); $body['amount'] = $montantRetrait; - $body['cardholder_name'] = $request->lastname . ' ' . $request->firstname; //"John Smith" ; + $body['cardholder_name'] = $request->lastname ? $request->lastname . ' ' . $request->firstname : "John Smith"; $body['currency'] = $this->getCurrency($init_country); $body['ref'] = date("Y-m-d H:i:s.u"); @@ -810,7 +810,7 @@ class iLinkTransactionController extends Controller $body['expiry_date'] = $expiration_date->format('m/y'); $body['amount'] = $montantDepot; - $body['cardholder_name'] = $request->lastname . ' ' . $request->firstname; //"John Smith" ; + $body['cardholder_name'] = $request->lastname ? $request->lastname . ' ' . $request->firstname : "John Smith"; $body['currency'] = $this->getCurrency($init_country); $body['ref'] = date("Y-m-d H:i:s.u");