From 95b332586c934e90df75078045c752251af5c9e4 Mon Sep 17 00:00:00 2001 From: Uwe Steinmann Date: Mon, 30 May 2016 20:24:49 +0200 Subject: [PATCH] add initial roles --- install/create_tables-innodb.sql | 3 +++ install/create_tables-sqlite3.sql | 3 +++ 2 files changed, 6 insertions(+) diff --git a/install/create_tables-innodb.sql b/install/create_tables-innodb.sql index 83af2822f..63dccca0d 100644 --- a/install/create_tables-innodb.sql +++ b/install/create_tables-innodb.sql @@ -932,6 +932,9 @@ CREATE TABLE `tblVersion` ( -- Initial content for database -- +INSERT INTO `tblRoles` (`id`, `name`, `role`) VALUES (1, 'Admin', 1); +INSERT INTO `tblRoles` (`id`, `name`, `role`) VALUES (2, 'Guest', 2); +INSERT INTO `tblRoles` (`id`, `name`, `role`) VALUES (3, 'User', 0); INSERT INTO tblUsers VALUES (1, 'admin', '21232f297a57a5a743894a0e4a801fc3', 'Administrator', 'address@server.com', '', '', '', 1, 0, '0000-00-00 00:00:00', 0, 0, 0, NULL); INSERT INTO tblUsers VALUES (2, 'guest', NULL, 'Guest User', NULL, '', '', '', 2, 0, '0000-00-00 00:00:00', 0, 0, 0, NULL); INSERT INTO tblFolders VALUES (1, 'DMS', 0, '', 'DMS root', UNIX_TIMESTAMP(), 1, 0, 2, 0); diff --git a/install/create_tables-sqlite3.sql b/install/create_tables-sqlite3.sql index 1bd57c948..ad0720acf 100644 --- a/install/create_tables-sqlite3.sql +++ b/install/create_tables-sqlite3.sql @@ -796,6 +796,9 @@ CREATE TABLE `tblVersion` ( -- Initial content for database -- +INSERT INTO `tblRoles` (`id`, `name`, `role`) VALUES (1, 'Admin', 1); +INSERT INTO `tblRoles` (`id`, `name`, `role`) VALUES (2, 'Guest', 2); +INSERT INTO `tblRoles` (`id`, `name`, `role`) VALUES (3, 'User', 0); INSERT INTO tblUsers VALUES (1, 'admin', '21232f297a57a5a743894a0e4a801fc3', 'Administrator', 'address@server.com', '', '', '', 1, 0, '', 0, 0, 0, 0); INSERT INTO tblUsers VALUES (2, 'guest', NULL, 'Guest User', NULL, '', '', '', 2, 0, '', 0, 0, 0, 0); INSERT INTO tblFolders VALUES (1, 'DMS', 0, '', 'DMS root', strftime('%s','now'), 1, 0, 2, 0);