From 80e2785fe74c8c48acc1e3fec9a80aae85c162af Mon Sep 17 00:00:00 2001 From: Babak Alizadeh Date: Mon, 24 Mar 2025 13:35:08 +0000 Subject: [PATCH] bug fin in parsian gatepay --- hesabixCore/src/Controller/Front/PayController.php | 4 +++- hesabixCore/src/Service/PayMGR.php | 2 +- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/hesabixCore/src/Controller/Front/PayController.php b/hesabixCore/src/Controller/Front/PayController.php index 3380886..ed7a7f1 100644 --- a/hesabixCore/src/Controller/Front/PayController.php +++ b/hesabixCore/src/Controller/Front/PayController.php @@ -130,6 +130,8 @@ class PayController extends AbstractController $wu->setFullName('کیف پول'); $wu->setEmail('wallet@hesabix.ir'); $wu->setRoles([]); + $wu->setPassword(0); + $wu->setDateRegister(time()); $wu->setActive(true); $entityManager->persist($wu); $entityManager->flush(); @@ -181,7 +183,7 @@ class PayController extends AbstractController $entityManager->flush(); $log->insert('کیف پول', 'پرداخت موفق فاکتور فروش ' . $originalDoc->getCode(), $this->getUser(), $doc->getBid()); - return $this->redirectToRoute('shortlinks_show', ['type' => 'sell', 'bid' => $originalDoc->getBid()->getId(), 'link' => $originalDoc->getId(), 'msg' => 'success']); + return $this->redirectToRoute('shortlinks_show', ['type' => 'sell', 'bid' => $originalDoc->getBid()->getId(), 'link' => $originalDoc->getShortlink(), 'msg' => 'success']); } } } diff --git a/hesabixCore/src/Service/PayMGR.php b/hesabixCore/src/Service/PayMGR.php index 27dbdb7..8933f04 100644 --- a/hesabixCore/src/Service/PayMGR.php +++ b/hesabixCore/src/Service/PayMGR.php @@ -165,7 +165,7 @@ class PayMGR if ($result->ConfirmPaymentResult->Status == '0') { $res['Success'] = true; $res['status'] = 100; - $res['refID'] = $_POST["RRN"]; + $res['refID'] = $result->ConfirmPaymentResult->RRN; $res['card_pan'] = $result->ConfirmPaymentResult->CardNumberMasked; } }