Merge branch 'development' of https://github.com/PrestaShop/PrestaShop into bootstrap
Conflicts: admin-dev/themes/default/css/modules.css admin-dev/themes/default/template/controllers/carts/helpers/view/view.tpl admin-dev/themes/default/template/controllers/groups/helpers/form/form.tpl admin-dev/themes/default/template/controllers/groups/helpers/view/view.tpl admin-dev/themes/default/template/controllers/products/helpers/form/form.tpl admin-dev/themes/default/template/controllers/products/images.tpl admin-dev/themes/default/template/controllers/products/prices.tpl admin-dev/themes/default/template/helpers/form/form.tpl admin-dev/themes/default/template/helpers/list/list_header.tpl classes/Autoload.php classes/Carrier.php classes/Product.php classes/ProductSale.php classes/Tools.php classes/Validate.php classes/tax/TaxRulesTaxManager.php controllers/admin/AdminPPreferencesController.php controllers/admin/AdminPerformanceController.php install-dev/install_version.php js/admin_carrier_wizard.js modules/blockcategories/blockcategories.php modules/blocklayered/blocklayered.php modules/statsequipment/statsequipment.php modules/statsproduct/statsproduct.php modules/watermark/watermark.php themes/default/address.tpl themes/default/authentication.tpl themes/default/category.tpl themes/default/contact-form.tpl themes/default/css/history.css themes/default/header.tpl themes/default/js/cart-summary.js themes/default/js/product.js themes/default/mobile/order-detail.tpl themes/default/modules/blocksearch/blocksearch.tpl themes/default/modules/productcomments/productcomments.tpl themes/default/order-carrier.tpl themes/default/order-detail.tpl themes/default/order-opc-new-account.tpl themes/default/product.tpl
This commit is contained in:
@@ -38,22 +38,25 @@ function add_module_to_hook($module_name, $hook_name)
|
||||
$id_hook = Db::getInstance()->getValue('SELECT `id_hook` FROM `'._DB_PREFIX_.'hook` WHERE `name` = "'.$hook_name.'"');
|
||||
if(!$id_hook)
|
||||
{
|
||||
$res &= Db::getInstance()->execute('
|
||||
if (!Db::getInstance()->execute('
|
||||
INSERT IGNORE INTO `'._DB_PREFIX_.'hook` (`name`, `title`)
|
||||
VALUES ("'.pSQL($hook_name).'", "'.pSQL($hook_name).'")');
|
||||
$id_hook = Db::getInstance()->Insert_ID();
|
||||
VALUES ("'.pSQL($hook_name).'", "'.pSQL($hook_name).'")'))
|
||||
$res = false;
|
||||
else
|
||||
$id_hook = Db::getInstance()->Insert_ID();
|
||||
}
|
||||
|
||||
if ((int)$id_hook > 0)
|
||||
{
|
||||
$res &= Db::getInstance()->execute('
|
||||
if (!Db::getInstance()->execute('
|
||||
INSERT IGNORE INTO `'._DB_PREFIX_.'hook_module` (`id_module`, `id_hook`, `position`)
|
||||
VALUES (
|
||||
'.(int)$id_module.',
|
||||
'.(int)$id_hook.',
|
||||
(SELECT IFNULL(
|
||||
(SELECT max_position from (SELECT MAX(position)+1 as max_position FROM `'._DB_PREFIX_.'hook_module` WHERE `id_hook` = '.(int)$id_hook.') AS max_position), 1))
|
||||
)');
|
||||
)'))
|
||||
$res = false;
|
||||
}
|
||||
}
|
||||
return $res;
|
||||
|
||||
@@ -41,10 +41,10 @@ function create_multistore()
|
||||
// @todo generate __PS_BASE_URI__ using $_SERVER['REQUEST_URI'], just in case
|
||||
return false;
|
||||
}
|
||||
$all_themes_dir = _PS_ROOT_DIR_.'/themes';
|
||||
$all_themes_dir = _PS_ROOT_DIR_.DIRECTORY_SEPARATOR.'themes';
|
||||
$themes = scandir($all_themes_dir);
|
||||
foreach ($themes AS $theme)
|
||||
if (is_dir($all_themes_dir.'/'.$theme)
|
||||
if (is_dir($all_themes_dir.DIRECTORY_SEPARATOR.$theme.DIRECTORY_SEPARATOR)
|
||||
&& $theme[0] != '.'
|
||||
&& $theme != 'prestashop')
|
||||
{
|
||||
@@ -73,8 +73,8 @@ function create_multistore()
|
||||
$shop_domain_ssl = create_multistore_getHttpHost();
|
||||
}
|
||||
|
||||
$_PS_DIRECTORY_ = trim(str_replace(' ', '%20', $INSTALLER__PS_BASE_URI), '/');
|
||||
$_PS_DIRECTORY_ = ($_PS_DIRECTORY_) ? '/'.$_PS_DIRECTORY_.'/' : '/';
|
||||
$_PS_DIRECTORY_ = trim(str_replace(' ', '%20', $INSTALLER__PS_BASE_URI), DIRECTORY_SEPARATOR);
|
||||
$_PS_DIRECTORY_ = ($_PS_DIRECTORY_) ? '/'.$_PS_DIRECTORY_.DIRECTORY_SEPARATOR : DIRECTORY_SEPARATOR;
|
||||
$res &= Db::getInstance()->execute('INSERT INTO `'._DB_PREFIX_.'shop_url` (`id_shop`, `domain`, `domain_ssl`, `physical_uri`, `virtual_uri`, `main`, `active`)
|
||||
VALUES(1, \''.pSQL($shop_domain).'\', \''.pSQL($shop_domain_ssl).'\', \''.pSQL($_PS_DIRECTORY_).'\', \'\', 1, 1)');
|
||||
|
||||
|
||||
@@ -31,7 +31,7 @@ function deactivate_custom_modules()
|
||||
$modules = scandir(_PS_MODULE_DIR_);
|
||||
foreach ($modules AS $name)
|
||||
{
|
||||
if (is_dir(_PS_MODULE_DIR_.$name) && file_exists(_PS_MODULE_DIR_.$name.'/'.$name.'.php'))
|
||||
if (is_dir(_PS_MODULE_DIR_.$name.'/') && file_exists(_PS_MODULE_DIR_.$name.'/'.$name.'.php'))
|
||||
{
|
||||
if (!preg_match('/^[a-zA-Z0-9_-]+$/', $name))
|
||||
die(Tools::displayError().' (Module '.$name.')');
|
||||
|
||||
@@ -68,7 +68,7 @@ function update_customer_default_group()
|
||||
if($result && file_exists($filename_old))
|
||||
{
|
||||
unlink($filename_old);
|
||||
chmod($filename, 0664);
|
||||
@chmod($filename, 0664);
|
||||
}
|
||||
}
|
||||
return $result;
|
||||
|
||||
Reference in New Issue
Block a user