ver. 0.292: ShopProduct + ShopPaymentMethod + ShopPromotion + ShopStatuses + ShopTransport frontend migration to Domain
Full migration of front\factory\ — entire directory removed (all 20 classes migrated). ProductRepository +20 frontend methods, PromotionRepository +5 applyType methods, TransportRepository +4 cached methods, PaymentMethodRepository +cached frontend methods. Fix: broken transports_list() in ajax.php replaced with forPaymentMethod(). Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -34,7 +34,7 @@
|
||||
</div>
|
||||
<div class="details">
|
||||
<?php
|
||||
$url = \front\factory\ShopProduct::product_url( $product );
|
||||
$url = \front\Views\ShopProduct::productUrl( $product );
|
||||
|
||||
if ( \Shared\Helpers\Helpers::get_session( 'current-lang' ) != ( new \Domain\Languages\LanguagesRepository( $GLOBALS['mdb'] ) )->defaultLanguage() and $url != '#')
|
||||
$url = '/' . \Shared\Helpers\Helpers::get_session('current-lang') . $url;
|
||||
|
||||
@@ -8,7 +8,7 @@
|
||||
|
||||
$basket = \Shared\Helpers\Helpers::get_session( 'basket' );
|
||||
$coupon = \Shared\Helpers\Helpers::get_session( 'coupon' );
|
||||
$transport_cost = \front\factory\ShopTransport::transport_cost( \Shared\Helpers\Helpers::get_session( 'basket-transport-method-id' ) );
|
||||
$transport_cost = ( new \Domain\Transport\TransportRepository( $GLOBALS['mdb'] ) )->transportCostCached( \Shared\Helpers\Helpers::get_session( 'basket-transport-method-id' ) );
|
||||
|
||||
$basket_summary = \Domain\Basket\BasketCalculator::summaryPrice( $basket, $coupon ) + $transport_cost;
|
||||
?>
|
||||
|
||||
Reference in New Issue
Block a user