Merge branch 'develop' into gli-1944
This commit is contained in:
@@ -152,7 +152,7 @@
|
||||
{l s='All'} <span class="badge pull-right">{$nb_modules}</span>
|
||||
</a>
|
||||
{foreach from=$list_modules_categories item=module_category key=module_category_key}
|
||||
<a class="categoryModuleFilterLink list-group-item {if isset($categoryFiltered[$module_category_key])}active{/if}" href="{$currentIndex|escape:'html':'UTF-8'}&token={$token|escape:'html':'UTF-8'}&{if isset($categoryFiltered[$module_category_key])}un{/if}filterCategory={$module_category_key}" id="filter_{$module_category_key}">
|
||||
<a class="categoryModuleFilterLink list-group-item {if isset($categoryFiltered[$module_category_key])}active{/if}" href="{$currentIndex|escape:'html':'UTF-8'}&token={$token|escape:'html':'UTF-8'}&filterCategory={$module_category_key}" id="filter_{$module_category_key}">
|
||||
{$module_category.name} <span class="badge pull-right">{$module_category.nb}</span>
|
||||
</a>
|
||||
{/foreach}
|
||||
|
||||
@@ -104,6 +104,7 @@ class TaxRulesTaxManagerCore implements TaxManagerInterface
|
||||
AND tr.`id_country` = '.(int)$this->address->id_country.'
|
||||
AND tr.`id_tax_rules_group` = '.(int)$this->type.'
|
||||
AND tr.`id_state` IN (0, '.(int)$this->address->id_state.')
|
||||
AND tr.`id_tax` !=0
|
||||
AND (\''.pSQL($postcode).'\' BETWEEN tr.`zipcode_from` AND tr.`zipcode_to`
|
||||
OR (tr.`zipcode_to` = 0 AND tr.`zipcode_from` IN(0, \''.pSQL($postcode).'\')))
|
||||
ORDER BY tr.`zipcode_from` DESC, tr.`zipcode_to` DESC, tr.`id_state` DESC, tr.`id_country` DESC');
|
||||
|
||||
@@ -186,19 +186,17 @@ class AdminNormalProductsControllerCore extends AdminController
|
||||
|
||||
$id_shop = Shop::isFeatureActive() && Shop::getContext() == Shop::CONTEXT_SHOP? (int)$this->context->shop->id : 'a.id_shop_default';
|
||||
$this->_join .= ' JOIN `'._DB_PREFIX_.'product_shop` sa ON (a.`id_product` = sa.`id_product` AND sa.id_shop = '.$id_shop.')
|
||||
LEFT JOIN `'._DB_PREFIX_.'htl_room_type` hrt ON (a.`id_product` = hrt.`id_product`)
|
||||
LEFT JOIN `'._DB_PREFIX_.'htl_branch_info` hb ON (hrt.`id_hotel` = hb.`id`)
|
||||
LEFT JOIN `'._DB_PREFIX_.'htl_branch_info_lang` hbl ON (hb.`id` = hbl.`id` AND b.`id_lang` = hbl.`id_lang`)
|
||||
LEFT JOIN `'._DB_PREFIX_.'category_lang` cl ON ('.$alias.'.`id_category_default` = cl.`id_category` AND b.`id_lang` = cl.`id_lang` AND cl.id_shop = '.$id_shop.')
|
||||
LEFT JOIN `'._DB_PREFIX_.'shop` shop ON (shop.id_shop = '.$id_shop.')
|
||||
LEFT JOIN `'._DB_PREFIX_.'image_shop` image_shop ON (image_shop.`id_product` = a.`id_product` AND image_shop.`cover` = 1 AND image_shop.id_shop = '.$id_shop.')
|
||||
LEFT JOIN `'._DB_PREFIX_.'image` i ON (i.`id_image` = image_shop.`id_image`)
|
||||
LEFT JOIN `'._DB_PREFIX_.'product_download` pd ON (pd.`id_product` = a.`id_product` AND pd.`active` = 1)
|
||||
LEFT JOIN `'._DB_PREFIX_.'htl_room_type_service_product` rsp ON (rsp.`id_product` = a.`id_product`)
|
||||
LEFT JOIN `'._DB_PREFIX_.'address` aa ON (aa.`id_hotel` = hb.`id`)';
|
||||
LEFT JOIN `'._DB_PREFIX_.'htl_room_type` hrt ON (rsp.`id_element` = hrt.`id_product` AND rsp.`element_type` = '.(int)RoomTypeServiceProduct::WK_ELEMENT_TYPE_ROOM_TYPE.')
|
||||
'.HotelBranchInformation::addHotelRestriction(false, 'hrt');
|
||||
|
||||
$this->_select .= ' IF(a.`auto_add_to_cart`, "'.$this->l('Yes').'", "'.$this->l('No').'") as auto_added, IF(a.`auto_add_to_cart`, 1, 0) as badge_success, IF(a.`show_at_front`, "'.$this->l('Yes').'", "'.$this->l('No').'") as show_at_front_txt, IF(a.`price_calculation_method` = '.(int)Product::PRICE_CALCULATION_METHOD_PER_DAY.', "'.$this->l('Per Day').'", "'.$this->l('Per Booking').'") as price_calculation_method_txt, (SELECT COUNT(hri.`id`) FROM `'._DB_PREFIX_.'htl_room_information` hri WHERE hri.`id_product` = a.`id_product`) as num_rooms, ';
|
||||
$this->_select .= ' COUNT(rsp.`id_product`) as products_associated, hrt.`adults`, hrt.`children`, hb.`id` as id_hotel, aa.`city`, hbl.`hotel_name`, ';
|
||||
$this->_select .= ' COUNT(hrt.`id_product`) as products_associated, ';
|
||||
$this->_select .= 'shop.`name` AS `shopname`, a.`id_shop_default`, ';
|
||||
$this->_select .= $alias_image.'.`id_image` AS `id_image`, cl.`name` AS `name_category`, '.$alias.'.`price`, 0 AS `price_final`, a.`is_virtual`, pd.`nb_downloadable`, sav.`quantity` AS `sav_quantity`, '.$alias.'.`active`, IF(sav.`quantity`<=0, 1, 0) AS `badge_danger`';
|
||||
|
||||
|
||||
@@ -677,6 +677,8 @@ class AdminThemesControllerCore extends AdminController
|
||||
|
||||
if (!count($this->errors)) {
|
||||
Tools::redirectAdmin(Context::getContext()->link->getAdminLink('AdminThemes').'&conf=6');
|
||||
} else {
|
||||
$this->redirect_after = '';
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1981,7 +1983,7 @@ class AdminThemesControllerCore extends AdminController
|
||||
}
|
||||
}
|
||||
if ($xml_version_too_old && !$this->_checkConfigForFeatures(array_keys(AdminThemes::$check_features))) {
|
||||
$this->errors[] .= Tools::displayError('The config.xml file has not been created for this version of PrestaShop.');
|
||||
$this->errors[] = Tools::displayError('The config.xml file has not been created for this version of QloApps.');
|
||||
$return = false;
|
||||
}
|
||||
|
||||
|
||||
@@ -100,6 +100,7 @@ class OrderDetailControllerCore extends FrontController
|
||||
$total_demands_price_ti = 0;
|
||||
$total_convenience_fee_te = 0;
|
||||
$total_convenience_fee_ti = 0;
|
||||
$roomTypes = array();
|
||||
if (!empty($products)) {
|
||||
foreach ($products as $type_key => $type_value) {
|
||||
if (in_array($type_value['product_id'], $processedProducts)) {
|
||||
@@ -374,7 +375,7 @@ class OrderDetailControllerCore extends FrontController
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
$roomTypes[$type_value['id_product']] = $type_value;
|
||||
}
|
||||
|
||||
$redirectTermsLink = $this->context->link->getCMSLink(new CMS(3, $this->context->language->id), null, $this->context->language->id);
|
||||
@@ -437,6 +438,7 @@ class OrderDetailControllerCore extends FrontController
|
||||
'order_history' => $order->getHistory($this->context->language->id, false, true),
|
||||
'overbooking_order_states' => OrderState::getOverBookingStates(),
|
||||
'products' => $products,
|
||||
'roomTypes' => $roomTypes,
|
||||
'discounts' => $order->getCartRules(),
|
||||
'carrier' => $carrier,
|
||||
'address_invoice' => $addressInvoice,
|
||||
|
||||
@@ -454,7 +454,7 @@
|
||||
|
||||
<select name="id_product" class="form-control">
|
||||
<option value="0">{l s='-- Choose --'}</option>
|
||||
{foreach from=$products item=product}
|
||||
{foreach from=$roomTypes item=product}
|
||||
{if $product.is_booking_product}
|
||||
<option value="{$product.product_id}">{$product.product_name|escape:'html':'UTF-8'}</option>
|
||||
{/if}
|
||||
|
||||
Reference in New Issue
Block a user