updated the design for the room types and services on the customer view page for the admin

This commit is contained in:
vishalsingh.qlo325
2024-07-29 16:34:51 +05:30
parent 7b4339a40c
commit 878c657e41
4 changed files with 102 additions and 31 deletions

View File

@@ -854,7 +854,17 @@ class AdminCustomersControllerCore extends AdminController
}
}
$products = $customer->getBoughtProducts();
$purchasedServices = array();
$purchasedRoomTypes = array();
if ($products = $customer->getBoughtProducts()) {
foreach ($products as $product) {
if ($product['is_booking_product']) {
$purchasedRoomTypes[] = $product;
} else {
$purchasedServices[] = $product;
}
}
}
$carts = Cart::getCustomerCarts($customer->id);
$total_carts = count($carts);
@@ -953,6 +963,8 @@ class AdminCustomersControllerCore extends AdminController
'total_ko' => Tools::displayPrice($total_ko, $this->context->currency->id),
// Products
'products' => $products,
'purchasedRoomTypes' => $purchasedRoomTypes,
'purchasedServices' => $purchasedServices,
// Addresses
'addresses' => $customer->getAddresses($this->default_form_language),
// Discounts
@@ -1053,7 +1065,6 @@ class AdminCustomersControllerCore extends AdminController
parent::processBulkDelete();
}
public function processAdd()
{
if (Tools::getValue('submitFormAjax')) {