This commit is contained in:
2025-03-13 14:15:49 +05:00
parent 352352acc8
commit 6fe6da5fe0

View File

@@ -58,13 +58,6 @@ class CheckOnlinePayment extends Action
]);
}
// $response = Http::asForm()->post('https://mpi.gov.tm/payment/rest/getOrderStatus.do', [
// 'language' => 'ru',
// 'orderId' => $onlinePaymentResource->orderId,
// 'userName' => $username,
// 'password' => $password,
// ]);
$response = Http::asForm()->post('https://mpi.gov.tm/payment/rest/getOrderStatusExtended.do', [
'language' => 'ru',
'orderId' => $onlinePaymentResource->orderId,
@@ -94,14 +87,11 @@ class CheckOnlinePayment extends Action
*
* @param $response
*/
public static function resultHTML($response)
public static function resultHTML(\Illuminate\Http\Client\Response $response)
{
$errorMessage = $response['ErrorMessage'] ?? '';
$keyValueListHTML = $response->body();
// $response->collect()->each(function ($item, $key) use (&$keyValueListHTML) {
// $keyValueListHTML .= "<li><span>{$key}:</span> <strong>{$item}</strong></li>";
// });
$keyValueListHTML = json_encode($response->json(), JSON_PRETTY_PRINT);
return Blade::render(<<<HTML
<span class="mb-2">HALKBANK-dan gelen netije:</span>