Add view classes for articles, banners, languages, menu, newsletter, containers, shop categories, clients, payment methods, products, and search

- Created Articles.php for rendering article views including full articles, miniature lists, and news sections.
- Added Banners.php for handling banner displays.
- Introduced Languages.php for rendering language options.
- Implemented Menu.php for dynamic menu rendering.
- Developed Newsletter.php for newsletter view rendering.
- Created Scontainers.php for rendering specific containers.
- Added ShopCategory.php for category descriptions and product listings.
- Introduced ShopClient.php for managing client-related views such as address editing and order history.
- Implemented ShopPaymentMethod.php for displaying payment methods in the basket.
- Created ShopProduct.php for generating product URLs.
- Added ShopSearch.php for rendering a simple search form.
- Added .htaccess file to enhance security by restricting access to sensitive files and directories.
This commit is contained in:
2026-02-21 23:00:15 +01:00
parent b51244c1d6
commit 3ecbe628dc
435 changed files with 44107 additions and 31270 deletions

View File

@@ -32,7 +32,7 @@
</tr>
</thead>
<tbody>
<? if ( \S::is_array_fix( $this -> last_orders ) ): foreach ( $this -> last_orders as $order ):?>
<? if ( \Shared\Helpers\Helpers::is_array_fix( $this -> last_orders ) ): foreach ( $this -> last_orders as $order ):?>
<tr class="status-<?= $order['status'];?>">
<td><?= date( "Y-m-d H:i", strtotime( $order['date_order'] ) );?></td>
<td>
@@ -122,8 +122,8 @@
</tr>
</thead>
<tbody>
<? if ( \S::is_array_fix( $this -> best_sales_products ) ): foreach ( $this -> best_sales_products as $row ):?>
<? $product = \shop\Product::getFromCache( (int)$row['parent_product_id'], \front\factory\Languages::default_language() );?>
<? if ( \Shared\Helpers\Helpers::is_array_fix( $this -> best_sales_products ) ): foreach ( $this -> best_sales_products as $row ):?>
<? $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>
@@ -157,8 +157,8 @@
</tr>
</thead>
<tbody>
<? if ( \S::is_array_fix( $this -> most_view_products ) ): foreach ( $this -> most_view_products as $row ):?>
<? $product = new \shop\Product( $row['id'] );?>
<? if ( \Shared\Helpers\Helpers::is_array_fix( $this -> most_view_products ) ): foreach ( $this -> most_view_products as $row ):?>
<? $product = ( new \Domain\Product\ProductRepository( $GLOBALS['mdb'] ) )->findCached( $row['id'] );?>
<tr>
<td>
<?