CMXX - Categories and filters
This commit is contained in:
17
product.php
17
product.php
@@ -68,6 +68,12 @@ $products_configurations = ioServer($api_url,'');
|
||||
//Decode Payload
|
||||
if (!empty($products_configurations)){$products_configurations = json_decode($products_configurations,true);}else{$products_configurations = null;}
|
||||
|
||||
//GET RELATED CATEGORIES
|
||||
$api_url = '/v2/products_categories/product_id='.$_GET['rowID'];
|
||||
$product['categories'] = ioServer($api_url,'');
|
||||
//Decode Payload
|
||||
if (!empty($product['categories'] )){$product['categories'] = json_decode($product['categories'] ,true);}else{$product['categories'] = null;}
|
||||
|
||||
//------------------------------
|
||||
// Variables
|
||||
//------------------------------
|
||||
@@ -146,6 +152,17 @@ $view .= ' <div class="content-block order-details">
|
||||
<div class="order-detail">
|
||||
<h3>'.($product_quantity ?? 'Quantity').'</h3>
|
||||
<p>'.(${$responses->quantity} ?? $responses->quantity).'</p>
|
||||
</div>
|
||||
<div class="order-detail">
|
||||
<h3>'.($product_categories_text ?? 'Categories').'</h3>
|
||||
<p><div class="multiselect" data-name="categories[]">';
|
||||
foreach ($product['categories'] as $cat){
|
||||
$view .= ' <span class="item">
|
||||
<i class="remove">×</i>'.$cat['name'].'
|
||||
</span>';
|
||||
}
|
||||
$view .= ' </div>
|
||||
</p>
|
||||
</div>';
|
||||
|
||||
$view .='
|
||||
|
||||
Reference in New Issue
Block a user