- Migrate class.S → Shared\Helpers\Helpers (140+ files), remove 12 unused methods - Migrate class.Html → Shared\Html\Html - Migrate class.Email → Shared\Email\Email - Migrate class.Image → Shared\Image\ImageManipulator - Delete class.Log (unused), class.Mobile_Detect (outdated UA detection) - Remove grid library loading from admin (index.php, ajax.php) - Replace gridEdit usage in 10 admin templates with grid-edit-replacement.php - Fix grid-edit-replacement.php AJAX to send values as JSON (grid.js compat) - Remove mobile layout conditionals (m_html/m_css/m_js) from Site + LayoutsRepository - Remove \Log::save_log() calls from OrderAdminService, ShopOrder, Order Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
110 lines
5.0 KiB
PHP
110 lines
5.0 KiB
PHP
<div class="order-summary-content">
|
|
<div class="top">
|
|
<div class="basket-summary left">
|
|
Data zamówienia: <span><?= \Shared\Helpers\Helpers::pretty_date( 'j f Y', strtotime( $this -> order['date_order'] ) );?></span>
|
|
</div>
|
|
<div class="basket-summary left">
|
|
Status zamówienia: <span><?= $this -> statuses[ $this -> order['status'] ];?></span>
|
|
</div>
|
|
</div>
|
|
<div class="top-second">
|
|
<div class="column">
|
|
<h5><?= ucfirst( \Shared\Helpers\Helpers::lang( 'dane-do-dostawy' ) );?></h5>
|
|
<p>
|
|
<?= $this -> order['client_surname'];?> <?= $this -> order['client_name'];?><br />
|
|
<?= $this -> order['client_street'];?><br />
|
|
<?= $this -> order['client_postal_code'];?> <?= $this -> order['client_city'];?><br />
|
|
<?= $this -> order['client_email'];?><br />
|
|
<?= $this -> order['client_phone'];?>
|
|
<? if ( $this -> order['inpost_paczkomat'] ):?>
|
|
<br /><br />Paczkomat: <b><?= $this -> order['inpost_paczkomat'];?>
|
|
<? endif;?>
|
|
<? if ( $this -> order['orlen_point'] ):?>
|
|
<br /><br />Punkt Orlen: <b><?= $this -> order['orlen_point'];?>
|
|
<? endif;?>
|
|
</p>
|
|
</div>
|
|
<div class="column">
|
|
<? if ( $this -> order['firm_name'] ):?>
|
|
<h5><?= \Shared\Helpers\Helpers::lang( 'dane-do-faktury' );?>:</h5>
|
|
<p>
|
|
<?= $this -> order['firm_name'];?><br />
|
|
<?= $this -> order['firm_street'];?><br />
|
|
<?= $this -> order['firm_postal_code'];?> <?= $this -> order['firm_city'];?><br />
|
|
NIP: <?= $this -> order['firm_nip'];?>
|
|
</p>
|
|
<? endif;?>
|
|
</div>
|
|
</div>
|
|
<div class="products">
|
|
<? if ( is_array( $this -> order['products'] ) and count( $this -> order['products'] ) ):?>
|
|
<? foreach ( $this -> order['products'] as $product ):?>
|
|
<? $product_tmp = \shop\Product::getFromCache( $product['product_id'], $lang['id'] );?>
|
|
<div class="basket-product">
|
|
<div class="image">
|
|
<? if ( file_exists( substr( $product_tmp['images'][0]['src'], 1 ) ) ):?>
|
|
<img class="main-img" src="<?= $product_tmp['images'][0]['src'];?>" alt="">
|
|
<? else:?>
|
|
|
|
<? endif;?>
|
|
</div>
|
|
<div class="details">
|
|
<div class="name">
|
|
<?= $product['name'];?>
|
|
<div class="attributes">
|
|
<?= $product['attributes'];?>
|
|
</div>
|
|
<div class="custom-fields">
|
|
<?= $product['custom_fields'];?>
|
|
</div>
|
|
<div class="product-message">
|
|
<?= $product['message'] != '' ? '<strong>Wiadomość:</strong> ' . $product['message'] : '';?>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<div class="prices">
|
|
<div class="price">
|
|
<?
|
|
echo \Shared\Helpers\Helpers::decimal( $product['price_brutto_promo'] ) . ' zł';
|
|
|
|
if ( $product['price_brutto_promo'] and $product['price_brutto_promo'] < $product['price_brutto'] )
|
|
echo '<u>' . \Shared\Helpers\Helpers::decimal( $product['price_brutto'] ) . ' zł</u>';
|
|
|
|
if ( $product['price_brutto_promo'] and $product['price_brutto_promo'] < $product['price_brutto'] )
|
|
$discount += \Shared\Helpers\Helpers::normalize_decimal( ( $product['price_brutto'] - $product['price_brutto_promo'] ) * $product['quantity'] );
|
|
?>
|
|
<span>x <?= $product['quantity'];?></span>
|
|
<?= \Shared\Helpers\Helpers::decimal( \Shared\Helpers\Helpers::normalize_decimal( $product['price_brutto'] * $product['quantity'] ) );?> zł
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<? $summary += \Shared\Helpers\Helpers::normalize_decimal( $product['price_brutto'] * $product['quantity'] );?>
|
|
<? endforeach;?>
|
|
<div class="basket-summary">
|
|
Wartość koszyka <span><?= \Shared\Helpers\Helpers::decimal( $summary );?> zł</span>
|
|
</div>
|
|
<? if ( $discount ):?>
|
|
<div class="basket-summary">
|
|
Rabat <span class="text-danger"><?= \Shared\Helpers\Helpers::decimal( $discount );?> zł</span>
|
|
</div>
|
|
<? endif;?>
|
|
<? if ( $this -> coupon ):?>
|
|
<div class="basket-summary">
|
|
Kod rabatowy: <span style="color: #cc0000;"><?= $this -> coupon -> name;?> - <?= $this -> coupon -> amount;?> <?= $this -> coupon -> type == 1 ? '%' : 'zł';?></span>
|
|
</div>
|
|
<? endif;?>
|
|
<div class="basket-summary">
|
|
<?= $this -> order['transport'];?> <span><?= \Shared\Helpers\Helpers::decimal( $this -> order['transport_cost'] );?> zł</span>
|
|
</div>
|
|
<div class="basket-summary big">
|
|
<?= ucfirst( \Shared\Helpers\Helpers::lang( 'razem-z-dostawa' ) );?>: <span><?= \Shared\Helpers\Helpers::decimal( $summary - $discount + $this -> order['transport_cost'] );?> zł</span>
|
|
</div>
|
|
<? endif;?>
|
|
<? if ( $this -> order['message'] ):?>
|
|
<div class="basket-summary">
|
|
Wiadomość:
|
|
<span class="comment"><?= $this -> order['message'];?></span>
|
|
</div>
|
|
<? endif;?>
|
|
</div>
|
|
</div>
|