Skip to content
Snippets Groups Projects
Verified Commit 98133475 authored by Timm Fitschen's avatar Timm Fitschen
Browse files

WIP: file system refactoring: link

parent 16ed23be
No related branches found
No related tags found
1 merge request!13Draft: EHN: file system: link
......@@ -64,12 +64,16 @@ ALTER TABLE files ADD FOREIGN KEY (parent_directory) REFERENCES entities (id);
ALTER TABLE archive_files ADD FOREIGN KEY (parent_directory) REFERENCES entities (id) ON DELETE CASCADE;
ALTER TABLE entities MODIFY COLUMN `role` enum('RECORDTYPE','RECORD','FILE','DOMAIN','PROPERTY','DATATYPE','ROLE','QUERYTEMPLATE', 'DIRECTORY') COLLATE utf8_unicode_ci NOT NULL;
ALTER TABLE entities MODIFY COLUMN `role` enum('RECORDTYPE','RECORD','FILE','DOMAIN','PROPERTY','DATATYPE','ROLE','QUERYTEMPLATE', 'DIRECTORY', 'LINK') COLLATE utf8_unicode_ci NOT NULL;
-- Add a new special role "DIRECTORY"
INSERT IGNORE INTO entities (id, description, role, acl) VALUES (9, "The directory role.", "ROLE", 0);
INSERT IGNORE INTO name_data (domain_id, entity_id, property_id, value, status, pidx) VALUES (0, 9, 20, "DIRECTORY", "FIX", 0);
-- Add a new special role "LINK"
INSERT IGNORE INTO entities (id, description, role, acl) VALUES (10, "The link role.", "ROLE", 0);
INSERT IGNORE INTO name_data (domain_id, entity_id, property_id, value, status, pidx) VALUES (0, 10, 20, "LINK", "FIX", 0);
-- In the default file storage back-end the key is just the path.
UPDATE files SET file_key=path;
UPDATE archive_files SET file_key=path;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment