// id_category_default is now for multishop

This commit is contained in:
vChabot
2012-02-27 13:53:52 +00:00
parent 7e0e9e2adb
commit 77774d0d94
22 changed files with 172 additions and 49 deletions
+1
View File
@@ -2045,6 +2045,7 @@ PRIMARY KEY (`id_store`, `id_shop`),
CREATE TABLE `PREFIX_product_shop` (
`id_product` INT( 11 ) UNSIGNED NOT NULL,
`id_shop` INT( 11 ) UNSIGNED NOT NULL,
`id_category_default` INT( 11 ) UNSIGNED DEFAULT NULL,
PRIMARY KEY ( `id_shop` , `id_product` ),
KEY `id_shop` (`id_shop`)
) ENGINE=ENGINE_TYPE DEFAULT CHARSET=utf8;
+6
View File
@@ -866,5 +866,11 @@
<configuration id="PS_STORES_ICON" name="PS_STORES_ICON">
<value>logo_stores.gif</value>
</configuration>
<configuration id="PS_ROOT_CATEGORY" name="PS_ROOT_CATEGORY">
<value>1</value>
</configuration>
<configuration id="PS_HOME_CATEGORY" name="PS_HOME_CATEGORY">
<value>2</value>
</configuration>
</entities>
</entity_configuration>
@@ -13,6 +13,9 @@ function generate_root_category_for_multishop()
(0, 0, 1, NOW(), NOW(), 0)
');
$id = Db::getInstance()->insert_id();
// set vars config
Configuration::set('PS_ROOT_CATEGORY', $id);
Configuration::set('PS_HOME_CATEGORY', 1);
$langs = Db::getInstance()->executeS('
SELECT `id_lang`
+2
View File
@@ -31,3 +31,5 @@ CREATE TABLE `PREFIX_carrier_tax_rules_group_shop` (
INSERT INTO `PREFIX_carrier_tax_rules_group_shop` (`id_carrier`, `id_tax_rules_group`, `id_shop`)
(SELECT `id_carrier`, `id_tax_rules_group`, `id_shop` FROM `PREFIX_carrier`, `PREFIX_shop`);
ALTER TABLE `PREFIX_carrier` DROP `id_tax_rules_group`;
ALTER TABLE `PREFIX_product_shop` ADD `id_category_default` INT( 11 ) UNSIGNED DEFAULT NULL;