Added CMS_STORAGE.as_sql_storage: detachable CMS_STORAGE_SQL_I to ease development based on SQL database.
This commit is contained in:
@@ -27,7 +27,7 @@ feature {NONE} -- Initialization
|
||||
Precursor
|
||||
|
||||
-- Create the node storage for type blog
|
||||
if attached {CMS_STORAGE_SQL_I} storage as l_storage_sql then
|
||||
if attached storage.as_sql_storage as l_storage_sql then
|
||||
create {CMS_TAXONOMY_STORAGE_SQL} taxonomy_storage.make (l_storage_sql)
|
||||
else
|
||||
create {CMS_TAXONOMY_STORAGE_NULL} taxonomy_storage.make
|
||||
|
||||
13
modules/taxonomy/site/scripts/install.sql
Normal file
13
modules/taxonomy/site/scripts/install.sql
Normal file
@@ -0,0 +1,13 @@
|
||||
CREATE TABLE taxonomy_term (
|
||||
`tid` INTEGER NOT NULL PRIMARY KEY AUTO_INCREMENT UNIQUE,
|
||||
`text` VARCHAR(255) NOT NULL,
|
||||
`weight` INTEGER,
|
||||
`description` TEXT,
|
||||
`langcode` VARCHAR(12)
|
||||
);
|
||||
|
||||
CREATE TABLE taxonomy_hierarchy (
|
||||
`tid` INTEGER NOT NULL,
|
||||
`parent` INTEGER,
|
||||
CONSTRAINT PK_tid_parent PRIMARY KEY (tid,parent)
|
||||
);
|
||||
2
modules/taxonomy/site/scripts/uninstall.sql
Normal file
2
modules/taxonomy/site/scripts/uninstall.sql
Normal file
@@ -0,0 +1,2 @@
|
||||
DROP TABLE IF EXISTS taxonomy_term;
|
||||
DROP TABLE IF EXISTS taxonomy_hierarchy;
|
||||
Reference in New Issue
Block a user