From 347c0176a518dda606e274913d58f4d534b731c7 Mon Sep 17 00:00:00 2001 From: Jerome Nadaud Date: Wed, 11 Dec 2013 11:44:34 +0100 Subject: [PATCH] [-] CORE : FixBug #PSCSX-89 - Up configuration name size to 255 --- classes/Configuration.php | 2 +- install-dev/data/db_structure.sql | 2 +- install-dev/upgrade/sql/1.6.0.2.sql | 2 ++ 3 files changed, 4 insertions(+), 2 deletions(-) diff --git a/classes/Configuration.php b/classes/Configuration.php index 570435a2f..0cc4bb8d9 100644 --- a/classes/Configuration.php +++ b/classes/Configuration.php @@ -51,7 +51,7 @@ class ConfigurationCore extends ObjectModel 'primary' => 'id_configuration', 'multilang' => true, 'fields' => array( - 'name' => array('type' => self::TYPE_STRING, 'validate' => 'isConfigName', 'required' => true, 'size' => 32), + 'name' => array('type' => self::TYPE_STRING, 'validate' => 'isConfigName', 'required' => true, 'size' => 255), 'id_shop_group' => array('type' => self::TYPE_NOTHING, 'validate' => 'isUnsignedId'), 'id_shop' => array('type' => self::TYPE_NOTHING, 'validate' => 'isUnsignedId'), 'value' => array('type' => self::TYPE_STRING), diff --git a/install-dev/data/db_structure.sql b/install-dev/data/db_structure.sql index ef426e1ac..07fa7535d 100644 --- a/install-dev/data/db_structure.sql +++ b/install-dev/data/db_structure.sql @@ -423,7 +423,7 @@ CREATE TABLE `PREFIX_configuration` ( `id_configuration` int(10) unsigned NOT NULL auto_increment, `id_shop_group` INT(11) UNSIGNED DEFAULT NULL, `id_shop` INT(11) UNSIGNED DEFAULT NULL, - `name` varchar(32) NOT NULL, + `name` varchar(255) NOT NULL, `value` text, `date_add` datetime NOT NULL, `date_upd` datetime NOT NULL, diff --git a/install-dev/upgrade/sql/1.6.0.2.sql b/install-dev/upgrade/sql/1.6.0.2.sql index 5eba8ecf0..87864e483 100644 --- a/install-dev/upgrade/sql/1.6.0.2.sql +++ b/install-dev/upgrade/sql/1.6.0.2.sql @@ -6,3 +6,5 @@ INSERT INTO `PREFIX_hook_module` (`id_module`, `id_shop`, `id_hook`, `position`) WHERE m.name IN ('dashgoals', 'dashactivity', 'dashtrends', 'dashproducts') AND h.name IN ('actionAdminControllerSetMedia') ); + +ALTER TABLE `PREFIX_configuration` CHANGE `name` `name` VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL;