[-] Installer : changed the primary keys of tha language tables of category, product, meta, carrier #PSCFV-3726
git-svn-id: http://dev.prestashop.com/svn/v1/branches/1.5.x@17291 b9a71923-0436-4b27-9f14-aed3839534dd
This commit is contained in:
+129
-129
File diff suppressed because it is too large
Load Diff
@@ -28,16 +28,14 @@
|
||||
function add_id_shop_to_shipper_lang_index()
|
||||
{
|
||||
$res = true;
|
||||
$key_exists = Db::getInstance()->executeS('SHOW INDEX
|
||||
FROM `'._DB_PREFIX_.'carrier_lang`
|
||||
WHERE Key_name = "shipper_lang_index"');
|
||||
|
||||
$key_exists = Db::getInstance()->executeS('
|
||||
SHOW INDEX
|
||||
FROM `'._DB_PREFIX_.'carrier_lang`
|
||||
WHERE Key_name = "shipper_lang_index"');
|
||||
if ($key_exists)
|
||||
$res &= Db::getInstance()->execute('ALTER TABLE
|
||||
`'._DB_PREFIX_.'carrier_lang`
|
||||
DROP KEY `shipper_lang_index`');
|
||||
$res &= Db::getInstance()->execute('ALTER TABLE
|
||||
`'._DB_PREFIX_.'carrier_lang`
|
||||
ADD UNIQUE `shipper_lang_index` (`id_carrier`, `id_shop`, `id_lang`)');
|
||||
$res &= Db::getInstance()->execute('ALTER TABLE `'._DB_PREFIX_.'carrier_lang` DROP KEY `shipper_lang_index`');
|
||||
$res &= Db::getInstance()->execute('ALTER TABLE `'._DB_PREFIX_.'carrier_lang` ADD PRIMARY KEY (`id_carrier`, `id_shop`, `id_lang`)');
|
||||
|
||||
return $res;
|
||||
}
|
||||
|
||||
@@ -5,4 +5,6 @@ ALTER TABLE `PREFIX_order_detail_tax` CHANGE `total_amount` `total_amount` DECIM
|
||||
|
||||
ALTER TABLE `PREFIX_customer_message` ADD `read` tinyint(1) NOT NULL default '0' AFTER `private`;
|
||||
|
||||
INSERT INTO `PREFIX_configuration`(`name`, `value`, `date_add`, `date_upd`) VALUES ('PS_ALLOW_MOBILE_DEVICE', '1', NOW(), NOW());
|
||||
INSERT INTO `PREFIX_configuration`(`name`, `value`, `date_add`, `date_upd`) VALUES ('PS_ALLOW_MOBILE_DEVICE', '1', NOW(), NOW());
|
||||
|
||||
/* PHP:p15017_add_id_shop_to_primary_key(); */;
|
||||
|
||||
Reference in New Issue
Block a user