Merge branch 'develop' into gli-2963

This commit is contained in:
azhar bhat
2026-04-16 16:10:26 +05:30
14 changed files with 271 additions and 98 deletions

View File

@@ -1477,10 +1477,7 @@ class CartRuleCore extends ObjectModel
*/
public static function isFeatureActive()
{
static $is_feature_active = null;
if ($is_feature_active === null) {
$is_feature_active = (bool)Configuration::get('PS_CART_RULE_FEATURE_ACTIVE');
}
$is_feature_active = (bool)Configuration::get('PS_CART_RULE_FEATURE_ACTIVE');
return $is_feature_active;
}

View File

@@ -141,11 +141,18 @@ class ProfileCore extends ObjectModel
);
}
} else {
$result = Db::getInstance()->executeS('
SELECT *
FROM `'._DB_PREFIX_.'access` a
LEFT JOIN `'._DB_PREFIX_.'tab` t ON t.id_tab = a.id_tab
WHERE `id_profile` = '.(int)$id_profile);
if ($result = Db::getInstance()->executeS('
SELECT * FROM `'._DB_PREFIX_.'access` a
LEFT JOIN `'._DB_PREFIX_.'tab` t ON t.id_tab = a.id_tab
WHERE `id_profile` = '.(int)$id_profile)
) {
foreach ($result as $key => $profileAccess) {
$result[$key]['view'] = (int) $profileAccess['view'];
$result[$key]['delete'] = (int) $profileAccess['delete'];
$result[$key]['add'] = (int) $profileAccess['add'];
$result[$key]['edit'] = (int) $profileAccess['edit'];
}
}
foreach ($result as $row) {
self::$_cache_accesses[$id_profile][$type][$row[$type]] = $row;

View File

@@ -2608,29 +2608,26 @@ FileETag none
public static function getDefaultIndexContent()
{
return '<?php
/**
* 2007-'.date('Y').' PrestaShop
*
/*
* NOTICE OF LICENSE
*
* This source file is subject to the Open Software License (OSL 3.0)
* that is bundled with this package in the file LICENSE.txt.
* This source file is subject to the Open Software License version 3.0
* that is bundled with this package in the file LICENSE.md
* It is also available through the world-wide-web at this URL:
* http://opensource.org/licenses/osl-3.0.php
* https://opensource.org/license/osl-3-0-php
* If you did not receive a copy of the license and are unable to
* obtain it through the world-wide-web, please send an email
* to license@prestashop.com so we can send you a copy immediately.
* to support@qloapps.com so we can send you a copy immediately.
*
* DISCLAIMER
*
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
* versions in the future. If you wish to customize PrestaShop for your
* needs please refer to http://www.prestashop.com for more information.
* Do not edit or add to this file if you wish to upgrade this module to a newer
* versions in the future. If you wish to customize this module for your needs
* please refer to https://store.webkul.com/customisation-guidelines for more information.
*
* @author PrestaShop SA <contact@prestashop.com>
* @copyright 2007-'.date('Y').' PrestaShop SA
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
* International Registered Trademark & Property of PrestaShop SA
* @author Webkul IN
* @copyright Since 2010 Webkul
* @license https://opensource.org/license/osl-3-0-php Open Software License version 3.0
*/
header("Expires: Mon, 26 Jul 1997 05:00:00 GMT");

View File

@@ -37,7 +37,8 @@ class CacheFsCore extends Cache
$keys_filename = $this->getFilename(self::KEYS_NAME);
if (@filemtime($keys_filename)) {
$this->keys = unserialize(file_get_contents($keys_filename));
$keys = @unserialize(file_get_contents($keys_filename));
$this->keys = is_array($keys) ? $keys : array();
}
}

View File

@@ -507,7 +507,7 @@ class WebserviceSpecificManagementBookingsCore Extends ObjectModel implements We
$formattedRooms[$key]['occupancy'] = $occupancy;
if (isset($room['id_tax_rules_group'])) {
$formattedRooms[$key]['id_tax_rules_group'] = $room['id_tax_rules_group'];
} else if ($room['total_tax']) {
} else if (isset($room['total_tax'])) {
$formattedRooms[$key]['total_tax'] = $room['total_tax'];
}
}