Refactor code structure for improved readability and maintainability
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
<? global $config; $this -> settings['ssl'] ? $base = 'https' : $base = 'http'; $paymentRepo = new \Domain\PaymentMethod\PaymentMethodRepository( $GLOBALS['mdb'] );?>
|
||||
<? global $config; $this -> settings['ssl'] ? $base = 'https' : $base = 'http'; $base_secure = 'https'; $paymentRepo = new \Domain\PaymentMethod\PaymentMethodRepository( $GLOBALS['mdb'] );?>
|
||||
<div class="order-summary">
|
||||
<div class="box-title">
|
||||
<?= ucfirst( \Shared\Helpers\Helpers::lang( 'szczegoly-zamowienia' ) );?>: <?= $this -> order['number'];?>
|
||||
@@ -119,9 +119,9 @@
|
||||
$url .= '&email=' . urlencode( $this -> order['client_email'] );
|
||||
$url .= '&nazwisko=' . urlencode( $this -> order['client_name'] . ' ' . $this -> order['client_surname'] );
|
||||
$url .= '&crc=' . $this -> order['hash'];
|
||||
$url .= '&result_url=' . urlencode( $base . "://" . $_SERVER['SERVER_NAME'] . '/tpay-status' );
|
||||
$url .= '&return_url=' . urlencode( $base . "://" . $_SERVER['SERVER_NAME'] . '/potwierdzenie-platnosci/' . $this -> order['hash'] );
|
||||
$url .= '&return_error_url=' . urlencode( $base . "://" . $_SERVER['SERVER_NAME'] . '/zamowienie/' . $this -> order['hash'] );
|
||||
$url .= '&result_url=' . urlencode( $base_secure . "://" . $_SERVER['SERVER_NAME'] . '/tpay-status' );
|
||||
$url .= '&return_url=' . urlencode( $base_secure . "://" . $_SERVER['SERVER_NAME'] . '/potwierdzenie-platnosci/' . $this -> order['hash'] );
|
||||
$url .= '&return_error_url=' . urlencode( $base_secure . "://" . $_SERVER['SERVER_NAME'] . '/zamowienie/' . $this -> order['hash'] );
|
||||
$url .= '&md5sum=' . md5( $id . '&' . str_replace( ',', '.', round( $this -> order['summary'], 2 ) ) . '&' . $this -> order['hash'] . '&' . $code );
|
||||
?>
|
||||
<button type="button" onclick="document.location.href='<?= $url;?>'" class="btn btn-success"><?= \Shared\Helpers\Helpers::lang( 'zaplac-online' );?> <?= \Shared\Helpers\Helpers::decimal( $this -> order['summary'] );?> zł</b></button>
|
||||
@@ -189,4 +189,4 @@
|
||||
<? unset( $_SESSION['google-analytics-purchase'] );?>
|
||||
<? endif;?>
|
||||
});
|
||||
</script>
|
||||
</script>
|
||||
|
||||
Reference in New Issue
Block a user