ver. 0.294: Remove all 12 legacy autoload/shop/ classes (~2363 lines)

Complete Domain-Driven Architecture migration:
- Phase 1-4: Transport, ProductSet, Coupon, Shop, Search, Basket,
  ProductCustomField, Category, ProductAttribute, Promotion
- Phase 5: Order (~562 lines) + Product (~952 lines)
- ~20 Product methods migrated to ProductRepository
- Apilo sync migrated to OrderAdminService
- Production hotfixes: stale Redis cache (prices 0.00), unqualified
  Product:: refs in LayoutEngine, object->array template conversion
- AttributeRepository::getAttributeValueById() Redis cache added

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
2026-02-18 02:05:39 +01:00
parent 22530df501
commit 69e78ca248
74 changed files with 2176 additions and 2669 deletions

View File

@@ -123,7 +123,7 @@
</thead>
<tbody>
<? if ( \Shared\Helpers\Helpers::is_array_fix( $this -> best_sales_products ) ): foreach ( $this -> best_sales_products as $row ):?>
<? $product = \shop\Product::getFromCache( (int)$row['parent_product_id'], ( new \Domain\Languages\LanguagesRepository( $GLOBALS['mdb'] ) )->defaultLanguage() );?>
<? $product = (new \Domain\Product\ProductRepository($GLOBALS['mdb']))->findCached( (int)$row['parent_product_id'], ( new \Domain\Languages\LanguagesRepository( $GLOBALS['mdb'] ) )->defaultLanguage() );?>
<tr>
<td>
<?
@@ -132,7 +132,7 @@
echo '<img src="'. $product['images'][0]['src'] . '">';
?>
</td>
<td><?= $product -> language['name'];?></td>
<td><?= $product['language']['name'];?></td>
<td class="text-center"><?= $row['quantity_summary'];?></td>
<td class="text-right"><?= number_format( $row['sales'], 2, '.', " " );?> zł</td>
</tr>
@@ -158,7 +158,7 @@
</thead>
<tbody>
<? if ( \Shared\Helpers\Helpers::is_array_fix( $this -> most_view_products ) ): foreach ( $this -> most_view_products as $row ):?>
<? $product = new \shop\Product( $row['id'] );?>
<? $product = ( new \Domain\Product\ProductRepository( $GLOBALS['mdb'] ) )->findCached( $row['id'] );?>
<tr>
<td>
<?