Changeset 542
- Timestamp:
- 05/28/09 16:17:42 (3 years ago)
- Location:
- trunk/phpbms
- Files:
-
- 22 modified
-
install/createtables.sql (modified) (10 diffs)
-
install/files.sql (modified) (2 diffs)
-
install/notes.sql (modified) (1 diff)
-
install/scheduler.sql (modified) (1 diff)
-
install/smartsearches.sql (modified) (1 diff)
-
install/tabledefs.sql (modified) (1 diff)
-
install/tabs.sql (modified) (1 diff)
-
install/updatev0.98.sql (modified) (6 diffs)
-
install/users.sql (modified) (1 diff)
-
modules/bms/install/createtables.sql (modified) (12 diffs)
-
modules/bms/install/roles.sql (modified) (1 diff)
-
modules/bms/install/shippingmethods.sql (modified) (1 diff)
-
modules/bms/install/smartsearches.sql (modified) (1 diff)
-
modules/bms/install/tabledefs.sql (modified) (1 diff)
-
modules/bms/install/tabs.sql (modified) (1 diff)
-
modules/bms/install/updatev0.98.sql (modified) (6 diffs)
-
modules/recurringinvoices/install/roles.sql (modified) (1 diff)
-
modules/recurringinvoices/install/scheduler.sql (modified) (1 diff)
-
modules/recurringinvoices/install/tabledefs.sql (modified) (1 diff)
-
modules/recurringinvoices/install/tabs.sql (modified) (1 diff)
-
modules/recurringinvoices/install/updatev1.03.sql (modified) (1 diff)
-
modules/recurringinvoices/install/users.sql (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
trunk/phpbms/install/createtables.sql
r540 r542 44 44 CREATE TABLE modules ( 45 45 id int(11) NOT NULL auto_increment, 46 `uuid` varchar(64) NOT NULL, 46 47 displayname varchar(128) NOT NULL default '', 47 48 name varchar(64) NOT NULL default '', … … 53 54 CREATE TABLE `notes` ( 54 55 `id` int(11) NOT NULL AUTO_INCREMENT, 56 `uuid` varchar(64) NOT NULL, 55 57 `assignedtoid` int(11) default NULL, 56 58 `attachedid` int(11) default NULL, … … 103 105 CREATE TABLE relationships ( 104 106 id int(11) NOT NULL auto_increment, 107 `uuid` varchar(64) NOT NULL, 105 108 tofield varchar(32) NOT NULL default '', 106 109 name varchar(128) NOT NULL default '', … … 154 157 CREATE TABLE `tabledefs` ( 155 158 `id` int(11) NOT NULL auto_increment, 159 `uuid` varchar(64) NOT NULL, 156 160 `displayname` varchar(64) default NULL, 157 161 `prefix` varchar(4) default NULL, … … 234 238 CREATE TABLE users ( 235 239 `id` INTEGER NOT NULL AUTO_INCREMENT, 240 `uuid` varchar(64) NOT NULL, 236 241 login varchar(64) NOT NULL default '', 237 242 password blob, … … 285 290 CREATE TABLE `files` ( 286 291 `id` int(11) NOT NULL auto_increment, 292 `uuid` varchar(64) NOT NULL, 287 293 `name` varchar(128) NOT NULL default '', 288 294 `description` text, … … 322 328 CREATE TABLE `roles` ( 323 329 `id` INTEGER UNSIGNED DEFAULT NULL AUTO_INCREMENT, 330 `uuid` varchar(64) NOT NULL, 324 331 `name` VARCHAR(64) NOT NULL, 325 332 `description` TEXT, … … 349 356 CREATE TABLE `scheduler` ( 350 357 `id` INTEGER UNSIGNED NOT NULL AUTO_INCREMENT, 358 `uuid` varchar(64) NOT NULL, 351 359 `name` varchar(45) default NULL, 352 360 `job` varchar(128) default NULL, … … 369 377 CREATE TABLE `tabs` ( 370 378 `id` int(10) unsigned NOT NULL AUTO_INCREMENT, 379 `uuid` varchar(64) NOT NULL, 371 380 `name` varchar(45) NOT NULL, 372 381 `tabgroup` varchar(45) NOT NULL, … … 386 395 CREATE TABLE `smartsearches` ( 387 396 `id` int(10) unsigned NOT NULL auto_increment, 397 `uuid` varchar(64) NOT NULL, 388 398 `name` varchar(128) NOT NULL, 389 399 `fromclause` text NOT NULL, -
trunk/phpbms/install/files.sql
r520 r542 1 INSERT INTO files (`id`, `name`, `description`, `file`, `type`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`, `roleid`) VALUES (1,'logo.png','Company Logo Used in PDF reports','PNG\r\n\Z\n\0\0\0\rIHDR\0\0\0\0\0]\0\0\0S°\0\0\0gAMA\0\0¯È7é\0\0\0tEXtSoftware\0Adobe ImageReadyqÉe<\0\0\0`PLTE666ÑÑѶ¶¶óó󪪪kkk rrrÅÅÅèèèÛÛÛ¿¿¿|||XXXÞÞÞðððÉÉÉâââKKK&&&QQQPPP%%%bbbcccÿÿÿV\"l\0\0\0ØIDATxÚb \0@£A\0\0D£påΡ\0D£p஡\04ÃA±I#<^inT)&1^v99YYv^.f°@\0a /¿¬1 INSERT INTO `files` (`id`, `uuid`, `name`, `description`, `file`, `type`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`, `roleid`, `custom1`, `custom2`, `custom3`, `custom4`, `custom5`, `custom6`, `custom7`, `custom8`) VALUES ('1', '', 'logo.png', 'Company Logo Used in PDF reports', 'PNG\r\n\Z\n\0\0\0\rIHDR\0\0\0\0\0]\0\0\0S°\0\0\0gAMA\0\0¯È7é\0\0\0tEXtSoftware\0Adobe ImageReadyqÉe<\0\0\0`PLTE666ÑÑѶ¶¶óó󪪪kkk rrrÅÅÅèèèÛÛÛ¿¿¿|||XXXÞÞÞðððÉÉÉâââKKK&&&QQQPPP%%%bbbcccÿÿÿV\"l\0\0\0ØIDATxÚb \0@£A\0\0D£påΡ\0D£p஡\04ÃA±I#<^inT)&1^v99YYv^.f°@\0a /¿¬ 2 2 X#%á I~8°\0] +t*#ËÏ&¬WVVN®ÝV~šŽ¬B 3 3 \"\n0àgj Žp\0« … … 122 122 Ü\0Â(Uº 123 123 HB=óÄ u¶±*\0\ZYóÜšå0\0 Ñy 124 \0 Ñp\0\0\Z\r\00\0tP|O;ë\0\0\0\0IEND®B`', 'image/png',2,NOW(),2,NOW(),90);124 \0 Ñp\0\0\Z\r\00\0tP|O;ë\0\0\0\0IEND®B`', 'image/png', 1, NOW(), 1, NOW(), '90', NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL); -
trunk/phpbms/install/notes.sql
r485 r542 1 INSERT INTO `notes` (` assignedtoid`, `attachedid`, `attachedtabledefid`, `content`, `assignedtodate`, `subject`, `type`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`, `importance`, `parentid`, `startdate`, `enddate`, `completed`, `private`, `status`, `completeddate`, `location`, `category`, `assignedtotime`, `starttime`, `endtime`, `assignedbyid`, `repeating`, `repeattype`, `repeatuntil`, `repeatevery`, `repeattimes`, `repeateachlist`, `repeatontheday`, `repeatontheweek`, `firstrepeat`, `lastrepeat`, `timesrepeated`, `repeatname`) VALUES (NULL,NULL,NULL,'For more help using this software use the following links:\r\n\r\nhttp://www.phpbms.org - community site and wiki.\r\n\r\nhttp://www.phpbms.org/forum -user support forum.\r\n\r\nhttp://www.kreotek.com - paid support and customization.',NULL,'Welcome to phpBMS','SM',1,NOW(),1,NOW(),0,NULL,NULL,NULL,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,0,'Daily',NULL,1,NULL,NULL,NULL,NULL,NULL,NULL,0,NULL);2 INSERT INTO `notes` (` assignedtoid`, `attachedid`, `attachedtabledefid`, `content`, `assignedtodate`, `subject`, `type`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`, `importance`, `parentid`, `startdate`, `enddate`, `completed`, `private`, `status`, `completeddate`, `location`, `category`, `assignedtotime`, `starttime`, `endtime`, `assignedbyid`, `repeating`, `repeattype`, `repeatuntil`, `repeatevery`, `repeattimes`, `repeateachlist`, `repeatontheday`, `repeatontheweek`, `firstrepeat`, `lastrepeat`, `timesrepeated`, `repeatname`) VALUES (NULL, NULL, NULL, '1) From the menu, navigate to Tools->Notes.\r\n2) From the find drop down, choose \'System Messages\' and then click the search button.\r\n3) Select the record(s) you want to delete and then click the delete (-) button.', NULL, 'How To Delete System Messages', 'SM', 1, NOW(), 1, NOW(), '0', NULL, NULL, NULL, '0', '0', NULL, NULL, NULL, NULL, NULL, NULL, NULL, '0', '0', 'Daily', NULL, '1', NULL, NULL, NULL, NULL, NULL, NULL, '0', NULL);1 INSERT INTO `notes` (`uuid`, `assignedtoid`, `attachedid`, `attachedtabledefid`, `content`, `assignedtodate`, `subject`, `type`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`, `importance`, `parentid`, `startdate`, `enddate`, `completed`, `private`, `status`, `completeddate`, `location`, `category`, `assignedtotime`, `starttime`, `endtime`, `assignedbyid`, `repeating`, `repeattype`, `repeatuntil`, `repeatevery`, `repeattimes`, `repeateachlist`, `repeatontheday`, `repeatontheweek`, `firstrepeat`, `lastrepeat`, `timesrepeated`, `repeatname`) VALUES ('note:c624f82a-6ff1-be91-2518-e5e3308f3afc', NULL,NULL,NULL,'For more help using this software use the following links:\r\n\r\nhttp://www.phpbms.org - community site and wiki.\r\n\r\nhttp://www.phpbms.org/forum -user support forum.\r\n\r\nhttp://www.kreotek.com - paid support and customization.',NULL,'Welcome to phpBMS','SM',1,NOW(),1,NOW(),0,NULL,NULL,NULL,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,0,'Daily',NULL,1,NULL,NULL,NULL,NULL,NULL,NULL,0,NULL); 2 INSERT INTO `notes` (`uuid`, `assignedtoid`, `attachedid`, `attachedtabledefid`, `content`, `assignedtodate`, `subject`, `type`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`, `importance`, `parentid`, `startdate`, `enddate`, `completed`, `private`, `status`, `completeddate`, `location`, `category`, `assignedtotime`, `starttime`, `endtime`, `assignedbyid`, `repeating`, `repeattype`, `repeatuntil`, `repeatevery`, `repeattimes`, `repeateachlist`, `repeatontheday`, `repeatontheweek`, `firstrepeat`, `lastrepeat`, `timesrepeated`, `repeatname`) VALUES ('note:9a52d13f-c1fc-ab91-5162-521c13ddbde6', NULL, NULL, NULL, '1) From the menu, navigate to Tools->Notes.\r\n2) From the find drop down, choose \'System Messages\' and then click the search button.\r\n3) Select the record(s) you want to delete and then click the delete (-) button.', NULL, 'How To Delete System Messages', 'SM', 1, NOW(), 1, NOW(), '0', NULL, NULL, NULL, '0', '0', NULL, NULL, NULL, NULL, NULL, NULL, NULL, '0', '0', 'Daily', NULL, '1', NULL, NULL, NULL, NULL, NULL, NULL, '0', NULL); -
trunk/phpbms/install/scheduler.sql
r485 r542 1 INSERT INTO `scheduler` (` name`, `job`, `crontab`, `lastrun`, `startdatetime`, `enddatetime`, `description`, `inactive`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('Clean Import Files', './scheduler_delete_tempimport.php', '30::*::*::*::*', NULL, NOW(), NULL, 'This will delete any temporary import files that are present (for whatever reason) after 30 minutes of their creation.', '0', 1, NOW(), 1, NOW());2 INSERT INTO `scheduler` (` id`, `name`, `job`, `crontab`, `lastrun`, `startdatetime`, `enddatetime`, `description`, `inactive`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('4', 'Remove Excess System Log Records', './scheduler_delete_logs.php', '*::24::*::*::*', NULL, '2009-03-31 12:00:00', NULL, 'This script will trim the system log when there are more than 2000 records present at the time of its calling (default will be every 24 hours).', '0', 1, NOW(), 1, NOW());1 INSERT INTO `scheduler` (`uuid`, `name`, `job`, `crontab`, `lastrun`, `startdatetime`, `enddatetime`, `description`, `inactive`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('schd:fb52e7fb-bb49-7f5f-89e1-002b2785f085', 'Clean Import Files', './scheduler_delete_tempimport.php', '30::*::*::*::*', '2009-05-28 12:30:02', '2009-05-07 17:27:13', NULL, 'This will delete any temporary import files that are present (for whatever reason) after 30 minutes of their creation.', '0', 1, NOW(), 1, NOW()); 2 INSERT INTO `scheduler` (`uuid`, `name`, `job`, `crontab`, `lastrun`, `startdatetime`, `enddatetime`, `description`, `inactive`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('schd:d1c247de-9811-d37f-ad94-a8472dc1bc9c', 'Remove Excess System Log Records', './scheduler_delete_logs.php', '*::24::*::*::*', NULL, '2009-03-31 12:00:00', NULL, 'This script will trim the system log when there are more than 2000 records present at the time of its calling (default will be every 24 hours).', '0', 1, NOW(), 1, NOW()); -
trunk/phpbms/install/smartsearches.sql
r384 r542 1 INSERT INTO `smartsearches` (` id`, `name`, `fromclause`, `valuefield`, `displayfield`, `secondaryfield`, `classfield`, `searchfields`, `filterclause`, `rolefield`, `tabledefid`, `moduleid`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('2', 'Pick Active User', 'users', 'users.id', 'CONCAT(users.firstname,\' \',users.lastname)', 'users.email', '\'\'', 'users.firstname, users.lastname', 'users.revoked=0 AND users.portalaccess = 0', NULL, '9', '1', 1, NOW(), 1, NOW());2 INSERT INTO `smartsearches` (` id`, `name`, `fromclause`, `valuefield`, `displayfield`, `secondaryfield`, `classfield`, `searchfields`, `filterclause`, `rolefield`, `tabledefid`, `moduleid`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('5', 'Pick File', 'files', 'files.id', 'files.name', 'files.description', '\'\'', 'files.name, files.description', 'files.id!=0', 'files.roleid', '26', '1', 1, NOW(), 1, NOW());3 INSERT INTO `smartsearches` (` id`, `name`, `fromclause`, `valuefield`, `displayfield`, `secondaryfield`, `classfield`, `searchfields`, `filterclause`, `rolefield`, `tabledefid`, `moduleid`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('9', 'Pick Active User Email', 'users', 'users.id', 'concat(users.firstname,\' \',users.lastname,\' [\',users.email,\']\')', 'users.phone', '\'\'', 'users.firstname, users.lastname, users.email', 'users.revoked = 0 AND users.portalaccess = 0', NULL, '9', '1', 1, NOW(), 1, NOW());1 INSERT INTO `smartsearches` (`uuid`, `name`, `fromclause`, `valuefield`, `displayfield`, `secondaryfield`, `classfield`, `searchfields`, `filterclause`, `rolefield`, `tabledefid`, `moduleid`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('smrt:ccc73fa4-6176-fad4-fbb1-5186d0edbdd1', 'Pick Active User', 'users', 'users.id', 'CONCAT(users.firstname,\' \',users.lastname)', 'users.email', '\'\'', 'users.firstname, users.lastname', 'users.revoked=0 AND users.portalaccess = 0', NULL, '9', '1', 1, NOW(), 1, NOW()); 2 INSERT INTO `smartsearches` (`uuid`, `name`, `fromclause`, `valuefield`, `displayfield`, `secondaryfield`, `classfield`, `searchfields`, `filterclause`, `rolefield`, `tabledefid`, `moduleid`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('smrt:855406d5-659d-c907-74a1-acfd3802fd73', 'Pick File', 'files', 'files.id', 'files.name', 'files.description', '\'\'', 'files.name, files.description', 'files.id!=0', 'files.roleid', '26', '1', 1, NOW(), 1, NOW()); 3 INSERT INTO `smartsearches` (`uuid`, `name`, `fromclause`, `valuefield`, `displayfield`, `secondaryfield`, `classfield`, `searchfields`, `filterclause`, `rolefield`, `tabledefid`, `moduleid`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('smrt:ed5b1d7f-b0fe-2088-f17c-47bfbe1ace25', 'Pick Active User Email', 'users', 'users.id', 'concat(users.firstname,\' \',users.lastname,\' [\',users.email,\']\')', 'users.phone', '\'\'', 'users.firstname, users.lastname, users.email', 'users.revoked = 0 AND users.portalaccess = 0', NULL, '9', '1', 1, NOW(), 1, NOW()); -
trunk/phpbms/install/tabledefs.sql
r517 r542 1 INSERT INTO `tabledefs` (`id`, ` displayname`, `type`, `moduleid`, `maintable`, `querytable`, `editfile`, `editroleid`, `addfile`, `addroleid`, `importfile`, `importroleid`, `searchroleid`, `advsearchroleid`, `viewsqlroleid`, `deletebutton`, `canpost`, `hascustomfields`, `defaultwhereclause`, `defaultsortorder`, `defaultsearchtype`, `defaultcriteriafindoptions`, `defaultcriteriaselection`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('9', 'Users', 'system', '1', 'users', 'users', 'modules/base/users_addedit.php', '0', 'modules/base/users_addedit.php', '0', 'modules/base/users_import.php', '-100', '0', '-100', '-100', 'revoke', '0', '0', 'users.id !=0', 'users.id', NULL, NULL, NULL, 1, NOW(), 1, NOW());2 INSERT INTO `tabledefs` (`id`, ` displayname`, `type`, `moduleid`, `maintable`, `querytable`, `editfile`, `editroleid`, `addfile`, `addroleid`, `importfile`, `importroleid`, `searchroleid`, `advsearchroleid`, `viewsqlroleid`, `deletebutton`, `canpost`, `hascustomfields`, `defaultwhereclause`, `defaultsortorder`, `defaultsearchtype`, `defaultcriteriafindoptions`, `defaultcriteriaselection`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('10', 'Relationships', 'system', '1', 'relationships', '(relationships inner join tabledefs as fromtable on relationships.fromtableid=fromtable.id) inner join tabledefs as totable on relationships.totableid=totable.id', 'modules/base/relationships_addedit.php', '0', 'modules/base/relationships_addedit.php', '0', NULL, '-100', '0', '-100', '-100', 'delete', '0', '0', 'relationships.id != 0', 'fromtable.displayname, name', '', '', '', 1, NOW(), 1, NOW());3 INSERT INTO `tabledefs` (`id`, ` displayname`, `type`, `moduleid`, `maintable`, `querytable`, `editfile`, `editroleid`, `addfile`, `addroleid`, `importfile`, `importroleid`, `searchroleid`, `advsearchroleid`, `viewsqlroleid`, `deletebutton`, `canpost`, `hascustomfields`, `defaultwhereclause`, `defaultsortorder`, `defaultsearchtype`, `defaultcriteriafindoptions`, `defaultcriteriaselection`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('11', 'Table Definitions', 'system', '1', 'tabledefs', 'tabledefs left join modules on tabledefs.moduleid=modules.id', 'modules/base/tabledefs_addedit.php', '-100', 'modules/base/tabledefs_addedit.php', '-100', NULL, '-100', '-100', '-100', '-100', 'delete', '0', '0', 'tabledefs.id != 0', 'modules.name, tabledefs.displayname', '', '', '', 1, NOW(), 1, NOW());4 INSERT INTO `tabledefs` (`id`, ` displayname`, `type`, `moduleid`, `maintable`, `querytable`, `editfile`, `editroleid`, `addfile`, `addroleid`, `importfile`, `importroleid`, `searchroleid`, `advsearchroleid`, `viewsqlroleid`, `deletebutton`, `canpost`, `hascustomfields`, `defaultwhereclause`, `defaultsortorder`, `defaultsearchtype`, `defaultcriteriafindoptions`, `defaultcriteriaselection`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('12', 'Notes', 'table', '1', 'notes', 'notes', 'modules/base/notes_addedit.php', '0', 'modules/base/notes_addedit.php', '0', NULL, '-100', '0', '-100', '-100', 'delete', '0', '1', 'notes.type=\'NT\' AND notes.createdby = {{$_SESSION[\'userinfo\'][\'id\']}} AND completed=0', 'notes.category,notes.type,notes.importance DESC,notes.creationdate', 'search', 'My Unread Notes', 'new', 1, NOW(), 1, NOW());5 INSERT INTO `tabledefs` (`id`, ` displayname`, `type`, `moduleid`, `maintable`, `querytable`, `editfile`, `editroleid`, `addfile`, `addroleid`, `importfile`, `importroleid`, `searchroleid`, `advsearchroleid`, `viewsqlroleid`, `deletebutton`, `canpost`, `hascustomfields`, `defaultwhereclause`, `defaultsortorder`, `defaultsearchtype`, `defaultcriteriafindoptions`, `defaultcriteriaselection`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('16', 'Reports', 'system', '1', 'reports', 'reports left join tabledefs on reports.tabledefid=tabledefs.id', 'modules/base/reports_addedit.php', '0', 'modules/base/reports_addedit.php', '0', NULL, '-100', '0', '-100', '-100', 'delete', '0', '0', 'reports.id != 0', 'tabledefid,displayorder DESC, reports.name', '', '', '', 1, NOW(), 1, NOW());6 INSERT INTO `tabledefs` (`id`, ` displayname`, `type`, `moduleid`, `maintable`, `querytable`, `editfile`, `editroleid`, `addfile`, `addroleid`, `importfile`, `importroleid`, `searchroleid`, `advsearchroleid`, `viewsqlroleid`, `deletebutton`, `canpost`, `hascustomfields`, `defaultwhereclause`, `defaultsortorder`, `defaultsearchtype`, `defaultcriteriafindoptions`, `defaultcriteriaselection`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('17', 'Saved Searches/Sorts', 'system', '1', 'usersearches', '(usersearches left join users on usersearches.userid = users.id) inner join tabledefs on usersearches.tabledefid=tabledefs.id', 'modules/base/usersearches_edit.php', '0', 'N/A', '0', NULL, '-100', '0', '-100', '-100', 'delete', '0', '0', 'usersearches.id != 0', 'usersearches.name', '', '', '', 1, NOW(), 1, NOW());7 INSERT INTO `tabledefs` (`id`, ` displayname`, `type`, `moduleid`, `maintable`, `querytable`, `editfile`, `editroleid`, `addfile`, `addroleid`, `importfile`, `importroleid`, `searchroleid`, `advsearchroleid`, `viewsqlroleid`, `deletebutton`, `canpost`, `hascustomfields`, `defaultwhereclause`, `defaultsortorder`, `defaultsearchtype`, `defaultcriteriafindoptions`, `defaultcriteriaselection`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('19', 'Menu', 'system', '1', 'menu', '((menu LEFT JOIN menu as parentmenu on menu.parentid=parentmenu.id) LEFT JOIN roles on menu.roleid=roles.id)', 'modules/base/menu_addedit.php', '-100', 'modules/base/menu_addedit.php', '-100', NULL, '-100', '-100', '-100', '-100', 'delete', '0', '0', 'menu.id!=0', 'if(parentmenu.name is null,menu.displayorder,parentmenu.displayorder+(menu.displayorder+1)/10000)', '', '', '', 1, NOW(), 1, NOW());8 INSERT INTO `tabledefs` (`id`, ` displayname`, `type`, `moduleid`, `maintable`, `querytable`, `editfile`, `editroleid`, `addfile`, `addroleid`, `importfile`, `importroleid`, `searchroleid`, `advsearchroleid`, `viewsqlroleid`, `deletebutton`, `canpost`, `hascustomfields`, `defaultwhereclause`, `defaultsortorder`, `defaultsearchtype`, `defaultcriteriafindoptions`, `defaultcriteriaselection`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('21', 'Installed Modules', 'system', '1', 'modules', 'modules', 'modules/base/modules_view.php', '0', 'modules/base/modules_view.php', '0', NULL, '-100', '0', '-100', '-100', 'NA', '0', '0', 'modules.id!=0', 'modules.name', '', '', '', 1, NOW(), 1, NOW());9 INSERT INTO `tabledefs` (`id`, ` displayname`, `type`, `moduleid`, `maintable`, `querytable`, `editfile`, `editroleid`, `addfile`, `addroleid`, `importfile`, `importroleid`, `searchroleid`, `advsearchroleid`, `viewsqlroleid`, `deletebutton`, `canpost`, `hascustomfields`, `defaultwhereclause`, `defaultsortorder`, `defaultsearchtype`, `defaultcriteriafindoptions`, `defaultcriteriaselection`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('23', 'Tasks', 'view', '1', 'notes', '((notes left join users as assignedto on assignedto.id= notes.assignedtoid) left join users as assignedby on assignedby.id=notes.assignedbyid)', 'modules/base/notes_addedit.php?backurl=../../search.php?id=23', '0', 'modules/base/notes_addedit.php?ty=TS&backurl=../../search.php?id=23', '0', NULL, '-100', '0', '-100', '-100', 'delete', '0', '0', 'notes.id = -1', 'notes.importance, IF(assignedtodate IS NOT NULL, assignedtodate, IF((enddate IS NOT NULL && type = \'TS\'), enddate, IF((startdate IS NOT NULL && type = \'EV\'), startdate, CURDATE()))), subject', 'search', 'My Uncompleted Tasks', NULL, 1, NOW(), 1, NOW());10 INSERT INTO `tabledefs` (`id`, ` displayname`, `type`, `moduleid`, `maintable`, `querytable`, `editfile`, `editroleid`, `addfile`, `addroleid`, `importfile`, `importroleid`, `searchroleid`, `advsearchroleid`, `viewsqlroleid`, `deletebutton`, `canpost`, `hascustomfields`, `defaultwhereclause`, `defaultsortorder`, `defaultsearchtype`, `defaultcriteriafindoptions`, `defaultcriteriaselection`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('24', 'Events', 'view', '1', 'notes', '((notes left join users as assignedto on assignedto.id= notes.assignedtoid) left join users as assignedby on assignedby.id=notes.assignedbyid)', 'modules/base/notes_addedit.php?backurl=../../search.php?id=24', '0', 'modules/base/notes_addedit.php?ty=EV&backurl=../../search.php?id=24', '0', NULL, '-100', '0', '-100', '-100', 'delete', '0', '0', 'notes.type=\'EV\' AND notes.createdby = {{$_SESSION[\'userinfo\'][\'id\']}} AND ((notes.startdate = year(notes.startdate)=year(curdate()) and week(notes.startdate)=week(curdate())))', 'notes.startdate DESC,notes.starttime DESC,notes.enddate DESC,notes.endtime DESC,notes.importance', 'search', NULL, NULL, 1, NOW(), 1, NOW());11 INSERT INTO `tabledefs` (`id`, ` displayname`, `type`, `moduleid`, `maintable`, `querytable`, `editfile`, `editroleid`, `addfile`, `addroleid`, `importfile`, `importroleid`, `searchroleid`, `advsearchroleid`, `viewsqlroleid`, `deletebutton`, `canpost`, `hascustomfields`, `defaultwhereclause`, `defaultsortorder`, `defaultsearchtype`, `defaultcriteriafindoptions`, `defaultcriteriaselection`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('26', 'Files', 'table', '1', 'files', 'files', 'modules/base/files_addedit.php', '0', 'modules/base/files_addedit.php', '0', NULL, '-100', '-100', '-100', '-100', 'delete', '0', '0', 'files.id=-1', 'files.name', 'search', '', '', 1, NOW(), 1, NOW());12 INSERT INTO `tabledefs` (`id`, ` displayname`, `type`, `moduleid`, `maintable`, `querytable`, `editfile`, `editroleid`, `addfile`, `addroleid`, `importfile`, `importroleid`, `searchroleid`, `advsearchroleid`, `viewsqlroleid`, `deletebutton`, `canpost`, `hascustomfields`, `defaultwhereclause`, `defaultsortorder`, `defaultsearchtype`, `defaultcriteriafindoptions`, `defaultcriteriaselection`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('27', 'Attachments', 'table', '1', 'attachments', '(attachments INNER JOIN files on attachments.fileid=files.id)', 'modules/base/files_addedit.php', '0', 'modules/base/files_addedit.php', '0', NULL, '-100', '0', '-100', '-100', 'delete', '0', '0', 'attachments.id!=0', 'attachments.creationdate DESC', 'search', '', '', 1, NOW(), 1, NOW());13 INSERT INTO `tabledefs` (`id`, ` displayname`, `type`, `moduleid`, `maintable`, `querytable`, `editfile`, `editroleid`, `addfile`, `addroleid`, `importfile`, `importroleid`, `searchroleid`, `advsearchroleid`, `viewsqlroleid`, `deletebutton`, `canpost`, `hascustomfields`, `defaultwhereclause`, `defaultsortorder`, `defaultsearchtype`, `defaultcriteriafindoptions`, `defaultcriteriaselection`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('200', 'Roles', 'table', '1', 'roles', 'roles', 'modules/base/roles_addedit.php', '-100', 'modules/base/roles_addedit.php', '-100', NULL, '-100', '-100', '-100', '-100', 'inactivate', '0', '0', 'roles.id!=-1', 'name', 'search', '', '', 1, NOW(), 1, NOW());14 INSERT INTO `tabledefs` (`id`, ` displayname`, `type`, `moduleid`, `maintable`, `querytable`, `editfile`, `editroleid`, `addfile`, `addroleid`, `importfile`, `importroleid`, `searchroleid`, `advsearchroleid`, `viewsqlroleid`, `deletebutton`, `canpost`, `hascustomfields`, `defaultwhereclause`, `defaultsortorder`, `defaultsearchtype`, `defaultcriteriafindoptions`, `defaultcriteriaselection`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('201', 'Scheduler', 'system', '1', 'scheduler', 'scheduler', 'modules/base/scheduler_addedit.php', '-100', 'modules/base/scheduler_addedit.php', '-100', NULL, '-100', '-100', '-100', '-100', 'delete', '0', '0', 'scheduler.id!=0', 'scheduler.name', '', '', '', 1, NOW(), 1, NOW());15 INSERT INTO `tabledefs` (`id`, ` displayname`, `type`, `moduleid`, `maintable`, `querytable`, `editfile`, `editroleid`, `addfile`, `addroleid`, `importfile`, `importroleid`, `searchroleid`, `advsearchroleid`, `viewsqlroleid`, `deletebutton`, `canpost`, `hascustomfields`, `defaultwhereclause`, `defaultsortorder`, `defaultsearchtype`, `defaultcriteriafindoptions`, `defaultcriteriaselection`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('202', 'System Log', 'system', '1', 'log', 'log LEFT JOIN users ON log.userid=users.id', 'N/A', '-100', 'N/A', '-100', NULL, '-100', '-100', '-100', '-100', 'delete', '0', '0', 'log.stamp> DATE_SUB(CURDATE(),INTERVAL 1 DAY)', 'log.stamp', '', '', '', 1, NOW(), 1, NOW());16 INSERT INTO `tabledefs` (`id`, ` displayname`, `type`, `moduleid`, `maintable`, `querytable`, `editfile`, `editroleid`, `addfile`, `addroleid`, `importfile`, `importroleid`, `searchroleid`, `advsearchroleid`, `viewsqlroleid`, `deletebutton`, `canpost`, `hascustomfields`, `defaultwhereclause`, `defaultsortorder`, `defaultsearchtype`, `defaultcriteriafindoptions`, `defaultcriteriaselection`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('203', 'Tabs', 'system', '1', 'tabs', 'tabs LEFT JOIN roles ON tabs.roleid=roles.id', 'modules/base/tabs_addedit.php', '-100', 'modules/base/tabs_addedit.php', '-100', NULL, '-100', '-100', '-100', '-100', 'delete', '0', '0', 'tabs.id!=0', 'tabs.tabgroup,tabs.displayorder', '', '', '', 1, NOW(), 1, NOW());17 INSERT INTO `tabledefs` (`id`, ` displayname`, `type`, `moduleid`, `maintable`, `querytable`, `editfile`, `editroleid`, `addfile`, `addroleid`, `importfile`, `importroleid`, `searchroleid`, `advsearchroleid`, `viewsqlroleid`, `deletebutton`, `canpost`, `hascustomfields`, `defaultwhereclause`, `defaultsortorder`, `defaultsearchtype`, `defaultcriteriafindoptions`, `defaultcriteriaselection`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('204', 'Smart Searches', 'table', '1', 'smartsearches', '(smartsearches INNER JOIN tabledefs ON smartsearches.tabledefid = tabledefs.id) INNER JOIN modules on smartsearches.moduleid = modules.id', 'modules/base/smartsearches_addedit.php', '-100', 'modules/base/smartsearches_addedit.php', '-100', NULL, '-100', '-100', '-100', '-100', 'delete', '0', '0', 'smartsearches.id != -1', 'smartsearches.name', NULL, NULL, NULL, 1, NOW(), 1, NOW());18 INSERT INTO `tabledefs` (`id`, ` displayname`, `type`, `moduleid`, `maintable`, `querytable`, `editfile`, `editroleid`, `addfile`, `addroleid`, `importfile`, `importroleid`, `searchroleid`, `advsearchroleid`, `viewsqlroleid`, `deletebutton`, `canpost`, `hascustomfields`, `defaultwhereclause`, `defaultsortorder`, `defaultsearchtype`, `defaultcriteriafindoptions`, `defaultcriteriaselection`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('205', 'Snapshot Widgets', 'system', '1', 'widgets', '((widgets INNER JOIN modules ON widgets.moduleid = modules.id) LEFT JOIN roles ON widgets.roleid = roles.id) ', 'modules/base/widgets_addedit.php', '-100', 'modules/base/widgets_addedit.php', '-100', NULL, '-100', '-100', '-100', '-100', 'delete', '0', '0', 'widgets.id != -1', 'widgets.title', NULL, NULL, NULL, 1, NOW(), 1, NOW());1 INSERT INTO `tabledefs` (`id`, `uuid`, `displayname`, `type`, `moduleid`, `maintable`, `querytable`, `editfile`, `editroleid`, `addfile`, `addroleid`, `importfile`, `importroleid`, `searchroleid`, `advsearchroleid`, `viewsqlroleid`, `deletebutton`, `canpost`, `hascustomfields`, `defaultwhereclause`, `defaultsortorder`, `defaultsearchtype`, `defaultcriteriafindoptions`, `defaultcriteriaselection`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('9', 'tbld:afe6d297-b484-4f0b-57d4-1c39412e9dfb', 'Users', 'system', '1', 'users', 'users', 'modules/base/users_addedit.php', '0', 'modules/base/users_addedit.php', '0', 'modules/base/users_import.php', '-100', '0', '-100', '-100', 'revoke', '0', '0', 'users.id !=0', 'users.id', NULL, NULL, NULL, 1, NOW(), 1, NOW()); 2 INSERT INTO `tabledefs` (`id`, `uuid`, `displayname`, `type`, `moduleid`, `maintable`, `querytable`, `editfile`, `editroleid`, `addfile`, `addroleid`, `importfile`, `importroleid`, `searchroleid`, `advsearchroleid`, `viewsqlroleid`, `deletebutton`, `canpost`, `hascustomfields`, `defaultwhereclause`, `defaultsortorder`, `defaultsearchtype`, `defaultcriteriafindoptions`, `defaultcriteriaselection`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('10', 'tbld:8d19c73c-42fb-d829-3681-d20b4dbe43b9', 'Relationships', 'system', '1', 'relationships', '(relationships inner join tabledefs as fromtable on relationships.fromtableid=fromtable.id) inner join tabledefs as totable on relationships.totableid=totable.id', 'modules/base/relationships_addedit.php', '0', 'modules/base/relationships_addedit.php', '0', NULL, '-100', '0', '-100', '-100', 'delete', '0', '0', 'relationships.id != 0', 'fromtable.displayname, name', '', '', '', 1, NOW(), 1, NOW()); 3 INSERT INTO `tabledefs` (`id`, `uuid`, `displayname`, `type`, `moduleid`, `maintable`, `querytable`, `editfile`, `editroleid`, `addfile`, `addroleid`, `importfile`, `importroleid`, `searchroleid`, `advsearchroleid`, `viewsqlroleid`, `deletebutton`, `canpost`, `hascustomfields`, `defaultwhereclause`, `defaultsortorder`, `defaultsearchtype`, `defaultcriteriafindoptions`, `defaultcriteriaselection`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('11', 'tbld:5c9d645f-26ab-5003-b98e-89e9049f8ac3', 'Table Definitions', 'system', '1', 'tabledefs', 'tabledefs left join modules on tabledefs.moduleid=modules.id', 'modules/base/tabledefs_addedit.php', '-100', 'modules/base/tabledefs_addedit.php', '-100', NULL, '-100', '-100', '-100', '-100', 'delete', '0', '0', 'tabledefs.id != 0', 'modules.name, tabledefs.displayname', '', '', '', 1, NOW(), 1, NOW()); 4 INSERT INTO `tabledefs` (`id`, `uuid`, `displayname`, `type`, `moduleid`, `maintable`, `querytable`, `editfile`, `editroleid`, `addfile`, `addroleid`, `importfile`, `importroleid`, `searchroleid`, `advsearchroleid`, `viewsqlroleid`, `deletebutton`, `canpost`, `hascustomfields`, `defaultwhereclause`, `defaultsortorder`, `defaultsearchtype`, `defaultcriteriafindoptions`, `defaultcriteriaselection`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('12', 'tbld:a4cdd991-cf0a-916f-1240-49428ea1bdd1', 'Notes', 'table', '1', 'notes', 'notes', 'modules/base/notes_addedit.php', '0', 'modules/base/notes_addedit.php', '0', NULL, '-100', '0', '-100', '-100', 'delete', '0', '1', 'notes.type=\'NT\' AND notes.createdby = {{$_SESSION[\'userinfo\'][\'id\']}} AND completed=0', 'notes.category,notes.type,notes.importance DESC,notes.creationdate', 'search', 'My Unread Notes', 'new', 1, NOW(), 1, NOW()); 5 INSERT INTO `tabledefs` (`id`, `uuid`, `displayname`, `type`, `moduleid`, `maintable`, `querytable`, `editfile`, `editroleid`, `addfile`, `addroleid`, `importfile`, `importroleid`, `searchroleid`, `advsearchroleid`, `viewsqlroleid`, `deletebutton`, `canpost`, `hascustomfields`, `defaultwhereclause`, `defaultsortorder`, `defaultsearchtype`, `defaultcriteriafindoptions`, `defaultcriteriaselection`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('16', 'tbld:d595ef42-db9d-2233-1b9b-11dfd0db9cbb', 'Reports', 'system', '1', 'reports', 'reports left join tabledefs on reports.tabledefid=tabledefs.id', 'modules/base/reports_addedit.php', '0', 'modules/base/reports_addedit.php', '0', NULL, '-100', '0', '-100', '-100', 'delete', '0', '0', 'reports.id != 0', 'tabledefid,displayorder DESC, reports.name', '', '', '', 1, NOW(), 1, NOW()); 6 INSERT INTO `tabledefs` (`id`, `uuid`, `displayname`, `type`, `moduleid`, `maintable`, `querytable`, `editfile`, `editroleid`, `addfile`, `addroleid`, `importfile`, `importroleid`, `searchroleid`, `advsearchroleid`, `viewsqlroleid`, `deletebutton`, `canpost`, `hascustomfields`, `defaultwhereclause`, `defaultsortorder`, `defaultsearchtype`, `defaultcriteriafindoptions`, `defaultcriteriaselection`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('17', 'tbld:e251524a-2da4-a0c9-8725-d3d0412d8f4a', 'Saved Searches/Sorts', 'system', '1', 'usersearches', '(usersearches left join users on usersearches.userid = users.id) inner join tabledefs on usersearches.tabledefid=tabledefs.id', 'modules/base/usersearches_edit.php', '0', 'N/A', '0', NULL, '-100', '0', '-100', '-100', 'delete', '0', '0', 'usersearches.id != 0', 'usersearches.name', '', '', '', 1, NOW(), 1, NOW()); 7 INSERT INTO `tabledefs` (`id`, `uuid`, `displayname`, `type`, `moduleid`, `maintable`, `querytable`, `editfile`, `editroleid`, `addfile`, `addroleid`, `importfile`, `importroleid`, `searchroleid`, `advsearchroleid`, `viewsqlroleid`, `deletebutton`, `canpost`, `hascustomfields`, `defaultwhereclause`, `defaultsortorder`, `defaultsearchtype`, `defaultcriteriafindoptions`, `defaultcriteriaselection`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('19', 'tbld:83187e3d-101e-a8a5-037f-31e9800fed2d', 'Menu', 'system', '1', 'menu', '((menu LEFT JOIN menu as parentmenu on menu.parentid=parentmenu.id) LEFT JOIN roles on menu.roleid=roles.id)', 'modules/base/menu_addedit.php', '-100', 'modules/base/menu_addedit.php', '-100', NULL, '-100', '-100', '-100', '-100', 'delete', '0', '0', 'menu.id!=0', 'if(parentmenu.name is null,menu.displayorder,parentmenu.displayorder+(menu.displayorder+1)/10000)', '', '', '', 1, NOW(), 1, NOW()); 8 INSERT INTO `tabledefs` (`id`, `uuid`, `displayname`, `type`, `moduleid`, `maintable`, `querytable`, `editfile`, `editroleid`, `addfile`, `addroleid`, `importfile`, `importroleid`, `searchroleid`, `advsearchroleid`, `viewsqlroleid`, `deletebutton`, `canpost`, `hascustomfields`, `defaultwhereclause`, `defaultsortorder`, `defaultsearchtype`, `defaultcriteriafindoptions`, `defaultcriteriaselection`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('21', 'tbld:ea159d67-5e89-5b7f-f5a0-c740e147cd73', 'Installed Modules', 'system', '1', 'modules', 'modules', 'modules/base/modules_view.php', '0', 'modules/base/modules_view.php', '0', NULL, '-100', '0', '-100', '-100', 'NA', '0', '0', 'modules.id!=0', 'modules.name', '', '', '', 1, NOW(), 1, NOW()); 9 INSERT INTO `tabledefs` (`id`, `uuid`, `displayname`, `type`, `moduleid`, `maintable`, `querytable`, `editfile`, `editroleid`, `addfile`, `addroleid`, `importfile`, `importroleid`, `searchroleid`, `advsearchroleid`, `viewsqlroleid`, `deletebutton`, `canpost`, `hascustomfields`, `defaultwhereclause`, `defaultsortorder`, `defaultsearchtype`, `defaultcriteriafindoptions`, `defaultcriteriaselection`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('23', 'tbld:2bc3e683-81f9-694a-9550-a0c7263057de', 'Tasks', 'view', '1', 'notes', '((notes left join users as assignedto on assignedto.id= notes.assignedtoid) left join users as assignedby on assignedby.id=notes.assignedbyid)', 'modules/base/notes_addedit.php?backurl=../../search.php?id=23', '0', 'modules/base/notes_addedit.php?ty=TS&backurl=../../search.php?id=23', '0', NULL, '-100', '0', '-100', '-100', 'delete', '0', '0', 'notes.id = -1', 'notes.importance, IF(assignedtodate IS NOT NULL, assignedtodate, IF((enddate IS NOT NULL && type = \'TS\'), enddate, IF((startdate IS NOT NULL && type = \'EV\'), startdate, CURDATE()))), subject', 'search', 'My Uncompleted Tasks', NULL, 1, NOW(), 1, NOW()); 10 INSERT INTO `tabledefs` (`id`, `uuid`, `displayname`, `type`, `moduleid`, `maintable`, `querytable`, `editfile`, `editroleid`, `addfile`, `addroleid`, `importfile`, `importroleid`, `searchroleid`, `advsearchroleid`, `viewsqlroleid`, `deletebutton`, `canpost`, `hascustomfields`, `defaultwhereclause`, `defaultsortorder`, `defaultsearchtype`, `defaultcriteriafindoptions`, `defaultcriteriaselection`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('24', 'tbld:0fcca651-6c34-c74d-ac04-2d88f602dd71', 'Events', 'view', '1', 'notes', '((notes left join users as assignedto on assignedto.id= notes.assignedtoid) left join users as assignedby on assignedby.id=notes.assignedbyid)', 'modules/base/notes_addedit.php?backurl=../../search.php?id=24', '0', 'modules/base/notes_addedit.php?ty=EV&backurl=../../search.php?id=24', '0', NULL, '-100', '0', '-100', '-100', 'delete', '0', '0', 'notes.type=\'EV\' AND notes.createdby = {{$_SESSION[\'userinfo\'][\'id\']}} AND ((notes.startdate = year(notes.startdate)=year(curdate()) and week(notes.startdate)=week(curdate())))', 'notes.startdate DESC,notes.starttime DESC,notes.enddate DESC,notes.endtime DESC,notes.importance', 'search', NULL, NULL, 1, NOW(), 1, NOW()); 11 INSERT INTO `tabledefs` (`id`, `uuid`, `displayname`, `type`, `moduleid`, `maintable`, `querytable`, `editfile`, `editroleid`, `addfile`, `addroleid`, `importfile`, `importroleid`, `searchroleid`, `advsearchroleid`, `viewsqlroleid`, `deletebutton`, `canpost`, `hascustomfields`, `defaultwhereclause`, `defaultsortorder`, `defaultsearchtype`, `defaultcriteriafindoptions`, `defaultcriteriaselection`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('26', 'tbld:80b4f38d-b957-bced-c0a0-ed08a0db6475', 'Files', 'table', '1', 'files', 'files', 'modules/base/files_addedit.php', '0', 'modules/base/files_addedit.php', '0', NULL, '-100', '-100', '-100', '-100', 'delete', '0', '0', 'files.id=-1', 'files.name', 'search', '', '', 1, NOW(), 1, NOW()); 12 INSERT INTO `tabledefs` (`id`, `uuid`, `displayname`, `type`, `moduleid`, `maintable`, `querytable`, `editfile`, `editroleid`, `addfile`, `addroleid`, `importfile`, `importroleid`, `searchroleid`, `advsearchroleid`, `viewsqlroleid`, `deletebutton`, `canpost`, `hascustomfields`, `defaultwhereclause`, `defaultsortorder`, `defaultsearchtype`, `defaultcriteriafindoptions`, `defaultcriteriaselection`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('27', 'tbld:edb8c896-7ce3-cafe-1d58-5aefbcd5f3d7', 'Attachments', 'table', '1', 'attachments', '(attachments INNER JOIN files on attachments.fileid=files.id)', 'modules/base/files_addedit.php', '0', 'modules/base/files_addedit.php', '0', NULL, '-100', '0', '-100', '-100', 'delete', '0', '0', 'attachments.id!=0', 'attachments.creationdate DESC', 'search', '', '', 1, NOW(), 1, NOW()); 13 INSERT INTO `tabledefs` (`id`, `uuid`, `displayname`, `type`, `moduleid`, `maintable`, `querytable`, `editfile`, `editroleid`, `addfile`, `addroleid`, `importfile`, `importroleid`, `searchroleid`, `advsearchroleid`, `viewsqlroleid`, `deletebutton`, `canpost`, `hascustomfields`, `defaultwhereclause`, `defaultsortorder`, `defaultsearchtype`, `defaultcriteriafindoptions`, `defaultcriteriaselection`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('200', 'tbld:87b9fe06-afe5-d9c6-0fa0-4a0f2ec4ee8a', 'Roles', 'table', '1', 'roles', 'roles', 'modules/base/roles_addedit.php', '-100', 'modules/base/roles_addedit.php', '-100', NULL, '-100', '-100', '-100', '-100', 'inactivate', '0', '0', 'roles.id!=-1', 'name', 'search', '', '', 1, NOW(), 1, NOW()); 14 INSERT INTO `tabledefs` (`id`, `uuid`, `displayname`, `type`, `moduleid`, `maintable`, `querytable`, `editfile`, `editroleid`, `addfile`, `addroleid`, `importfile`, `importroleid`, `searchroleid`, `advsearchroleid`, `viewsqlroleid`, `deletebutton`, `canpost`, `hascustomfields`, `defaultwhereclause`, `defaultsortorder`, `defaultsearchtype`, `defaultcriteriafindoptions`, `defaultcriteriaselection`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('201', 'tbld:83de284b-ef79-3567-145c-30ca38b40796', 'Scheduler', 'system', '1', 'scheduler', 'scheduler', 'modules/base/scheduler_addedit.php', '-100', 'modules/base/scheduler_addedit.php', '-100', NULL, '-100', '-100', '-100', '-100', 'delete', '0', '0', 'scheduler.id!=0', 'scheduler.name', '', '', '', 1, NOW(), 1, NOW()); 15 INSERT INTO `tabledefs` (`id`, `uuid`, `displayname`, `type`, `moduleid`, `maintable`, `querytable`, `editfile`, `editroleid`, `addfile`, `addroleid`, `importfile`, `importroleid`, `searchroleid`, `advsearchroleid`, `viewsqlroleid`, `deletebutton`, `canpost`, `hascustomfields`, `defaultwhereclause`, `defaultsortorder`, `defaultsearchtype`, `defaultcriteriafindoptions`, `defaultcriteriaselection`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('202', 'tbld:3f71ab66-1f84-d68b-e2a3-3ee3bb0ec667', 'System Log', 'system', '1', 'log', 'log LEFT JOIN users ON log.userid=users.id', 'N/A', '-100', 'N/A', '-100', NULL, '-100', '-100', '-100', '-100', 'delete', '0', '0', 'log.stamp> DATE_SUB(CURDATE(),INTERVAL 1 DAY)', 'log.stamp', '', '', '', 1, NOW(), 1, NOW()); 16 INSERT INTO `tabledefs` (`id`, `uuid`, `displayname`, `type`, `moduleid`, `maintable`, `querytable`, `editfile`, `editroleid`, `addfile`, `addroleid`, `importfile`, `importroleid`, `searchroleid`, `advsearchroleid`, `viewsqlroleid`, `deletebutton`, `canpost`, `hascustomfields`, `defaultwhereclause`, `defaultsortorder`, `defaultsearchtype`, `defaultcriteriafindoptions`, `defaultcriteriaselection`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('203', 'tbld:7e75af48-6f70-d157-f440-69a8e7f59d38', 'Tabs', 'system', '1', 'tabs', 'tabs LEFT JOIN roles ON tabs.roleid=roles.id', 'modules/base/tabs_addedit.php', '-100', 'modules/base/tabs_addedit.php', '-100', NULL, '-100', '-100', '-100', '-100', 'delete', '0', '0', 'tabs.id!=0', 'tabs.tabgroup,tabs.displayorder', '', '', '', 1, NOW(), 1, NOW()); 17 INSERT INTO `tabledefs` (`id`, `uuid`, `displayname`, `type`, `moduleid`, `maintable`, `querytable`, `editfile`, `editroleid`, `addfile`, `addroleid`, `importfile`, `importroleid`, `searchroleid`, `advsearchroleid`, `viewsqlroleid`, `deletebutton`, `canpost`, `hascustomfields`, `defaultwhereclause`, `defaultsortorder`, `defaultsearchtype`, `defaultcriteriafindoptions`, `defaultcriteriaselection`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('204', 'tbld:29925e0a-c825-0067-8882-db4b57866a96', 'Smart Searches', 'table', '1', 'smartsearches', '(smartsearches INNER JOIN tabledefs ON smartsearches.tabledefid = tabledefs.id) INNER JOIN modules on smartsearches.moduleid = modules.id', 'modules/base/smartsearches_addedit.php', '-100', 'modules/base/smartsearches_addedit.php', '-100', NULL, '-100', '-100', '-100', '-100', 'delete', '0', '0', 'smartsearches.id != -1', 'smartsearches.name', NULL, NULL, NULL, 1, NOW(), 1, NOW()); 18 INSERT INTO `tabledefs` (`id`, `uuid`, `displayname`, `type`, `moduleid`, `maintable`, `querytable`, `editfile`, `editroleid`, `addfile`, `addroleid`, `importfile`, `importroleid`, `searchroleid`, `advsearchroleid`, `viewsqlroleid`, `deletebutton`, `canpost`, `hascustomfields`, `defaultwhereclause`, `defaultsortorder`, `defaultsearchtype`, `defaultcriteriafindoptions`, `defaultcriteriaselection`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('205', 'tbld:2ad5146c-d4c0-db8e-592a-c0cc2f3c2c21', 'Snapshot Widgets', 'system', '1', 'widgets', '((widgets INNER JOIN modules ON widgets.moduleid = modules.id) LEFT JOIN roles ON widgets.roleid = roles.id) ', 'modules/base/widgets_addedit.php', '-100', 'modules/base/widgets_addedit.php', '-100', NULL, '-100', '-100', '-100', '-100', 'delete', '0', '0', 'widgets.id != -1', 'widgets.title', NULL, NULL, NULL, 1, NOW(), 1, NOW()); -
trunk/phpbms/install/tabs.sql
r517 r542 1 INSERT INTO `tabs` (`id`, `name`, `tabgroup`, `location`, `displayorder`, `enableonnew`, `roleid`, `tooltip`, `notificationsql`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES (1,'general','tabledefs entry','modules/base/tabledefs_addedit.php',10,1,-100,'','',1,NOW(),1,NOW());2 INSERT INTO `tabs` (`id`, `name`, `tabgroup`, `location`, `displayorder`, `enableonnew`, `roleid`, `tooltip`, `notificationsql`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES (2,'columns','tabledefs entry','modules/base/tabledefs_columns.php',20,0,-100,'',NULL,1,NOW(),1,NOW());3 INSERT INTO `tabs` (`id`, `name`, `tabgroup`, `location`, `displayorder`, `enableonnew`, `roleid`, `tooltip`, `notificationsql`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES (3,'options','tabledefs entry','modules/base/tabledefs_options.php',30,0,-100,'',NULL,1,NOW(),1,NOW());4 INSERT INTO `tabs` (`id`, `name`, `tabgroup`, `location`, `displayorder`, `enableonnew`, `roleid`, `tooltip`, `notificationsql`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES (4,'quick search','tabledefs entry','modules/base/tabledefs_quicksearch.php',40,0,-100,'',NULL,1,NOW(),1,NOW());5 INSERT INTO `tabs` (`id`, `name`, `tabgroup`, `location`, `displayorder`, `enableonnew`, `roleid`, `tooltip`, `notificationsql`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES (5,'search fields','tabledefs entry','modules/base/tabledefs_searchfields.php',50,0,-100,'',NULL,1,NOW(),1,NOW());6 INSERT INTO `tabs` (`id`, `name`, `tabgroup`, `location`, `displayorder`, `enableonnew`, `roleid`, `tooltip`, `notificationsql`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES (100,'groupings','tabledefs entry','modules/base/tabledefs_groupings.php',25,0,-100,'',NULL,1,NOW(),1,NOW());7 INSERT INTO `tabs` (`id`, ` name`, `tabgroup`, `location`, `displayorder`, `enableonnew`, `roleid`, `tooltip`, `notificationsql`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES (101, 'custom fields', 'tabledefs entry', 'modules/base/tabledefs_custom.php', '60', '0', '-100', NULL, NULL, 1, NOW(), 1, NOW());1 INSERT INTO `tabs` (`id`, `uuid`, `name`, `tabgroup`, `location`, `displayorder`, `enableonnew`, `roleid`, `tooltip`, `notificationsql`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('1', 'tab:fdf064e0-f2d9-6c67-b64f-449e72e859b9', 'general', 'tabledefs entry', 'modules/base/tabledefs_addedit.php', '10', '1', '-100', '', '', 1, NOW(), 1, NOW()); 2 INSERT INTO `tabs` (`id`, `uuid`, `name`, `tabgroup`, `location`, `displayorder`, `enableonnew`, `roleid`, `tooltip`, `notificationsql`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('2', 'tab:b1011143-1d47-520e-5879-3953a4f5055b', 'columns', 'tabledefs entry', 'modules/base/tabledefs_columns.php', '20', '0', '-100', '', NULL, 1, NOW(), 1, NOW()); 3 INSERT INTO `tabs` (`id`, `uuid`, `name`, `tabgroup`, `location`, `displayorder`, `enableonnew`, `roleid`, `tooltip`, `notificationsql`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('3', 'tab:c5bdaf10-062c-fb3a-f40f-ddce821fd579', 'options', 'tabledefs entry', 'modules/base/tabledefs_options.php', '30', '0', '-100', '', NULL, 1, NOW(), 1, NOW()); 4 INSERT INTO `tabs` (`id`, `uuid`, `name`, `tabgroup`, `location`, `displayorder`, `enableonnew`, `roleid`, `tooltip`, `notificationsql`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('4', 'tab:276dacd4-4a37-d979-aeda-a7982f632559', 'quick search', 'tabledefs entry', 'modules/base/tabledefs_quicksearch.php', '40', '0', '-100', '', NULL, 1, NOW(), 1, NOW()); 5 INSERT INTO `tabs` (`id`, `uuid`, `name`, `tabgroup`, `location`, `displayorder`, `enableonnew`, `roleid`, `tooltip`, `notificationsql`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('5', 'tab:22d08e82-5047-4150-6de7-49e89149f56b', 'search fields', 'tabledefs entry', 'modules/base/tabledefs_searchfields.php', '50', '0', '-100', '', NULL, 1, NOW(), 1, NOW()); 6 INSERT INTO `tabs` (`id`, `uuid`, `name`, `tabgroup`, `location`, `displayorder`, `enableonnew`, `roleid`, `tooltip`, `notificationsql`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('100', 'tab:c111eaf5-692b-9c7d-1d46-1bacb6703361', 'groupings', 'tabledefs entry', 'modules/base/tabledefs_groupings.php', '25', '0', '-100', '', NULL, 1, NOW(), 1, NOW()); 7 INSERT INTO `tabs` (`id`, `uuid`, `name`, `tabgroup`, `location`, `displayorder`, `enableonnew`, `roleid`, `tooltip`, `notificationsql`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('101', 'tab:2ebf956d-5e39-c7d5-16b7-501b64685a5a', 'custom fields', 'tabledefs entry', 'modules/base/tabledefs_custom.php', '60', '0', '-100', NULL, NULL, 1, NOW(), 1, NOW()); -
trunk/phpbms/install/updatev0.98.sql
r540 r542 2 2 ALTER TABLE `choices` ENGINE=INNODB; 3 3 ALTER TABLE `files` ENGINE=INNODB; 4 ALTER TABLE `files` ADD COLUMN `uuid` varchar(64) NOT NULL AFTER `id`; 5 ALTER TABLE `files` ADD COLUMN `custom1` DOUBLE, ADD COLUMN `custom2` DOUBLE, ADD COLUMN `custom3` DATETIME, ADD COLUMN `custom4` DATETIME, ADD COLUMN `custom5` VARCHAR(255), ADD COLUMN `custom6` VARCHAR(255), ADD COLUMN `custom7` TINYINT(1) DEFAULT 0, ADD COLUMN `custom8` TINYINT(1) DEFAULT 0; 4 6 ALTER TABLE `log` ENGINE=INNODB; 5 7 ALTER TABLE `menu` ENGINE=INNODB; 6 8 ALTER TABLE `menu` ADD COlUMN `uuid` varchar(64) NOT NULL AFTER `id`, MODIFY COLUMN `parentid` varchar(64) NOT NULL DEFAULT '0'; 7 9 ALTER TABLE `modules` ENGINE=INNODB; 10 ALTER TABLE `modules` ADD COLUMN `uuid` varchar(64) NOT NULL AFTER `id`; 8 11 ALTER TABLE `notes` ENGINE=INNODB; 9 12 ALTER TABLE `notes` MODIFY COLUMN `type` CHAR(2) NOT NULL DEFAULT 'NT'; 13 ALTER TABLE `notes` ADD COLUMN `uuid` varchar(64) NOT NULL AFTER `id`; 14 ALTER TABLE `notes` ADD COLUMN `custom1` DOUBLE, ADD COLUMN `custom2` DOUBLE, ADD COLUMN `custom3` DATETIME, ADD COLUMN `custom4` DATETIME, ADD COLUMN `custom5` VARCHAR(255), ADD COLUMN `custom6` VARCHAR(255), ADD COLUMN `custom7` TINYINT(1) DEFAULT 0, ADD COLUMN `custom8` TINYINT(1) DEFAULT 0; 10 15 ALTER TABLE `relationships` ENGINE=INNODB; 16 ALTER TABLE `relationships` ADD COLUMN `uuid` varchar(64) NOT NULL AFTER `id`; 11 17 ALTER TABLE `reports` ENGINE=INNODB; 12 18 ALTER TABLE `reports` MODIFY COLUMN `reportfile` VARCHAR(128) NOT NULL; … … 15 21 ALTER TABLE `roles` ENGINE=INNODB; 16 22 ALTER TABLE `roles` MODIFY COLUMN `inactive` TINYINT(4) NOT NULL DEFAULT 0; 23 ALTER TABLE `roles` ADD COLUMN `uuid` varchar(64) NOT NULL AFTER `id`; 24 ALTER TABLE `roles` ADD COLUMN `custom1` DOUBLE, ADD COLUMN `custom2` DOUBLE, ADD COLUMN `custom3` DATETIME, ADD COLUMN `custom4` DATETIME, ADD COLUMN `custom5` VARCHAR(255), ADD COLUMN `custom6` VARCHAR(255), ADD COLUMN `custom7` TINYINT(1) DEFAULT 0, ADD COLUMN `custom8` TINYINT(1) DEFAULT 0; 17 25 ALTER TABLE `rolestousers` ENGINE=INNODB; 18 26 ALTER TABLE `scheduler` ENGINE=INNODB; 19 INSERT INTO `scheduler` (`name`, `job`, `crontab`, `lastrun`, `startdatetime`, `enddatetime`, `description`, `inactive`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('Clean Import Files', './scheduler_delete_tempimport.php', '30::*::*::*::*', NULL, NOW(), NULL, 'This will delete any temporary import files that are present (for whatever reason) after 30 minutes of their creation.', '0', 1, NOW(), 1, NOW()); 20 INSERT INTO `scheduler` (`id`, `name`, `job`, `crontab`, `lastrun`, `startdatetime`, `enddatetime`, `description`, `inactive`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('4', 'Remove Excess System Log Records', './scheduler_delete_logs.php', '*::24::*::*::*', NULL, '2009-03-31 12:00:00', NULL, 'This script will trim the system log when there are more than 2000 records present at the time of its calling (default will be every 24 hours).', '0', 1, NOW(), 1, NOW()); 27 ALTER TABLE `scheduler` ADD COLUMN `uuid` varchar(64) NOT NULL AFTER `id`; 28 --scheduler-- 29 INSERT INTO `scheduler` (`uuid`, `name`, `job`, `crontab`, `lastrun`, `startdatetime`, `enddatetime`, `description`, `inactive`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('schd:fb52e7fb-bb49-7f5f-89e1-002b2785f085', 'Clean Import Files', './scheduler_delete_tempimport.php', '30::*::*::*::*', '2009-05-28 12:30:02', '2009-05-07 17:27:13', NULL, 'This will delete any temporary import files that are present (for whatever reason) after 30 minutes of their creation.', '0', 1, NOW(), 1, NOW()); 30 INSERT INTO `scheduler` (`uuid`, `name`, `job`, `crontab`, `lastrun`, `startdatetime`, `enddatetime`, `description`, `inactive`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('schd:d1c247de-9811-d37f-ad94-a8472dc1bc9c', 'Remove Excess System Log Records', './scheduler_delete_logs.php', '*::24::*::*::*', NULL, '2009-03-31 12:00:00', NULL, 'This script will trim the system log when there are more than 2000 records present at the time of its calling (default will be every 24 hours).', '0', 1, NOW(), 1, NOW()); 31 --end insert scheduler 21 32 ALTER TABLE `settings` ENGINE=INNODB; 22 33 ALTER TABLE `smartsearches` ENGINE=INNODB; 34 ALTER TABLE `smartsearches` ADD COLUMN `uuid` varchar(64) NOT NULL AFTER `id`; 35 --update smartsearches-- 36 UPDATE `smartsearches` SET `uuid`='smrt:ccc73fa4-6176-fad4-fbb1-5186d0edbdd1' WHERE `id`='2'; 37 UPDATE `smartsearches` SET `uuid`='smrt:855406d5-659d-c907-74a1-acfd3802fd73' WHERE `id`='5'; 38 UPDATE `smartsearches` SET `uuid`='smrt:ed5b1d7f-b0fe-2088-f17c-47bfbe1ace25' WHERE `id`='9'; 39 --end update smartsearches-- 23 40 ALTER TABLE `tablecolumns` ENGINE=INNODB; 24 41 ALTER TABLE `tablecolumns` MODIFY COLUMN `roleid` int(10) NOT NULL default '0'; 42 43 --TABLEDEFS-- 25 44 ALTER TABLE `tabledefs` ENGINE=INNODB; 26 45 ALTER TABLE `tabledefs` ADD COLUMN `importfile` VARCHAR(128) DEFAULT NULL AFTER `addroleid`, ADD COLUMN `importroleid` int(11) NOT NULL DEFAULT '-100' AFTER `importfile`, ADD COLUMN `canpost` tinyint(4) NOT NULL default '0' AFTER `deletebutton`, ADD COLUMN `hascustomfields` tinyint(4) NOT NULL default '0' AFTER `canpost`; 27 46 ALTER TABLE `tabledefs` MODIFY COLUMN `defaultwhereclause` TEXT DEFAULT NULL, MODIFY COLUMN `defaultsortorder` TEXT; 47 ALTER TABLE `tabledefs` ADD COLUMN `uuid` varchar(64) NOT NULL AFTER `id`; 48 --END TABLEDEFS-- 49 28 50 ALTER TABLE `tablefindoptions` ENGINE=INNODB; 29 51 ALTER TABLE `tablefindoptions` MODIFY COLUMN `search` TEXT NOT NULL; … … 52 74 ALTER TABLE `tablesearchablefields` MODIFY COLUMN `field` TEXT NOT NULL; 53 75 ALTER TABLE `tabs` ENGINE=INNODB; 76 ALTER TABLE `tabs` ADD COLUMN `uuid` varchar(64) NOT NULL AFTER `id`; 54 77 ALTER TABLE `users` ENGINE=INNODB; 55 78 ALTER TABLE `users` ADD COLUMN `lastip` VARCHAR(45) NOT NULL DEFAULT '' AFTER `lastname`; 79 ALTER TABLE `users` ADD COLUMN `uuid` varchar(64) NOT NULL AFTER `id`; 80 ALTER TABLE `users` ADD COLUMN `custom1` DOUBLE, ADD COLUMN `custom2` DOUBLE, ADD COLUMN `custom3` DATETIME, ADD COLUMN `custom4` DATETIME, ADD COLUMN `custom5` VARCHAR(255), ADD COLUMN `custom6` VARCHAR(255), ADD COLUMN `custom7` TINYINT(1) DEFAULT 0, ADD COLUMN `custom8` TINYINT(1) DEFAULT 0; 56 81 ALTER TABLE `usersearches` ENGINE=INNODB; 57 82 UPDATE `tablefindoptions` SET `search` = 'notes.type=\'TS\' AND notes.private=0' WHERE `tabledefid` = 23 AND `name` = 'Public Tasks'; … … 60 85 CREATE TABLE `widgets` (`id` int(10) unsigned NOT NULL AUTO_INCREMENT, `uuid` varchar(64) NOT NULL, `type` varchar(64) NOT NULL, `title` varchar(128) NOT NULL, `file` varchar(255) NOT NULL, `roleid` int(11) NOT NULL default '0', `moduleid` int(11) NOT NULL default '0', `default` tinyint(4) NOT NULL default '0', `createdby` int(11) default NULL, `creationdate` datetime default NULL, `modifiedby` int(10) unsigned default NULL, `modifieddate` timestamp, PRIMARY KEY (`id`), KEY `uniqueid` (`uuid`)) ENGINE=INNODB; 61 86 CREATE TABLE `userpreferences` (`id` int(10) unsigned NOT NULL AUTO_INCREMENT, `userid` int(120) NOT NULL, `name` varchar(64) NOT NULL, `value` TEXT, PRIMARY KEY (`id`), KEY `thename` (`name`)) ENGINE=INNODB; 62 INSERT INTO `tabledefs` (`id`, `displayname`, `type`, `moduleid`, `maintable`, `querytable`, `editfile`, `editroleid`, `addfile`, `addroleid`, `importfile`, `importroleid`, `searchroleid`, `advsearchroleid`, `viewsqlroleid`, `deletebutton`, `canpost`, `defaultwhereclause`, `defaultsortorder`, `defaultsearchtype`, `defaultcriteriafindoptions`, `defaultcriteriaselection`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('205', 'Snapshot Widgets', 'system', '1', 'widgets', '((widgets INNER JOIN modules ON widgets.moduleid = modules.id) LEFT JOIN roles ON widgets.roleid = roles.id) ', 'modules/base/widgets_addedit.php', '-100', 'modules/base/widgets_addedit.php', '-100', NULL, '-100', '-100', '-100', '-100', 'delete', '0', 'widgets.id != -1', 'widgets.title', NULL, NULL, NULL, 1, NOW(), 1, NOW()); 87 88 --tabledefs update/insert-- 89 INSERT INTO `tabledefs` (`id`, `uuid`, `displayname`, `type`, `moduleid`, `maintable`, `querytable`, `editfile`, `editroleid`, `addfile`, `addroleid`, `importfile`, `importroleid`, `searchroleid`, `advsearchroleid`, `viewsqlroleid`, `deletebutton`, `canpost`, `hascustomfields`, `defaultwhereclause`, `defaultsortorder`, `defaultsearchtype`, `defaultcriteriafindoptions`, `defaultcriteriaselection`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('205', 'tbld:2ad5146c-d4c0-db8e-592a-c0cc2f3c2c21', 'Snapshot Widgets', 'system', '1', 'widgets', '((widgets INNER JOIN modules ON widgets.moduleid = modules.id) LEFT JOIN roles ON widgets.roleid = roles.id) ', 'modules/base/widgets_addedit.php', '-100', 'modules/base/widgets_addedit.php', '-100', NULL, '-100', '-100', '-100', '-100', 'delete', '0', '0', 'widgets.id != -1', 'widgets.title', NULL, NULL, NULL, 1, NOW(), 1, NOW()); 63 90 DELETE FROM `tabledefs` WHERE `id` = '19'; 64 INSERT INTO `tabledefs` (`id`, `displayname`, `type`, `moduleid`, `maintable`, `querytable`, `editfile`, `editroleid`, `addfile`, `addroleid`, `importfile`, `importroleid`, `searchroleid`, `advsearchroleid`, `viewsqlroleid`, `deletebutton`, `canpost`, `defaultwhereclause`, `defaultsortorder`, `defaultsearchtype`, `defaultcriteriafindoptions`, `defaultcriteriaselection`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('19', 'Menu', 'system', '1', 'menu', '((menu LEFT JOIN menu as parentmenu on menu.parentid=parentmenu.uuid) LEFT JOIN roles on menu.roleid=roles.id)', 'modules/base/menu_addedit.php', '-100', 'modules/base/menu_addedit.php', '-100', NULL, '-100', '-100', '-100', '-100', 'delete', '0', 'menu.id!=0', 'if(parentmenu.name is null,menu.displayorder,parentmenu.displayorder+(menu.displayorder+1)/10000)', NULL, NULL, NULL, 1, NOW(), 1, NOW()); 91 INSERT INTO `tabledefs` (`id`, `uuid`, `displayname`, `type`, `moduleid`, `maintable`, `querytable`, `editfile`, `editroleid`, `addfile`, `addroleid`, `importfile`, `importroleid`, `searchroleid`, `advsearchroleid`, `viewsqlroleid`, `deletebutton`, `canpost`, `hascustomfields`, `defaultwhereclause`, `defaultsortorder`, `defaultsearchtype`, `defaultcriteriafindoptions`, `defaultcriteriaselection`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('19', 'tbld:83187e3d-101e-a8a5-037f-31e9800fed2d', 'Menu', 'system', '1', 'menu', '((menu LEFT JOIN menu as parentmenu on menu.parentid=parentmenu.id) LEFT JOIN roles on menu.roleid=roles.id)', 'modules/base/menu_addedit.php', '-100', 'modules/base/menu_addedit.php', '-100', NULL, '-100', '-100', '-100', '-100', 'delete', '0', '0', 'menu.id!=0', 'if(parentmenu.name is null,menu.displayorder,parentmenu.displayorder+(menu.displayorder+1)/10000)', '', '', '', 1, NOW(), 1, NOW()); 92 UPDATE `tabledefs` SET `uuid`='tbld:afe6d297-b484-4f0b-57d4-1c39412e9dfb' WHERE `id`='9'; 93 UPDATE `tabledefs` SET `uuid`='tbld:8d19c73c-42fb-d829-3681-d20b4dbe43b9' WHERE `id`='10'; 94 UPDATE `tabledefs` SET `uuid`='tbld:5c9d645f-26ab-5003-b98e-89e9049f8ac3' WHERE `id`='11'; 95 UPDATE `tabledefs` SET `uuid`='tbld:a4cdd991-cf0a-916f-1240-49428ea1bdd1' WHERE `id`='12'; 96 UPDATE `tabledefs` SET `uuid`='tbld:d595ef42-db9d-2233-1b9b-11dfd0db9cbb' WHERE `id`='16'; 97 UPDATE `tabledefs` SET `uuid`='tbld:e251524a-2da4-a0c9-8725-d3d0412d8f4a' WHERE `id`='17'; 98 UPDATE `tabledefs` SET `uuid`='tbld:ea159d67-5e89-5b7f-f5a0-c740e147cd73' WHERE `id`='21'; 99 UPDATE `tabledefs` SET `uuid`='tbld:2bc3e683-81f9-694a-9550-a0c7263057de' WHERE `id`='23'; 100 UPDATE `tabledefs` SET `uuid`='tbld:0fcca651-6c34-c74d-ac04-2d88f602dd71' WHERE `id`='24'; 101 UPDATE `tabledefs` SET `uuid`='tbld:80b4f38d-b957-bced-c0a0-ed08a0db6475' WHERE `id`='26'; 102 UPDATE `tabledefs` SET `uuid`='tbld:edb8c896-7ce3-cafe-1d58-5aefbcd5f3d7' WHERE `id`='27'; 103 UPDATE `tabledefs` SET `uuid`='tbld:87b9fe06-afe5-d9c6-0fa0-4a0f2ec4ee8a' WHERE `id`='200'; 104 UPDATE `tabledefs` SET `uuid`='tbld:83de284b-ef79-3567-145c-30ca38b40796' WHERE `id`='201'; 105 UPDATE `tabledefs` SET `uuid`='tbld:3f71ab66-1f84-d68b-e2a3-3ee3bb0ec667' WHERE `id`='202'; 106 UPDATE `tabledefs` SET `uuid`='tbld:7e75af48-6f70-d157-f440-69a8e7f59d38' WHERE `id`='203'; 107 UPDATE `tabledefs` SET `uuid`='tbld:29925e0a-c825-0067-8882-db4b57866a96' WHERE `id`='204'; 108 --end tabledefs update/insert-- 109 110 --users update-- 111 UPDATE `users` SET `uuid`='usr:5c196e01-193a-8952-fee7-29b4e5e6a0b0' WHERE `id`='1'; 112 UPDATE `users` SET `uuid`='usr:cb67a60b-a264-735c-6189-49a7c883af0b' WHERE `id`='2'; 113 UPDATE `users` SET `uuid`='usr:42e0cc76-3c31-d9b6-ff12-fe4adfd15e75' WHERE `id`='3'; 114 --end users update-- 115 65 116 INSERT INTO `tablecolumns` (`tabledefid`, `name`, `column`, `align`, `footerquery`, `displayorder`, `sortorder`, `wrap`, `size`, `format`, `roleid`) VALUES ('205', 'widget', 'concat(\'[b]\', widgets.title, \'[/b][br]\', widgets.uuid)', 'left', '', '0', 'widgets.title', '0', '100%', 'bbcode', '0'); 66 117 INSERT INTO `tablecolumns` (`tabledefid`, `name`, `column`, `align`, `footerquery`, `displayorder`, `sortorder`, `wrap`, `size`, `format`, `roleid`) VALUES ('205', 'role', 'IF(widgets.roleid != 0, IF(widgets.roleid != -100, roles.name, \'Administrator\'), \'EVERYONE\')', 'left', '', '2', '', '0', '', NULL, '0'); … … 119 170 INSERT INTO `menu` (`uuid`, `name`, `link`, `parentid`, `displayorder`, `createdby`, `modifiedby`, `creationdate`, `modifieddate`, `roleid`) VALUES ('menu:e8401ebb-c369-304f-053d-8195988e7faf', '----', 'N/A', 'menu:f07d910f-f56d-3d24-e74f-7a3b36b2d3c8', '30', 1, 1, NOW(), NOW(), '-100'); 120 171 UPDATE `tabledefs` SET `hascustomfields` = 1 WHERE `id` IN(12, 9, 26, 200); 121 ALTER TABLE `notes` ADD COLUMN `custom1` DOUBLE, ADD COLUMN `custom2` DOUBLE, ADD COLUMN `custom3` DATETIME, ADD COLUMN `custom4` DATETIME, ADD COLUMN `custom5` VARCHAR(255), ADD COLUMN `custom6` VARCHAR(255), ADD COLUMN `custom7` TINYINT(1) DEFAULT 0, ADD COLUMN `custom8` TINYINT(1) DEFAULT 0; 122 ALTER TABLE `users` ADD COLUMN `custom1` DOUBLE, ADD COLUMN `custom2` DOUBLE, ADD COLUMN `custom3` DATETIME, ADD COLUMN `custom4` DATETIME, ADD COLUMN `custom5` VARCHAR(255), ADD COLUMN `custom6` VARCHAR(255), ADD COLUMN `custom7` TINYINT(1) DEFAULT 0, ADD COLUMN `custom8` TINYINT(1) DEFAULT 0; 123 ALTER TABLE `roles` ADD COLUMN `custom1` DOUBLE, ADD COLUMN `custom2` DOUBLE, ADD COLUMN `custom3` DATETIME, ADD COLUMN `custom4` DATETIME, ADD COLUMN `custom5` VARCHAR(255), ADD COLUMN `custom6` VARCHAR(255), ADD COLUMN `custom7` TINYINT(1) DEFAULT 0, ADD COLUMN `custom8` TINYINT(1) DEFAULT 0; 124 ALTER TABLE `files` ADD COLUMN `custom1` DOUBLE, ADD COLUMN `custom2` DOUBLE, ADD COLUMN `custom3` DATETIME, ADD COLUMN `custom4` DATETIME, ADD COLUMN `custom5` VARCHAR(255), ADD COLUMN `custom6` VARCHAR(255), ADD COLUMN `custom7` TINYINT(1) DEFAULT 0, ADD COLUMN `custom8` TINYINT(1) DEFAULT 0; 125 INSERT INTO `tabs` (`id`, `name`, `tabgroup`, `location`, `displayorder`, `enableonnew`, `roleid`, `tooltip`, `notificationsql`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES (101, 'custom fields', 'tabledefs entry', 'modules/base/tabledefs_custom.php', '60', '0', '-100', NULL, NULL, 1, NOW(), 1, NOW()); 172 173 --tabs insert/update-- 174 INSERT INTO `tabs` (`id`, `uuid`, `name`, `tabgroup`, `location`, `displayorder`, `enableonnew`, `roleid`, `tooltip`, `notificationsql`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('101', 'tab:2ebf956d-5e39-c7d5-16b7-501b64685a5a', 'custom fields', 'tabledefs entry', 'modules/base/tabledefs_custom.php', '60', '0', '-100', NULL, NULL, 1, NOW(), 1, NOW()); 175 UPDATE `tabs` SET `uuid`='tab:fdf064e0-f2d9-6c67-b64f-449e72e859b9' WHERE `id`='1'; 176 UPDATE `tabs` SET `uuid`='tab:b1011143-1d47-520e-5879-3953a4f5055b' WHERE `id`='2'; 177 UPDATE `tabs` SET `uuid`='tab:c5bdaf10-062c-fb3a-f40f-ddce821fd579' WHERE `id`='3'; 178 UPDATE `tabs` SET `uuid`='tab:276dacd4-4a37-d979-aeda-a7982f632559' WHERE `id`='4'; 179 UPDATE `tabs` SET `uuid`='tab:22d08e82-5047-4150-6de7-49e89149f56b' WHERE `id`='5'; 180 UPDATE `tabs` SET `uuid`='tab:c111eaf5-692b-9c7d-1d46-1bacb6703361' WHERE `id`='100'; 181 --end tabs insert/update-- 182 --reports update-- 126 183 UPDATE `reports` SET `uuid`='reports:37cee478-b57e-2d53-d951-baf3937ba9e0' WHERE `name`='Raw Table Print'; 127 184 UPDATE `reports` SET `uuid`='reports:dac75fb9-91d2-cb1e-9213-9fab6d32f4c8' WHERE `name`='Raw Table Export'; … … 129 186 UPDATE `reports` SET `uuid`='reports:2944b204-5967-348a-8679-6835f45f0d79' WHERE `name`='SQL Export'; 130 187 UPDATE `reports` SET `uuid`='reports:37a299d1-d795-ad83-4b47-0778c16a381c' WHERE `name`='Support Tables SQL Export'; 131 -- Adding UUID prefix 188 --end reports update-- 189 --ADD TABLEDEFS-- 132 190 ALTER TABLE `tabledefs` ADD COLUMN `prefix` VARCHAR(4) AFTER `displayname`; 133 191 -- Setting BASE UUID prefix for needed records -
trunk/phpbms/install/users.sql
r359 r542 1 INSERT INTO `users` (`id`, ` login`, `password`, `firstname`, `lastname`, `creationdate`, `revoked`, `createdby`, `modifiedby`, `lastlogin`, `modifieddate`, `email`, `phone`, `department`, `employeenumber`, `admin`, `portalaccess`) VALUES (1,'nologin','Tá-Gó','phpBMS','Install',NOW(),1,1,1,NULL,NOW(),'','','','',0,1);2 INSERT INTO `users` (`id`, ` login`, `password`, `firstname`, `lastname`, `creationdate`, `revoked`, `createdby`, `modifiedby`, `lastlogin`, `modifieddate`, `email`, `phone`, `department`, `employeenumber`, `admin`, `portalaccess`) VALUES (2,'admin',encode('phpbms','freeble'),'Administrator',' ',NOW(),0,1,1,NULL,NOW(),'','','','',1,0);3 INSERT INTO `users` (`id`, ` login`, `password`, `firstname`, `lastname`, `creationdate`, `revoked`, `createdby`, `modifiedby`, `lastlogin`, `modifieddate`, `email`, `phone`, `department`, `employeenumber`, `admin`, `portalaccess`) VALUES (3,'Scheduler','Òt%ÁBøTv:$ÖRtÈ`','phpBMS','Scheduler',NOW(),0,1,1,NULL,NOW(),'','','','',0,1);1 INSERT INTO `users` (`id`, `uuid`, `login`, `password`, `firstname`, `lastname`, `lastip`, `creationdate`, `revoked`, `createdby`, `modifiedby`, `lastlogin`, `modifieddate`, `email`, `phone`, `department`, `employeenumber`, `admin`, `portalaccess`) VALUES ('1', 'usr:5c196e01-193a-8952-fee7-29b4e5e6a0b0', 'nologin', 'Tá-Gó', 'phpBMS', 'Install', '', NOW(), '1', 1, 1, NULL, NOW(), '', '', '', '', '0', '1'); 2 INSERT INTO `users` (`id`, `uuid`, `login`, `password`, `firstname`, `lastname`, `lastip`, `creationdate`, `revoked`, `createdby`, `modifiedby`, `lastlogin`, `modifieddate`, `email`, `phone`, `department`, `employeenumber`, `admin`, `portalaccess`) VALUES ('2', 'usr:cb67a60b-a264-735c-6189-49a7c883af0b', 'admin', encode('phpbms','freeble'), 'Administrator', ' ', '192.168.1.86', NOW(), '0', 1, 1, '2009-05-28 11:52:12', NOW(), '', '', '', '', '1', '0'); 3 INSERT INTO `users` (`id`, `uuid`, `login`, `password`, `firstname`, `lastname`, `lastip`, `creationdate`, `revoked`, `createdby`, `modifiedby`, `lastlogin`, `modifieddate`, `email`, `phone`, `department`, `employeenumber`, `admin`, `portalaccess`) VALUES ('3', 'usr:42e0cc76-3c31-d9b6-ff12-fe4adfd15e75', 'Scheduler', 'Òt%ÁBøTv:$ÖRtÈ`', 'phpBMS', 'Scheduler', '', NOW(), '0', 1, 1, NULL, NOW(), '', '', '', '', '0', '1'); -
trunk/phpbms/modules/bms/install/createtables.sql
r524 r542 1 1 CREATE TABLE clientemailprojects ( 2 2 id int(11) NOT NULL auto_increment, 3 `uuid` varchar(64) NOT NULL, 3 4 name varchar(64) default '', 4 5 userid int(11) NOT NULL default '0', … … 13 14 CREATE TABLE `clients` ( 14 15 `id` int(11) NOT NULL auto_increment, 16 `uuid` varchar(64) NOT NULL, 15 17 `firstname` varchar(64) NOT NULL default '', 16 18 `lastname` varchar(64) NOT NULL default '', … … 68 70 CREATE TABLE discounts ( 69 71 id int(11) NOT NULL auto_increment, 72 `uuid` varchar(64) NOT NULL, 70 73 name varchar(128) default '', 71 74 inactive tinyint(1) NOT NULL default '0', … … 90 93 CREATE TABLE `invoices` ( 91 94 `id` int(11) NOT NULL auto_increment, 95 `uuid` varchar(64) NOT NULL, 92 96 `clientid` int(11) NOT NULL default '0', 93 97 `type` enum('Quote','Order','Invoice','VOID') default NULL, … … 209 213 CREATE TABLE productcategories ( 210 214 `id` int(11) NOT NULL auto_increment, 215 `uuid` varchar(64) NOT NULL, 211 216 `name` varchar(64) default NULL, 212 217 `parentid` int(11) NOT NULL DEFAULT 0, … … 237 242 description varchar(255) default NULL, 238 243 id int(11) NOT NULL auto_increment, 244 `uuid` varchar(64) NOT NULL, 239 245 isoversized tinyint(4) NOT NULL default '0', 240 246 isprepackaged tinyint(4) NOT NULL default '0', … … 276 282 CREATE TABLE tax ( 277 283 id int(11) NOT NULL auto_increment, 284 `uuid` varchar(64) NOT NULL, 278 285 name varchar(64) default NULL, 279 286 percentage double NOT NULL default '0', … … 296 303 CREATE TABLE `shippingmethods` ( 297 304 `id` int(11) NOT NULL AUTO_INCREMENT, 305 `uuid` varchar(64) NOT NULL, 298 306 `name` VARCHAR(128) NOT NULL, 299 307 `inactive` tinyint(4) NOT NULL DEFAULT 0, … … 318 326 CREATE TABLE `paymentmethods` ( 319 327 `id` int(11) NOT NULL AUTO_INCREMENT, 328 `uuid` varchar(64) NOT NULL, 320 329 `name` varchar(128) NOT NULL default '', 321 330 `type` enum('draft','charge','receivable') default NULL, … … 341 350 CREATE TABLE `invoicestatuses` ( 342 351 `id` INTEGER UNSIGNED NOT NULL AUTO_INCREMENT, 352 `uuid` varchar(64) NOT NULL, 343 353 `name` VARCHAR(128), 344 354 `setreadytopost` TINYINT UNSIGNED NOT NULL DEFAULT 0 , … … 395 405 CREATE TABLE `receipts` ( 396 406 `id` int(10) unsigned NOT NULL AUTO_INCREMENT, 407 `uuid` varchar(64) NOT NULL, 397 408 `clientid` int(10) unsigned NOT NULL, 398 409 `amount` double NOT NULL default '0', … … 440 451 CREATE TABLE `addresses` ( 441 452 `id` INTEGER UNSIGNED NOT NULL AUTO_INCREMENT, 453 `uuid` varchar(64) NOT NULL, 442 454 `title` VARCHAR(128), 443 455 `shiptoname` VARCHAR(128), -
trunk/phpbms/modules/bms/install/roles.sql
r311 r542 1 INSERT INTO `roles` (`id`, ` name`, `description`, `inactive`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES (10,'shipping','Basic user access only.',0,1,NOW(),1,NOW());2 INSERT INTO `roles` (`id`, ` name`, `description`, `inactive`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES (20,'sales','sales',0,1,NOW(),1,NOW());3 INSERT INTO `roles` (`id`, ` name`, `description`, `inactive`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES (30,'sales manager','',0,1,NOW(),1,NOW());4 INSERT INTO `roles` (`id`, ` name`, `description`, `inactive`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES (50,'upper manager','',0,1,NOW(),1,NOW());5 INSERT INTO `roles` (`id`, ` name`, `description`, `inactive`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES (80,'accounts receivable','Access to AR items, and receipts',0,1,NOW(),1,NOW());1 INSERT INTO `roles` (`id`, `uuid`, `name`, `description`, `inactive`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('10', 'role:3403a7e0-adb1-4d0b-3c6e-6d6bbe177d52', 'shipping', 'Basic user access only.', '0', 1, NOW(), 1, NOW(); 2 INSERT INTO `roles` (`id`, `uuid`, `name`, `description`, `inactive`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('20', 'role:de7e6679-8bb2-29ee-4883-2fcd756fb120', 'sales', 'sales', '0', 1, NOW(), 1, NOW()); 3 INSERT INTO `roles` (`id`, `uuid`, `name`, `description`, `inactive`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('30', 'role:259ead9f-100b-55b5-508a-27e33a6216bf', 'sales manager', '', '0', 1, NOW(), 1, NOW()); 4 INSERT INTO `roles` (`id`, `uuid`, `name`, `description`, `inactive`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('50', 'role:8f5fb368-e7d9-5010-d8f6-b4a78adc0520', 'upper manager', '', '0', 1, NOW(), 1, NOW()); 5 INSERT INTO `roles` (`id`, `uuid`, `name`, `description`, `inactive`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('80', 'role:c9439c3c-499b-7bcc-ee14-fec5bfcf5fc2', 'accounts receivable', 'Access to AR items, and receipts', '0', 1, NOW(), 1, NOW()); -
trunk/phpbms/modules/bms/install/shippingmethods.sql
r176 r542 1 INSERT INTO `shippingmethods` (` name`, `inactive`, `priority`, `canestimate`, `estimationscript`, `createdby`, `creationdate`, `modifiedby`,`modifieddate`) VALUES ('FedEx Priority Overnight AM',0,0,0,'',1,NOW(),1,NOW());2 INSERT INTO `shippingmethods` (` name`, `inactive`, `priority`, `canestimate`, `estimationscript`, `createdby`, `creationdate`, `modifiedby`,`modifieddate`) VALUES ('FedEx Standard Overnight',0,0,0,'',1,NOW(),1,NOW());3 INSERT INTO `shippingmethods` (` name`, `inactive`, `priority`, `canestimate`, `estimationscript`, `createdby`, `creationdate`, `modifiedby`,`modifieddate`) VALUES ('UPS 2nd Day Air',0,0,1,'modules/bms/shipping_estimate_ups.php',1,NOW(),1,NOW());4 INSERT INTO `shippingmethods` (` name`, `inactive`, `priority`, `canestimate`, `estimationscript`, `createdby`, `creationdate`, `modifiedby`,`modifieddate`) VALUES ('UPS 3 Day Select',0,0,1,'modules/bms/shipping_estimate_ups.php',1,NOW(),1,NOW());5 INSERT INTO `shippingmethods` (` name`, `inactive`, `priority`, `canestimate`, `estimationscript`, `createdby`, `creationdate`, `modifiedby`,`modifieddate`) VALUES ('UPS Ground (Com)',0,0,1,'modules/bms/shipping_estimate_ups.php',1,NOW(),1,NOW());6 INSERT INTO `shippingmethods` (` name`, `inactive`, `priority`, `canestimate`, `estimationscript`, `createdby`, `creationdate`, `modifiedby`,`modifieddate`) VALUES ('UPS Ground (Res)',0,0,1,'modules/bms/shipping_estimate_ups.php',1,NOW(),1,NOW());7 INSERT INTO `shippingmethods` (` name`, `inactive`, `priority`, `canestimate`, `estimationscript`, `createdby`, `creationdate`, `modifiedby`,`modifieddate`) VALUES ('UPS Next Day Air',0,0,1,'modules/bms/shipping_estimate_ups.php',1,NOW(),1,NOW());1 INSERT INTO `shippingmethods` (`id`, `uuid`, `name`, `inactive`, `priority`, `canestimate`, `estimationscript`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`, `custom1`, `custom2`, `custom3`, `custom4`, `custom5`, `custom6`, `custom7`, `custom8`) VALUES ('1', 'shp:f34a3e10-e782-2675-f041-71f5c88f5aa9', 'FedEx Priority Overnight AM', '0', '0', '0', '', 1, NOW(), 1, NOW(), NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL); 2 INSERT INTO `shippingmethods` (`id`, `uuid`, `name`, `inactive`, `priority`, `canestimate`, `estimationscript`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`, `custom1`, `custom2`, `custom3`, `custom4`, `custom5`, `custom6`, `custom7`, `custom8`) VALUES ('2', 'shp:e2e43816-667a-fdf3-6bec-4456bcf8bef0', 'FedEx Standard Overnight', '0', '0', '0', '', 1, NOW(), 1, NOW(), NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL); 3 INSERT INTO `shippingmethods` (`id`, `uuid`, `name`, `inactive`, `priority`, `canestimate`, `estimationscript`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`, `custom1`, `custom2`, `custom3`, `custom4`, `custom5`, `custom6`, `custom7`, `custom8`) VALUES ('3', 'shp:0f07f7fd-0352-8df7-8294-a57e5e375808', 'UPS 2nd Day Air', '0', '0', '1', 'modules/bms/shipping_estimate_ups.php', 1, NOW(), 1, NOW(), NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL); 4 INSERT INTO `shippingmethods` (`id`, `uuid`, `name`, `inactive`, `priority`, `canestimate`, `estimationscript`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`, `custom1`, `custom2`, `custom3`, `custom4`, `custom5`, `custom6`, `custom7`, `custom8`) VALUES ('4', 'shp:6ef11711-7335-3e90-cf27-df5ea23c1480', 'UPS 3 Day Select', '0', '0', '1', 'modules/bms/shipping_estimate_ups.php', 1, NOW(), 1, NOW(), NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL); 5 INSERT INTO `shippingmethods` (`id`, `uuid`, `name`, `inactive`, `priority`, `canestimate`, `estimationscript`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`, `custom1`, `custom2`, `custom3`, `custom4`, `custom5`, `custom6`, `custom7`, `custom8`) VALUES ('5', 'shp:1a0c53bd-6754-7d9f-4bea-bad57628187a', 'UPS Ground (Com)', '0', '0', '1', 'modules/bms/shipping_estimate_ups.php', 1, NOW(), 1, NOW(), NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL); 6 INSERT INTO `shippingmethods` (`id`, `uuid`, `name`, `inactive`, `priority`, `canestimate`, `estimationscript`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`, `custom1`, `custom2`, `custom3`, `custom4`, `custom5`, `custom6`, `custom7`, `custom8`) VALUES ('6', 'shp:9e0bad1f-0545-6b09-3900-4e5943629037', 'UPS Ground (Res)', '0', '0', '1', 'modules/bms/shipping_estimate_ups.php', 1, NOW(), 1, NOW(), NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL); 7 INSERT INTO `shippingmethods` (`id`, `uuid`, `name`, `inactive`, `priority`, `canestimate`, `estimationscript`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`, `custom1`, `custom2`, `custom3`, `custom4`, `custom5`, `custom6`, `custom7`, `custom8`) VALUES ('7', 'shp:ba131229-fb3d-d328-91c8-323480831b03', 'UPS Next Day Air', '0', '0', '1', 'modules/bms/shipping_estimate_ups.php', 1, NOW(), 1, NOW(), NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL); -
trunk/phpbms/modules/bms/install/smartsearches.sql
r524 r542 1 INSERT INTO `smartsearches` (` id`, `name`, `fromclause`, `valuefield`, `displayfield`, `secondaryfield`, `classfield`, `searchfields`, `filterclause`, `rolefield`, `tabledefid`, `moduleid`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('1', 'Pick Exisiting Client Address', '(clients INNER JOIN addresstorecord ON clients.id = addresstorecord.recordid AND addresstorecord.tabledefid = 2) INNER JOIN addresses ON addresstorecord.addressid = addresses.id', 'addresses.id', 'concat(if(clients.lastname!=\"\",concat(clients.lastname,\", \",clients.firstname,if(clients.company!=\"\",concat(\" (\",clients.company,\")\"),\"\")),clients.company), if(addresses.title != \"\",concat(\" [\", addresses.title, \"]\"),\"\"))', 'CONCAT(addresses.address1,if(addresses.address2 != \'\',concat(\'[br]\', addresses.address2),\'\'),if(addresses.city != \'\',concat(\'[br]\',addresses.city,\', \',if(addresses.state != \'\',addresses.state, \'\'),\' \',if(addresses.postalcode != \'\', addresses.postalcode, \'\')),\'\'),if(addresses.country != \'\',concat(\'[br]\',addresses.country),\'\'))', 'if(addresstorecord.primary,\'primary\',\'\')', 'clients.firstname, clients.lastname, clients.company, addresses.title, addresses.address1', 'clients.inactive=0', NULL, '306', '2', 1, NOW(), 1, NOW());2 INSERT INTO `smartsearches` (` id`, `name`, `fromclause`, `valuefield`, `displayfield`, `secondaryfield`, `classfield`, `searchfields`, `filterclause`, `rolefield`, `tabledefid`, `moduleid`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('3', 'Pick Sales Order Client', '((clients INNER JOIN addresstorecord on clients.id = addresstorecord.recordid AND addresstorecord.tabledefid=2 AND addresstorecord.primary=1) INNER JOIN addresses ON addresstorecord.addressid = addresses.id)', 'clients.id', 'IF(clients.company != \'\', CONCAT(clients.company,IF(clients.lastname != \'\' OR clients.firstname != \'\', CONCAT(\' (\',if(clients.lastname != \'\', clients.lastname, \'{blank}\'),\', \',if(clients.firstname != \'\', clients.firstname, \'{blank}\'),\')\'), \'\')), IF(clients.lastname != \'\' OR clients.firstname != \'\', CONCAT(if(clients.lastname != \'\', clients.lastname, \'{blank}\'),\', \',if(clients.firstname != \'\', clients.firstname, \'{blank}\')), \'\'))', 'IF(addresses.city != \'\' OR addresses.state !=\'\' OR addresses.postalcode != \'\', CONCAT(IF(addresses.city != \'\',addresses.city,\'\'),\', \',IF(addresses.state != \'\', addresses.state, \'\'),\' \',IF(addresses.postalcode != \'\', addresses.postalcode, \'\')),\'unspecified location\')', 'clients.type', 'clients.company, clients.firstname, clients.lastname', 'clients.inactive=0', NULL, '2', '2', 1, NOW(), 1, NOW());3 INSERT INTO `smartsearches` (` id`, `name`, `fromclause`, `valuefield`, `displayfield`, `secondaryfield`, `classfield`, `searchfields`, `filterclause`, `rolefield`, `tabledefid`, `moduleid`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('4', 'Pick Product', 'products', 'products.id', 'CONCAT(products.partnumber,IF(products.partname != \'\',CONCAT(\' :: \',products.partname),\'\'))', 'products.type', '\'\'', 'products.partnumber, products.partname', 'products.inactive = 0 AND products.status = \'In Stock\'', NULL, '4', '2', 1, NOW(), 1, NOW());4 INSERT INTO `smartsearches` (` id`, `name`, `fromclause`, `valuefield`, `displayfield`, `secondaryfield`, `classfield`, `searchfields`, `filterclause`, `rolefield`, `tabledefid`, `moduleid`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('6', 'Pick Client With Credit', '((clients INNER JOIN addresstorecord on clients.id = addresstorecord.recordid AND addresstorecord.tabledefid=2 AND addresstorecord.primary=1) INNER JOIN addresses ON addresstorecord.addressid = addresses.id)', 'clients.id', 'IF(clients.company != \'\', CONCAT(clients.company,IF(clients.lastname != \'\' OR clients.firstname != \'\', CONCAT(\' (\',if(clients.lastname != \'\', clients.lastname, \'{blank}\'),\', \',if(clients.firstname != \'\', clients.firstname, \'{blank}\'),\')\'), \'\')), IF(clients.lastname != \'\' OR clients.firstname != \'\', CONCAT(if(clients.lastname != \'\', clients.lastname, \'{blank}\'),\', \',if(clients.firstname != \'\', clients.firstname, \'{blank}\')), \'\'))', 'IF(addresses.city != \'\' OR addresses.state !=\'\' OR addresses.postalcode != \'\', CONCAT(IF(addresses.city != \'\',addresses.city,\'\'),\', \',IF(addresses.state != \'\', addresses.state, \'\'),\' \',IF(addresses.postalcode != \'\', addresses.postalcode, \'\')),\'unspecified location\')', '\'\'', 'clients.company, clients.firstname, clients.lastname', 'clients.inactive = 0 AND clients.type=\'client\' AND clients.hascredit=1', NULL, '2', '2', 1, NOW(), 1, NOW());5 INSERT INTO `smartsearches` (` id`, `name`, `fromclause`, `valuefield`, `displayfield`, `secondaryfield`, `classfield`, `searchfields`, `filterclause`, `rolefield`, `tabledefid`, `moduleid`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('7', 'Pick Client By Email', 'clients', 'clients.id', 'IF(clients.company != \'\', CONCAT(clients.company,IF(clients.lastname != \'\' OR clients.firstname != \'\', CONCAT(\' (\',if(clients.lastname != \'\', clients.lastname, \'{blank}\'),\', \',if(clients.firstname != \'\', clients.firstname, \'{blank}\'),\')\'), \'\')), IF(clients.lastname != \'\' OR clients.firstname != \'\', CONCAT(if(clients.lastname != \'\', clients.lastname, \'{blank}\'),\', \',if(clients.firstname != \'\', clients.firstname, \'{blank}\')), \'\'))', 'clients.email', 'clients.type', 'clients.email', 'clients.inactive = 0', NULL, '2', '2', 1, NOW(), 1, NOW());6 INSERT INTO `smartsearches` (` id`, `name`, `fromclause`, `valuefield`, `displayfield`, `secondaryfield`, `classfield`, `searchfields`, `filterclause`, `rolefield`, `tabledefid`, `moduleid`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('8', 'Pick Client By Phone', 'clients', 'clients.id', 'IF(clients.company != \'\', CONCAT(clients.company,IF(clients.lastname != \'\' OR clients.firstname != \'\', CONCAT(\' (\',if(clients.lastname != \'\', clients.lastname, \'{blank}\'),\', \',if(clients.firstname != \'\', clients.firstname, \'{blank}\'),\')\'), \'\')), IF(clients.lastname != \'\' OR clients.firstname != \'\', CONCAT(if(clients.lastname != \'\', clients.lastname, \'{blank}\'),\', \',if(clients.firstname != \'\', clients.firstname, \'{blank}\')), \'\'))', 'CONCAT(IF(clients.workphone != \'\',CONCAT(clients.workphone,\' (w)[br]\'),\'\'),IF(clients.homephone != \'\',CONCAT(clients.homephone,\' (h)[br]\'),\'\'),IF(clients.mobilephone != \'\',CONCAT(clients.mobilephone,\' (m)[br]\'),\'\'),IF(clients.otherphone != \'\',CONCAT(clients.otherphone,\' (o)[br]\'),\'\'),IF(clients.fax != \'\',CONCAT(clients.fax,\' (fax)\'),\'\'))', 'clients.type', 'clients.workphone, clients.homephone, clients.mobilephone, clients.otherphone, clients.fax', 'clients.inactive = 0', NULL, '2', '2', 1, NOW(), 1, NOW());7 INSERT INTO `smartsearches` (` id`, `name`, `fromclause`, `valuefield`, `displayfield`, `secondaryfield`, `classfield`, `searchfields`, `filterclause`, `rolefield`, `tabledefid`, `moduleid`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('10', 'Pick Product Category For Product', 'productcategories', 'productcategories.id', 'productcategories.name', '\'\'', '\'\'', 'productcategories.name', 'productcategories.inactive = 0', '\'\'', '7', '2', 1, NOW(), 1, NOW());1 INSERT INTO `smartsearches` (`uuid`, `name`, `fromclause`, `valuefield`, `displayfield`, `secondaryfield`, `classfield`, `searchfields`, `filterclause`, `rolefield`, `tabledefid`, `moduleid`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('smrt:5cf171f7-2284-1492-62bb-872bc222eaef', 'Pick Exisiting Client Address', '(clients INNER JOIN addresstorecord ON clients.id = addresstorecord.recordid AND addresstorecord.tabledefid = 2) INNER JOIN addresses ON addresstorecord.addressid = addresses.id', 'addresses.id', 'concat(if(clients.lastname!=\"\",concat(clients.lastname,\", \",clients.firstname,if(clients.company!=\"\",concat(\" (\",clients.company,\")\"),\"\")),clients.company), if(addresses.title != \"\",concat(\" [\", addresses.title, \"]\"),\"\"))', 'CONCAT(addresses.address1,if(addresses.address2 != \'\',concat(\'[br]\', addresses.address2),\'\'),if(addresses.city != \'\',concat(\'[br]\',addresses.city,\', \',if(addresses.state != \'\',addresses.state, \'\'),\' \',if(addresses.postalcode != \'\', addresses.postalcode, \'\')),\'\'),if(addresses.country != \'\',concat(\'[br]\',addresses.country),\'\'))', 'if(addresstorecord.primary,\'primary\',\'\')', 'clients.firstname, clients.lastname, clients.company, addresses.title, addresses.address1', 'clients.inactive=0', NULL, '306', '2', 1, NOW(), 1, NOW()); 2 INSERT INTO `smartsearches` (`uuid`, `name`, `fromclause`, `valuefield`, `displayfield`, `secondaryfield`, `classfield`, `searchfields`, `filterclause`, `rolefield`, `tabledefid`, `moduleid`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('smrt:1b16f1e8-edf2-332e-e61b-3759f7020d41', 'Pick Sales Order Client', '((clients INNER JOIN addresstorecord on clients.id = addresstorecord.recordid AND addresstorecord.tabledefid=2 AND addresstorecord.primary=1) INNER JOIN addresses ON addresstorecord.addressid = addresses.id)', 'clients.id', 'IF(clients.company != \'\', CONCAT(clients.company,IF(clients.lastname != \'\' OR clients.firstname != \'\', CONCAT(\' (\',if(clients.lastname != \'\', clients.lastname, \'{blank}\'),\', \',if(clients.firstname != \'\', clients.firstname, \'{blank}\'),\')\'), \'\')), IF(clients.lastname != \'\' OR clients.firstname != \'\', CONCAT(if(clients.lastname != \'\', clients.lastname, \'{blank}\'),\', \',if(clients.firstname != \'\', clients.firstname, \'{blank}\')), \'\'))', 'IF(addresses.city != \'\' OR addresses.state !=\'\' OR addresses.postalcode != \'\', CONCAT(IF(addresses.city != \'\',addresses.city,\'\'),\', \',IF(addresses.state != \'\', addresses.state, \'\'),\' \',IF(addresses.postalcode != \'\', addresses.postalcode, \'\')),\'unspecified location\')', 'clients.type', 'clients.company, clients.firstname, clients.lastname', 'clients.inactive=0', NULL, '2', '2', 1, NOW(), 1, NOW()); 3 INSERT INTO `smartsearches` (`uuid`, `name`, `fromclause`, `valuefield`, `displayfield`, `secondaryfield`, `classfield`, `searchfields`, `filterclause`, `rolefield`, `tabledefid`, `moduleid`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('smrt:5634f7fb-a0c8-7e10-4c96-8bb043e7f478', 'Pick Product', 'products', 'products.id', 'CONCAT(products.partnumber,IF(products.partname != \'\',CONCAT(\' :: \',products.partname),\'\'))', 'products.type', '\'\'', 'products.partnumber, products.partname', 'products.inactive = 0 AND products.status = \'In Stock\'', NULL, '4', '2', 1, NOW(), 1, NOW()); 4 INSERT INTO `smartsearches` (`uuid`, `name`, `fromclause`, `valuefield`, `displayfield`, `secondaryfield`, `classfield`, `searchfields`, `filterclause`, `rolefield`, `tabledefid`, `moduleid`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('smrt:32f76377-1822-17f5-674c-118b678378d4', 'Pick Client With Credit', '((clients INNER JOIN addresstorecord on clients.id = addresstorecord.recordid AND addresstorecord.tabledefid=2 AND addresstorecord.primary=1) INNER JOIN addresses ON addresstorecord.addressid = addresses.id)', 'clients.id', 'IF(clients.company != \'\', CONCAT(clients.company,IF(clients.lastname != \'\' OR clients.firstname != \'\', CONCAT(\' (\',if(clients.lastname != \'\', clients.lastname, \'{blank}\'),\', \',if(clients.firstname != \'\', clients.firstname, \'{blank}\'),\')\'), \'\')), IF(clients.lastname != \'\' OR clients.firstname != \'\', CONCAT(if(clients.lastname != \'\', clients.lastname, \'{blank}\'),\', \',if(clients.firstname != \'\', clients.firstname, \'{blank}\')), \'\'))', 'IF(addresses.city != \'\' OR addresses.state !=\'\' OR addresses.postalcode != \'\', CONCAT(IF(addresses.city != \'\',addresses.city,\'\'),\', \',IF(addresses.state != \'\', addresses.state, \'\'),\' \',IF(addresses.postalcode != \'\', addresses.postalcode, \'\')),\'unspecified location\')', '\'\'', 'clients.company, clients.firstname, clients.lastname', 'clients.inactive = 0 AND clients.type=\'client\' AND clients.hascredit=1', NULL, '2', '2', 1, NOW(), 1, NOW()); 5 INSERT INTO `smartsearches` (`uuid`, `name`, `fromclause`, `valuefield`, `displayfield`, `secondaryfield`, `classfield`, `searchfields`, `filterclause`, `rolefield`, `tabledefid`, `moduleid`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('smrt:a18ca9d4-58aa-7a47-faa7-1ad0ed5ba8c6', 'Pick Client By Email', 'clients', 'clients.id', 'IF(clients.company != \'\', CONCAT(clients.company,IF(clients.lastname != \'\' OR clients.firstname != \'\', CONCAT(\' (\',if(clients.lastname != \'\', clients.lastname, \'{blank}\'),\', \',if(clients.firstname != \'\', clients.firstname, \'{blank}\'),\')\'), \'\')), IF(clients.lastname != \'\' OR clients.firstname != \'\', CONCAT(if(clients.lastname != \'\', clients.lastname, \'{blank}\'),\', \',if(clients.firstname != \'\', clients.firstname, \'{blank}\')), \'\'))', 'clients.email', 'clients.type', 'clients.email', 'clients.inactive = 0', NULL, '2', '2', 1, NOW(), 1, NOW()); 6 INSERT INTO `smartsearches` (`uuid`, `name`, `fromclause`, `valuefield`, `displayfield`, `secondaryfield`, `classfield`, `searchfields`, `filterclause`, `rolefield`, `tabledefid`, `moduleid`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('smrt:3b48afbf-f18f-a18d-8aa8-f51f27008750', 'Pick Client By Phone', 'clients', 'clients.id', 'IF(clients.company != \'\', CONCAT(clients.company,IF(clients.lastname != \'\' OR clients.firstname != \'\', CONCAT(\' (\',if(clients.lastname != \'\', clients.lastname, \'{blank}\'),\', \',if(clients.firstname != \'\', clients.firstname, \'{blank}\'),\')\'), \'\')), IF(clients.lastname != \'\' OR clients.firstname != \'\', CONCAT(if(clients.lastname != \'\', clients.lastname, \'{blank}\'),\', \',if(clients.firstname != \'\', clients.firstname, \'{blank}\')), \'\'))', 'CONCAT(IF(clients.workphone != \'\',CONCAT(clients.workphone,\' (w)[br]\'),\'\'),IF(clients.homephone != \'\',CONCAT(clients.homephone,\' (h)[br]\'),\'\'),IF(clients.mobilephone != \'\',CONCAT(clients.mobilephone,\' (m)[br]\'),\'\'),IF(clients.otherphone != \'\',CONCAT(clients.otherphone,\' (o)[br]\'),\'\'),IF(clients.fax != \'\',CONCAT(clients.fax,\' (fax)\'),\'\'))', 'clients.type', 'clients.workphone, clients.homephone, clients.mobilephone, clients.otherphone, clients.fax', 'clients.inactive = 0', NULL, '2', '2', 1, NOW(), 1, NOW()); 7 INSERT INTO `smartsearches` (`uuid`, `name`, `fromclause`, `valuefield`, `displayfield`, `secondaryfield`, `classfield`, `searchfields`, `filterclause`, `rolefield`, `tabledefid`, `moduleid`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('smrt:eed8c810-f9c8-077b-4b3e-9aef451f8057 ', 'Pick Product Category For Product', 'productcategories', 'productcategories.id', 'productcategories.name', '\'\'', '\'\'', 'productcategories.name', 'productcategories.inactive = 0', '\'\'', '7', '2', 1, NOW(), 1, NOW()); -
trunk/phpbms/modules/bms/install/tabledefs.sql
r524 r542 1 INSERT INTO `tabledefs` (`id`, ` displayname`, `type`, `moduleid`, `maintable`, `querytable`, `editfile`, `editroleid`, `addfile`, `addroleid`, `importfile`, `importroleid`, `searchroleid`, `advsearchroleid`, `viewsqlroleid`, `deletebutton`, `canpost`, `hascustomfields`, `defaultwhereclause`, `defaultsortorder`, `defaultsearchtype`, `defaultcriteriafindoptions`, `defaultcriteriaselection`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('2', 'Clients', 'table', '2', 'clients', '((clients INNER JOIN addresstorecord on clients.id = addresstorecord.recordid AND addresstorecord.tabledefid=2 AND addresstorecord.primary=1) INNER JOIN addresses ON addresstorecord.addressid = addresses.id)', 'modules/bms/clients_addedit.php', '0', 'modules/bms/clients_addedit.php', '0', 'modules/bms/clients_import.php', '-100', '0', '-100', '-100', 'inactivate', '0', '1', 'clients.id=-100', 'clients.company, clients.lastname, clients.firstname', NULL, NULL, NULL, 1, NOW(), 1, NOW());2 INSERT INTO `tabledefs` (`id`, ` displayname`, `type`, `moduleid`, `maintable`, `querytable`, `editfile`, `editroleid`, `addfile`, `addroleid`, `importfile`, `importroleid`, `searchroleid`, `advsearchroleid`, `viewsqlroleid`, `deletebutton`, `canpost`, `hascustomfields`, `defaultwhereclause`, `defaultsortorder`, `defaultsearchtype`, `defaultcriteriafindoptions`, `defaultcriteriaselection`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('3', 'Sales Orders', 'table', '2', 'invoices', '(((invoices INNER JOIN clients ON invoices.clientid=clients.id) INNER JOIN invoicestatuses ON invoices.statusid=invoicestatuses.id) LEFT JOIN paymentmethods ON invoices.paymentmethodid = paymentmethods.id)', 'modules/bms/invoices_addedit.php', '0', 'modules/bms/invoices_addedit.php', '0', NULL, '-100', '0', '-100', '-100', 'void', '1', '1', 'invoices.type+0<3 OR (invoices.type = \'Invoice\' AND invoices.totalti != invoices.amountpaid)', 'invoices.id', NULL, NULL, NULL, 1, NOW(), 1, NOW());3 INSERT INTO `tabledefs` (`id`, ` displayname`, `type`, `moduleid`, `maintable`, `querytable`, `editfile`, `editroleid`, `addfile`, `addroleid`, `importfile`, `importroleid`, `searchroleid`, `advsearchroleid`, `viewsqlroleid`, `deletebutton`, `canpost`, `hascustomfields`, `defaultwhereclause`, `defaultsortorder`, `defaultsearchtype`, `defaultcriteriafindoptions`, `defaultcriteriaselection`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('4', 'Products', 'table', '2', 'products', '(products LEFT JOIN productcategories ON products.categoryid =productcategories.id)', 'modules/bms/products_addedit.php', '0', 'modules/bms/products_addedit.php', '0', '', '-100', '0', '-100', '-100', 'inactivate', '0', '1', 'products.id =-100', 'products.partnumber', NULL, NULL, NULL, 1, NOW(), 1, NOW());4 INSERT INTO `tabledefs` (`id`, ` displayname`, `type`, `moduleid`, `maintable`, `querytable`, `editfile`, `editroleid`, `addfile`, `addroleid`, `importfile`, `importroleid`, `searchroleid`, `advsearchroleid`, `viewsqlroleid`, `deletebutton`, `canpost`, `hascustomfields`, `defaultwhereclause`, `defaultsortorder`, `defaultsearchtype`, `defaultcriteriafindoptions`, `defaultcriteriaselection`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('5', 'Line Items', 'table', '2', 'lineitems', '((lineitems left join products on lineitems.productid=products.id) inner join invoices on lineitems.invoiceid=invoices.id)', 'N/A', '0', 'N/A', '0', NULL, '-100', '0', '-100', '-100', 'NA', '0', '1', 'lineitems.id =-1', 'lineitems.invoiceid,lineitems.id', '', '', '', 1, NOW(), 1, NOW());5 INSERT INTO `tabledefs` (`id`, ` displayname`, `type`, `moduleid`, `maintable`, `querytable`, `editfile`, `editroleid`, `addfile`, `addroleid`, `importfile`, `importroleid`, `searchroleid`, `advsearchroleid`, `viewsqlroleid`, `deletebutton`, `canpost`, `hascustomfields`, `defaultwhereclause`, `defaultsortorder`, `defaultsearchtype`, `defaultcriteriafindoptions`, `defaultcriteriaselection`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('6', 'Tax Areas', 'table', '2', 'tax', 'tax', 'modules/bms/tax_addedit.php', '0', 'modules/bms/tax_addedit.php', '0', NULL, '-100', '0', '-100', '-100', 'inactivate', '0', '1', 'tax.inactive=0', 'tax.name', NULL, NULL, NULL, 1, NOW(), 1, NOW());6 INSERT INTO `tabledefs` (`id`, ` displayname`, `type`, `moduleid`, `maintable`, `querytable`, `editfile`, `editroleid`, `addfile`, `addroleid`, `importfile`, `importroleid`, `searchroleid`, `advsearchroleid`, `viewsqlroleid`, `deletebutton`, `canpost`, `hascustomfields`, `defaultwhereclause`, `defaultsortorder`, `defaultsearchtype`, `defaultcriteriafindoptions`, `defaultcriteriaselection`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('7', 'Product Categories', 'table', '2', 'productcategories', '(productcategories LEFT JOIN productcategories AS `parents` ON productcategories.parentid = parents.id)', 'modules/bms/productcategories_addedit.php', '0', 'modules/bms/productcategories_addedit.php', '0', NULL, '-100', '0', '-100', '-100', 'inactivate', '0', '1', 'productcategories.id !=0', 'productcategories.name', NULL, NULL, NULL, 1, NOW(), 1, NOW());7 INSERT INTO `tabledefs` (`id`, ` displayname`, `type`, `moduleid`, `maintable`, `querytable`, `editfile`, `editroleid`, `addfile`, `addroleid`, `importfile`, `importroleid`, `searchroleid`, `advsearchroleid`, `viewsqlroleid`, `deletebutton`, `canpost`, `hascustomfields`, `defaultwhereclause`, `defaultsortorder`, `defaultsearchtype`, `defaultcriteriafindoptions`, `defaultcriteriaselection`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('8', 'Prerequisites', 'table', '2', 'prerequisites', '(prerequisites left join products on prerequisites.parentid=products.id) left join products as childproducts on prerequisites.childid=childproducts.id', 'N/A', '0', 'N/A', '0', NULL, '-100', '0', '-100', '-100', 'NA', '0', '0', 'prerequisites.id =-1', 'products.id', '', '', '', 1, NOW(), 1, NOW());8 INSERT INTO `tabledefs` (`id`, ` displayname`, `type`, `moduleid`, `maintable`, `querytable`, `editfile`, `editroleid`, `addfile`, `addroleid`, `importfile`, `importroleid`, `searchroleid`, `advsearchroleid`, `viewsqlroleid`, `deletebutton`, `canpost`, `hascustomfields`, `defaultwhereclause`, `defaultsortorder`, `defaultsearchtype`, `defaultcriteriafindoptions`, `defaultcriteriaselection`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('18', 'Client Duplicates', 'view', '2', 'clients', '((clients INNER JOIN addresstorecord on clients.id = addresstorecord.recordid AND addresstorecord.tabledefid=2 AND addresstorecord.primary=1) INNER JOIN addresses ON addresstorecord.addressid = addresses.id),((clients AS dclients INNER JOIN addresstorecord as daddresstorecord on dclients.id = daddresstorecord.recordid AND daddresstorecord.tabledefid=2 AND daddresstorecord.primary=1) INNER JOIN addresses AS daddresses ON daddresstorecord.addressid = daddresses.id)', 'N/A', '0', 'N/A', '0', NULL, '-100', '0', '-100', '-100', 'NA', '0', '0', 'clients.id = -100', 'clients.company, clients.lastname, clients.firstname', NULL, NULL, NULL, 1, NOW(), 1, NOW());9 INSERT INTO `tabledefs` (`id`, ` displayname`, `type`, `moduleid`, `maintable`, `querytable`, `editfile`, `editroleid`, `addfile`, `addroleid`, `importfile`, `importroleid`, `searchroleid`, `advsearchroleid`, `viewsqlroleid`, `deletebutton`, `canpost`, `hascustomfields`, `defaultwhereclause`, `defaultsortorder`, `defaultsearchtype`, `defaultcriteriafindoptions`, `defaultcriteriaselection`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('22', 'Client E-mail Projects', 'system', '2', 'clientemailprojects', 'clientemailprojects left join users on clientemailprojects.userid=users.id', 'modules/bms/clientemailprojects_edit.php', '0', 'NA', '0', NULL, '-100', '0', '-100', '-100', 'delete', '0', '0', 'clientemailprojects.id !=-1', 'clientemailprojects.name', 'search', '', '', 1, NOW(), 1, NOW());10 INSERT INTO `tabledefs` (`id`, ` displayname`, `type`, `moduleid`, `maintable`, `querytable`, `editfile`, `editroleid`, `addfile`, `addroleid`, `importfile`, `importroleid`, `searchroleid`, `advsearchroleid`, `viewsqlroleid`, `deletebutton`, `canpost`, `hascustomfields`, `defaultwhereclause`, `defaultsortorder`, `defaultsearchtype`, `defaultcriteriafindoptions`, `defaultcriteriaselection`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('25', 'Discounts', 'table', '2', 'discounts', 'discounts', 'modules/bms/discounts_addedit.php', '0', 'modules/bms/discounts_addedit.php', '0', NULL, '-100', '0', '-100', '-100', 'inactivate', '0', '1', 'discounts.inactive=0', 'discounts.id', 'search', 'active records', 'name', 1, NOW(), 1, NOW());11 INSERT INTO `tabledefs` (`id`, ` displayname`, `type`, `moduleid`, `maintable`, `querytable`, `editfile`, `editroleid`, `addfile`, `addroleid`, `importfile`, `importroleid`, `searchroleid`, `advsearchroleid`, `viewsqlroleid`, `deletebutton`, `canpost`, `hascustomfields`, `defaultwhereclause`, `defaultsortorder`, `defaultsearchtype`, `defaultcriteriafindoptions`, `defaultcriteriaselection`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('300', 'Shipping Methods', 'table', '2', 'shippingmethods', 'shippingmethods', 'modules/bms/shippingmethods_addedit.php', '30', 'modules/bms/shippingmethods_addedit.php', '30', NULL, '-100', '30', '30', '-100', 'inactivate', '0', '1', 'shippingmethods.inactive!=0', 'shippingmethods.priority, shippingmethods.name', '', '', '', 1, NOW(), 1, NOW());12 INSERT INTO `tabledefs` (`id`, ` displayname`, `type`, `moduleid`, `maintable`, `querytable`, `editfile`, `editroleid`, `addfile`, `addroleid`, `importfile`, `importroleid`, `searchroleid`, `advsearchroleid`, `viewsqlroleid`, `deletebutton`, `canpost`, `hascustomfields`, `defaultwhereclause`, `defaultsortorder`, `defaultsearchtype`, `defaultcriteriafindoptions`, `defaultcriteriaselection`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('301', 'Payment Methods', 'table', '2', 'paymentmethods', 'paymentmethods', 'modules/bms/paymentmethods_addedit.php', '30', 'modules/bms/paymentmethods_addedit.php', '30', NULL, '-100', '30', '30', '-100', 'inactivate', '0', '0', 'paymentmethods.inactive=0', 'paymentmethods.priority,paymentmethods.name', '', '', '', 1, NOW(), 1, NOW());13 INSERT INTO `tabledefs` (`id`, ` displayname`, `type`, `moduleid`, `maintable`, `querytable`, `editfile`, `editroleid`, `addfile`, `addroleid`, `importfile`, `importroleid`, `searchroleid`, `advsearchroleid`, `viewsqlroleid`, `deletebutton`, `canpost`, `hascustomfields`, `defaultwhereclause`, `defaultsortorder`, `defaultsearchtype`, `defaultcriteriafindoptions`, `defaultcriteriaselection`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('302', 'Invoice Statuses', 'table', '2', 'invoicestatuses', 'invoicestatuses', 'modules/bms/invoicestatuses_addedit.php', '30', 'modules/bms/invoicestatuses_addedit.php', '30', NULL, '-100', '30', '-100', '-100', 'inactivate', '0', '1', 'invoicestatuses.inactive=0', 'invoicestatuses.priority,invoicestatuses.name', '', '', '', 1, NOW(), 1, NOW());14 INSERT INTO `tabledefs` (`id`, ` displayname`, `type`, `moduleid`, `maintable`, `querytable`, `editfile`, `editroleid`, `addfile`, `addroleid`, `importfile`, `importroleid`, `searchroleid`, `advsearchroleid`, `viewsqlroleid`, `deletebutton`, `canpost`, `hascustomfields`, `defaultwhereclause`, `defaultsortorder`, `defaultsearchtype`, `defaultcriteriafindoptions`, `defaultcriteriaselection`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('303', 'AR Items', 'table', '2', 'aritems', '(aritems INNER JOIN clients ON aritems.clientid = clients.id)', 'modules/bms/aritems_view.php', '0', 'NA', '0', NULL, '-100', '0', '-100', '-100', 'NA', '0', '0', 'aritems.posted=1 AND aritems.status = \'open\'', 'aritems.itemdate, aritems.status, aritems.id', NULL, NULL, NULL, 1, NOW(), 1, NOW());15 INSERT INTO `tabledefs` (`id`, ` displayname`, `type`, `moduleid`, `maintable`, `querytable`, `editfile`, `editroleid`, `addfile`, `addroleid`, `importfile`, `importroleid`, `searchroleid`, `advsearchroleid`, `viewsqlroleid`, `deletebutton`, `canpost`, `hascustomfields`, `defaultwhereclause`, `defaultsortorder`, `defaultsearchtype`, `defaultcriteriafindoptions`, `defaultcriteriaselection`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('304', 'Receipts', 'table', '2', 'receipts', '((receipts INNER JOIN clients ON receipts.clientid = clients.id) LEFT JOIN paymentmethods ON receipts.paymentmethodid = paymentmethods.id)', 'modules/bms/receipts_addedit.php', '80', 'modules/bms/receipts_addedit.php', '80', NULL, '-100', '80', '-100', '-100', 'delete', '1', '1', 'receipts.posted=0', 'receipts.receiptdate', NULL, NULL, NULL, 1, NOW(), 1, NOW());16 INSERT INTO `tabledefs` (`id`, ` displayname`, `type`, `moduleid`, `maintable`, `querytable`, `editfile`, `editroleid`, `addfile`, `addroleid`, `importfile`, `importroleid`, `searchroleid`, `advsearchroleid`, `viewsqlroleid`, `deletebutton`, `canpost`, `hascustomfields`, `defaultwhereclause`, `defaultsortorder`, `defaultsearchtype`, `defaultcriteriafindoptions`, `defaultcriteriaselection`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('305', 'Client Addresses', 'view', '2', 'addresstorecord', '((addresstorecord INNER JOIN addresses ON addresstorecord.addressid = addresses.id) INNER JOIN clients ON addresstorecord.recordid = clients.id)', 'modules/bms/addresses_addedit.php', '0', 'modules/bms/addresses_addedit.php', '0', NULL, '-100', '0', '-100', '-100', 'remove', '0', '0', 'addresstorecord.tabledefid=2 AND addresstorecord.id = -100', 'addresstorecord.primary DESC, addresstorecord.defaultshipto DESC, addresses.title, addresses.address1', NULL, NULL, NULL, 1, NOW(), 1, NOW());17 INSERT INTO `tabledefs` (`id`, ` displayname`, `type`, `moduleid`, `maintable`, `querytable`, `editfile`, `editroleid`, `addfile`, `addroleid`, `importfile`, `importroleid`, `searchroleid`, `advsearchroleid`, `viewsqlroleid`, `deletebutton`, `canpost`, `hascustomfields`, `defaultwhereclause`, `defaultsortorder`, `defaultsearchtype`, `defaultcriteriafindoptions`, `defaultcriteriaselection`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('306', 'Addresses', 'table', '2', 'addresses', 'addresses', 'modules/bms/addresses_addedit.php', '0', 'modules/bms/addresses_addedit.php', '0', NULL, '-100', '0', '-100', '-100', 'delete', '0', '1', 'addresses.id != -100', 'addresses.title DESC', NULL, NULL, NULL, 1, NOW(), 1, NOW());18 INSERT INTO `tabledefs` (`id`, ` displayname`, `type`, `moduleid`, `maintable`, `querytable`, `editfile`, `editroleid`, `addfile`, `addroleid`, `importfile`, `importroleid`, `searchroleid`, `advsearchroleid`, `viewsqlroleid`, `deletebutton`, `canpost`, `hascustomfields`, `defaultwhereclause`, `defaultsortorder`, `defaultsearchtype`, `defaultcriteriafindoptions`, `defaultcriteriaselection`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('307', 'Posting Sessions', 'table', '2', 'postingsessions', '(postingsessions INNER JOIN users ON postingsessions.userid = users.id)', 'N/A', '0', 'N/A', '0', NULL, '-100', '50', '-100', '-100', 'NA', '0', '0', 'YEAR(postingsessions.sessiondate) = YEAR(NOW()) AND MONTH(postingsessions.sessiondate) = MONTH(NOW())', 'postingsessions.sessiondate DESC', NULL, NULL, NULL, 1, NOW(), 1, NOW());1 INSERT INTO `tabledefs` (`id`, `uuid`, `displayname`, `type`, `moduleid`, `maintable`, `querytable`, `editfile`, `editroleid`, `addfile`, `addroleid`, `importfile`, `importroleid`, `searchroleid`, `advsearchroleid`, `viewsqlroleid`, `deletebutton`, `canpost`, `hascustomfields`, `defaultwhereclause`, `defaultsortorder`, `defaultsearchtype`, `defaultcriteriafindoptions`, `defaultcriteriaselection`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('2', 'tbld:6d290174-8b73-e199-fe6c-bcf3d4b61083', 'Clients', 'table', '2', 'clients', '((clients INNER JOIN addresstorecord on clients.id = addresstorecord.recordid AND addresstorecord.tabledefid=2 AND addresstorecord.primary=1) INNER JOIN addresses ON addresstorecord.addressid = addresses.id)', 'modules/bms/clients_addedit.php', '0', 'modules/bms/clients_addedit.php', '0', 'modules/bms/clients_import.php', '-100', '0', '-100', '-100', 'inactivate', '0', '1', 'clients.id=-100', 'clients.company, clients.lastname, clients.firstname', NULL, NULL, NULL, 1, NOW(), 1, NOW()); 2 INSERT INTO `tabledefs` (`id`, `uuid`, `displayname`, `type`, `moduleid`, `maintable`, `querytable`, `editfile`, `editroleid`, `addfile`, `addroleid`, `importfile`, `importroleid`, `searchroleid`, `advsearchroleid`, `viewsqlroleid`, `deletebutton`, `canpost`, `hascustomfields`, `defaultwhereclause`, `defaultsortorder`, `defaultsearchtype`, `defaultcriteriafindoptions`, `defaultcriteriaselection`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('3', 'tbld:62fe599d-c18f-3674-9e54-b62c2d6b1883', 'Sales Orders', 'table', '2', 'invoices', '(((invoices INNER JOIN clients ON invoices.clientid=clients.id) INNER JOIN invoicestatuses ON invoices.statusid=invoicestatuses.id) LEFT JOIN paymentmethods ON invoices.paymentmethodid = paymentmethods.id)', 'modules/bms/invoices_addedit.php', '0', 'modules/bms/invoices_addedit.php', '0', NULL, '-100', '0', '-100', '-100', 'void', '1', '1', 'invoices.type+0<3 OR (invoices.type = \'Invoice\' AND invoices.totalti != invoices.amountpaid)', 'invoices.id', NULL, NULL, NULL, 1, NOW(), 1, NOW()); 3 INSERT INTO `tabledefs` (`id`, `uuid`, `displayname`, `type`, `moduleid`, `maintable`, `querytable`, `editfile`, `editroleid`, `addfile`, `addroleid`, `importfile`, `importroleid`, `searchroleid`, `advsearchroleid`, `viewsqlroleid`, `deletebutton`, `canpost`, `hascustomfields`, `defaultwhereclause`, `defaultsortorder`, `defaultsearchtype`, `defaultcriteriafindoptions`, `defaultcriteriaselection`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('4', 'tbld:7a9e87ed-d165-c4a4-d9b9-0a4adc3c5a34', 'Products', 'table', '2', 'products', '(products inner join productcategories on products.categoryid=productcategories.id)', 'modules/bms/products_addedit.php', '0', 'modules/bms/products_addedit.php', '0', '', '-100', '0', '-100', '-100', 'inactivate', '0', '1', 'products.id =-100', 'products.partnumber', NULL, NULL, NULL, 1, NOW(), 1, NOW()); 4 INSERT INTO `tabledefs` (`id`, `uuid`, `displayname`, `type`, `moduleid`, `maintable`, `querytable`, `editfile`, `editroleid`, `addfile`, `addroleid`, `importfile`, `importroleid`, `searchroleid`, `advsearchroleid`, `viewsqlroleid`, `deletebutton`, `canpost`, `hascustomfields`, `defaultwhereclause`, `defaultsortorder`, `defaultsearchtype`, `defaultcriteriafindoptions`, `defaultcriteriaselection`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('5', 'tbld:31423480-a9b0-f0ff-749e-b3b5e18ca93c', 'Line Items', 'table', '2', 'lineitems', '((lineitems left join products on lineitems.productid=products.id) inner join invoices on lineitems.invoiceid=invoices.id)', 'N/A', '0', 'N/A', '0', NULL, '-100', '0', '-100', '-100', 'NA', '0', '1', 'lineitems.id =-1', 'lineitems.invoiceid,lineitems.id', '', '', '', 1, NOW(), 1, NOW()); 5 INSERT INTO `tabledefs` (`id`, `uuid`, `displayname`, `type`, `moduleid`, `maintable`, `querytable`, `editfile`, `editroleid`, `addfile`, `addroleid`, `importfile`, `importroleid`, `searchroleid`, `advsearchroleid`, `viewsqlroleid`, `deletebutton`, `canpost`, `hascustomfields`, `defaultwhereclause`, `defaultsortorder`, `defaultsearchtype`, `defaultcriteriafindoptions`, `defaultcriteriaselection`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('6', 'tbld:c9ff2c8c-ce1f-659a-9c55-31bca7cce70e', 'Tax Areas', 'table', '2', 'tax', 'tax', 'modules/bms/tax_addedit.php', '0', 'modules/bms/tax_addedit.php', '0', NULL, '-100', '0', '-100', '-100', 'inactivate', '0', '1', 'tax.inactive=0', 'tax.name', NULL, NULL, NULL, 1, NOW(), 1, NOW()); 6 INSERT INTO `tabledefs` (`id`, `uuid`, `displayname`, `type`, `moduleid`, `maintable`, `querytable`, `editfile`, `editroleid`, `addfile`, `addroleid`, `importfile`, `importroleid`, `searchroleid`, `advsearchroleid`, `viewsqlroleid`, `deletebutton`, `canpost`, `hascustomfields`, `defaultwhereclause`, `defaultsortorder`, `defaultsearchtype`, `defaultcriteriafindoptions`, `defaultcriteriaselection`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('7', 'tbld:3342a3d4-c6a2-3a38-6576-419299859561', 'Product Categories', 'table', '2', 'productcategories', 'productcategories', 'modules/bms/productcategories_addedit.php', '0', 'modules/bms/productcategories_addedit.php', '0', NULL, '-100', '0', '-100', '-100', 'inactivate', '0', '1', 'productcategories.id !=0', 'productcategories.name', NULL, NULL, NULL, 1, NOW(), 1, NOW()); 7 INSERT INTO `tabledefs` (`id`, `uuid`, `displayname`, `type`, `moduleid`, `maintable`, `querytable`, `editfile`, `editroleid`, `addfile`, `addroleid`, `importfile`, `importroleid`, `searchroleid`, `advsearchroleid`, `viewsqlroleid`, `deletebutton`, `canpost`, `hascustomfields`, `defaultwhereclause`, `defaultsortorder`, `defaultsearchtype`, `defaultcriteriafindoptions`, `defaultcriteriaselection`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('8', 'tbld:8179e105-5487-5173-d835-d9d510cc7f1b', 'Prerequisites', 'table', '2', 'prerequisites', '(prerequisites left join products on prerequisites.parentid=products.id) left join products as childproducts on prerequisites.childid=childproducts.id', 'N/A', '0', 'N/A', '0', NULL, '-100', '0', '-100', '-100', 'NA', '0', '0', 'prerequisites.id =-1', 'products.id', '', '', '', 1, NOW(), 1, NOW()); 8 INSERT INTO `tabledefs` (`id`, `uuid`, `displayname`, `type`, `moduleid`, `maintable`, `querytable`, `editfile`, `editroleid`, `addfile`, `addroleid`, `importfile`, `importroleid`, `searchroleid`, `advsearchroleid`, `viewsqlroleid`, `deletebutton`, `canpost`, `hascustomfields`, `defaultwhereclause`, `defaultsortorder`, `defaultsearchtype`, `defaultcriteriafindoptions`, `defaultcriteriaselection`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('18', 'tbld:f993cf23-ad4a-047b-e920-d45fee1dc08e', 'Client Duplicates', 'view', '2', 'clients', '((clients INNER JOIN addresstorecord on clients.id = addresstorecord.recordid AND addresstorecord.tabledefid=2 AND addresstorecord.primary=1) INNER JOIN addresses ON addresstorecord.addressid = addresses.id),((clients AS dclients INNER JOIN addresstorecord as daddresstorecord on dclients.id = daddresstorecord.recordid AND daddresstorecord.tabledefid=2 AND daddresstorecord.primary=1) INNER JOIN addresses AS daddresses ON daddresstorecord.addressid = daddresses.id)', 'N/A', '0', 'N/A', '0', NULL, '-100', '0', '-100', '-100', 'NA', '0', '0', 'clients.id = -100', 'clients.company, clients.lastname, clients.firstname', NULL, NULL, NULL, 1, NOW(), 1, NOW()); 9 INSERT INTO `tabledefs` (`id`, `uuid`, `displayname`, `type`, `moduleid`, `maintable`, `querytable`, `editfile`, `editroleid`, `addfile`, `addroleid`, `importfile`, `importroleid`, `searchroleid`, `advsearchroleid`, `viewsqlroleid`, `deletebutton`, `canpost`, `hascustomfields`, `defaultwhereclause`, `defaultsortorder`, `defaultsearchtype`, `defaultcriteriafindoptions`, `defaultcriteriaselection`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('22', 'tbld:157b7707-5503-4161-4dcf-6811f8b0322f', 'Client E-mail Projects', 'system', '2', 'clientemailprojects', 'clientemailprojects left join users on clientemailprojects.userid=users.id', 'modules/bms/clientemailprojects_edit.php', '0', 'NA', '0', NULL, '-100', '0', '-100', '-100', 'delete', '0', '0', 'clientemailprojects.id !=-1', 'clientemailprojects.name', 'search', '', '', 1, NOW(), 1, NOW()); 10 INSERT INTO `tabledefs` (`id`, `uuid`, `displayname`, `type`, `moduleid`, `maintable`, `querytable`, `editfile`, `editroleid`, `addfile`, `addroleid`, `importfile`, `importroleid`, `searchroleid`, `advsearchroleid`, `viewsqlroleid`, `deletebutton`, `canpost`, `hascustomfields`, `defaultwhereclause`, `defaultsortorder`, `defaultsearchtype`, `defaultcriteriafindoptions`, `defaultcriteriaselection`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('25', 'tbld:455b8839-162b-3fcb-64b6-eeb946f873e1', 'Discounts', 'table', '2', 'discounts', 'discounts', 'modules/bms/discounts_addedit.php', '0', 'modules/bms/discounts_addedit.php', '0', NULL, '-100', '0', '-100', '-100', 'inactivate', '0', '1', 'discounts.inactive=0', 'discounts.id', 'search', 'active records', 'name', 1, NOW(), 1, NOW()); 11 INSERT INTO `tabledefs` (`id`, `uuid`, `displayname`, `type`, `moduleid`, `maintable`, `querytable`, `editfile`, `editroleid`, `addfile`, `addroleid`, `importfile`, `importroleid`, `searchroleid`, `advsearchroleid`, `viewsqlroleid`, `deletebutton`, `canpost`, `hascustomfields`, `defaultwhereclause`, `defaultsortorder`, `defaultsearchtype`, `defaultcriteriafindoptions`, `defaultcriteriaselection`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('300', 'tbld:fa8a0ddc-87d3-a9e9-60b0-1bab374b2993', 'Shipping Methods', 'table', '2', 'shippingmethods', 'shippingmethods', 'modules/bms/shippingmethods_addedit.php', '30', 'modules/bms/shippingmethods_addedit.php', '30', NULL, '-100', '30', '30', '-100', 'inactivate', '0', '1', 'shippingmethods.inactive!=0', 'shippingmethods.priority, shippingmethods.name', '', '', '', 1, NOW(), 1, NOW()); 12 INSERT INTO `tabledefs` (`id`, `uuid`, `displayname`, `type`, `moduleid`, `maintable`, `querytable`, `editfile`, `editroleid`, `addfile`, `addroleid`, `importfile`, `importroleid`, `searchroleid`, `advsearchroleid`, `viewsqlroleid`, `deletebutton`, `canpost`, `hascustomfields`, `defaultwhereclause`, `defaultsortorder`, `defaultsearchtype`, `defaultcriteriafindoptions`, `defaultcriteriaselection`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('301', 'tbld:380d4efa-a825-f377-6fa1-a030b8c58ffe', 'Payment Methods', 'table', '2', 'paymentmethods', 'paymentmethods', 'modules/bms/paymentmethods_addedit.php', '30', 'modules/bms/paymentmethods_addedit.php', '30', NULL, '-100', '30', '30', '-100', 'inactivate', '0', '0', 'paymentmethods.inactive=0', 'paymentmethods.priority,paymentmethods.name', '', '', '', 1, NOW(), 1, NOW()); 13 INSERT INTO `tabledefs` (`id`, `uuid`, `displayname`, `type`, `moduleid`, `maintable`, `querytable`, `editfile`, `editroleid`, `addfile`, `addroleid`, `importfile`, `importroleid`, `searchroleid`, `advsearchroleid`, `viewsqlroleid`, `deletebutton`, `canpost`, `hascustomfields`, `defaultwhereclause`, `defaultsortorder`, `defaultsearchtype`, `defaultcriteriafindoptions`, `defaultcriteriaselection`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('302', 'tbld:d6e4e1fb-4bfa-cb53-ab9c-1b3e7f907ae2', 'Invoice Statuses', 'table', '2', 'invoicestatuses', 'invoicestatuses', 'modules/bms/invoicestatuses_addedit.php', '30', 'modules/bms/invoicestatuses_addedit.php', '30', NULL, '-100', '30', '-100', '-100', 'inactivate', '0', '1', 'invoicestatuses.inactive=0', 'invoicestatuses.priority,invoicestatuses.name', '', '', '', 1, NOW(), 1, NOW()); 14 INSERT INTO `tabledefs` (`id`, `uuid`, `displayname`, `type`, `moduleid`, `maintable`, `querytable`, `editfile`, `editroleid`, `addfile`, `addroleid`, `importfile`, `importroleid`, `searchroleid`, `advsearchroleid`, `viewsqlroleid`, `deletebutton`, `canpost`, `hascustomfields`, `defaultwhereclause`, `defaultsortorder`, `defaultsearchtype`, `defaultcriteriafindoptions`, `defaultcriteriaselection`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('303', 'tbld:c595dbe7-6c77-1e02-5e81-c2e215736e9c', 'AR Items', 'table', '2', 'aritems', '(aritems INNER JOIN clients ON aritems.clientid = clients.id)', 'modules/bms/aritems_view.php', '0', 'NA', '0', NULL, '-100', '0', '-100', '-100', 'NA', '0', '0', 'aritems.posted=1 AND aritems.status = \'open\'', 'aritems.itemdate, aritems.status, aritems.id', NULL, NULL, NULL, 1, NOW(), 1, NOW()); 15 INSERT INTO `tabledefs` (`id`, `uuid`, `displayname`, `type`, `moduleid`, `maintable`, `querytable`, `editfile`, `editroleid`, `addfile`, `addroleid`, `importfile`, `importroleid`, `searchroleid`, `advsearchroleid`, `viewsqlroleid`, `deletebutton`, `canpost`, `hascustomfields`, `defaultwhereclause`, `defaultsortorder`, `defaultsearchtype`, `defaultcriteriafindoptions`, `defaultcriteriaselection`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('304', 'tbld:43678406-be25-909b-c715-7e2afc7db601', 'Receipts', 'table', '2', 'receipts', '((receipts INNER JOIN clients ON receipts.clientid = clients.id) LEFT JOIN paymentmethods ON receipts.paymentmethodid = paymentmethods.id)', 'modules/bms/receipts_addedit.php', '80', 'modules/bms/receipts_addedit.php', '80', NULL, '-100', '80', '-100', '-100', 'delete', '1', '1', 'receipts.posted=0', 'receipts.receiptdate', NULL, NULL, NULL, 1, NOW(), 1, NOW()); 16 INSERT INTO `tabledefs` (`id`, `uuid`, `displayname`, `type`, `moduleid`, `maintable`, `querytable`, `editfile`, `editroleid`, `addfile`, `addroleid`, `importfile`, `importroleid`, `searchroleid`, `advsearchroleid`, `viewsqlroleid`, `deletebutton`, `canpost`, `hascustomfields`, `defaultwhereclause`, `defaultsortorder`, `defaultsearchtype`, `defaultcriteriafindoptions`, `defaultcriteriaselection`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('305', 'tbld:e3ce122f-7c43-cfca-fd32-11c663567a2a', 'Client Addresses', 'view', '2', 'addresstorecord', '((addresstorecord INNER JOIN addresses ON addresstorecord.addressid = addresses.id) INNER JOIN clients ON addresstorecord.recordid = clients.id)', 'modules/bms/addresses_addedit.php', '0', 'modules/bms/addresses_addedit.php', '0', NULL, '-100', '0', '-100', '-100', 'remove', '0', '0', 'addresstorecord.tabledefid=2 AND addresstorecord.id = -100', 'addresstorecord.primary DESC, addresstorecord.defaultshipto DESC, addresses.title, addresses.address1', NULL, NULL, NULL, 1, NOW(), 1, NOW()); 17 INSERT INTO `tabledefs` (`id`, `uuid`, `displayname`, `type`, `moduleid`, `maintable`, `querytable`, `editfile`, `editroleid`, `addfile`, `addroleid`, `importfile`, `importroleid`, `searchroleid`, `advsearchroleid`, `viewsqlroleid`, `deletebutton`, `canpost`, `hascustomfields`, `defaultwhereclause`, `defaultsortorder`, `defaultsearchtype`, `defaultcriteriafindoptions`, `defaultcriteriaselection`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('306', 'tbld:27b99bda-7bec-b152-8397-a3b09c74cb23', 'Addresses', 'table', '2', 'addresses', 'addresses', 'modules/bms/addresses_addedit.php', '0', 'modules/bms/addresses_addedit.php', '0', NULL, '-100', '0', '-100', '-100', 'delete', '0', '1', 'addresses.id != -100', 'addresses.title DESC', NULL, NULL, NULL, 1, NOW(), 1, NOW()); 18 INSERT INTO `tabledefs` (`id`, `uuid`, `displayname`, `type`, `moduleid`, `maintable`, `querytable`, `editfile`, `editroleid`, `addfile`, `addroleid`, `importfile`, `importroleid`, `searchroleid`, `advsearchroleid`, `viewsqlroleid`, `deletebutton`, `canpost`, `hascustomfields`, `defaultwhereclause`, `defaultsortorder`, `defaultsearchtype`, `defaultcriteriafindoptions`, `defaultcriteriaselection`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('307', 'tbld:97760a4f-1c1a-a108-d05f-5fc4ec59583c', 'Posting Sessions', 'table', '2', 'postingsessions', '(postingsessions INNER JOIN users ON postingsessions.userid = users.id)', 'N/A', '0', 'N/A', '0', NULL, '-100', '50', '-100', '-100', 'NA', '0', '0', 'YEAR(postingsessions.sessiondate) = YEAR(NOW()) AND MONTH(postingsessions.sessiondate) = MONTH(NOW())', 'postingsessions.sessiondate DESC', NULL, NULL, NULL, 1, NOW(), 1, NOW()); -
trunk/phpbms/modules/bms/install/tabs.sql
r384 r542 1 INSERT INTO `tabs` (`id`, ` name`, `tabgroup`, `location`, `displayorder`, `enableonnew`, `roleid`, `tooltip`, `notificationsql`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES (6,'general','clients entry','modules/bms/clients_addedit.php',10,1,10,'','',1,NOW(),1,NOW());2 INSERT INTO `tabs` (`id`, ` name`, `tabgroup`, `location`, `displayorder`, `enableonnew`, `roleid`, `tooltip`, `notificationsql`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES (300,'credit', 'clients entry', 'modules/bms/clients_credit.php', 15, 0, 0, 'Credit Limits/History', NULL, 1, NOW(), 1, NOW());3 INSERT INTO `tabs` (`id`, ` name`, `tabgroup`, `location`, `displayorder`, `enableonnew`, `roleid`, `tooltip`, `notificationsql`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES (7,'purchase history','clients entry','modules/bms/clients_purchasehistory.php',20,0,30,'','',1,NOW(),1,NOW());4 INSERT INTO `tabs` (`id`, ` name`, `tabgroup`, `location`, `displayorder`, `enableonnew`, `roleid`, `tooltip`, `notificationsql`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES (8,'attachments','clients entry','modules/bms/clients_attachments.php',30,0,10,'','SELECT count(id) AS theresult FROM attachments WHERE tabledefid=2 AND recordid={{id}}',1,NOW(),1,NOW());5 INSERT INTO `tabs` (`id`, ` name`, `tabgroup`, `location`, `displayorder`, `enableonnew`, `roleid`, `tooltip`, `notificationsql`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES (9,'notes/tasks/events','clients entry','modules/bms/clients_notes.php',40,0,10,'','SELECT count(id) AS theresult FROM notes WHERE attachedtabledefid=2 AND attachedid={{id}}',1,NOW(),1,NOW());6 INSERT INTO `tabs` (`id`, ` name`, `tabgroup`, `location`, `displayorder`, `enableonnew`, `roleid`, `tooltip`, `notificationsql`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES (10,'general','products entry','modules/bms/products_addedit.php',10,1,10,'','',1,NOW(),1,NOW());7 INSERT INTO `tabs` (`id`, ` name`, `tabgroup`, `location`, `displayorder`, `enableonnew`, `roleid`, `tooltip`, `notificationsql`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES (11,'prerequisites','products entry','modules/bms/products_prereq.php',20,0,10,'','SELECT count(id) FROM prerequisites WHERE childid={{id}}',1,NOW(),1,NOW());8 INSERT INTO `tabs` (`id`, ` name`, `tabgroup`, `location`, `displayorder`, `enableonnew`, `roleid`, `tooltip`, `notificationsql`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES (12,'sales history','products entry','modules/bms/products_saleshistory.php',30,0,30,'','',1,NOW(),1,NOW());9 INSERT INTO `tabs` (`id`, ` name`, `tabgroup`, `location`, `displayorder`, `enableonnew`, `roleid`, `tooltip`, `notificationsql`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES (13,'attachments','products entry','modules/bms/products_attachments.php',40,0,10,'','SELECT count(id) AS theresult FROM attachments WHERE tabledefid=4 AND recordid={{id}}',1,NOW(),1,NOW());10 INSERT INTO `tabs` (`id`, ` name`, `tabgroup`, `location`, `displayorder`, `enableonnew`, `roleid`, `tooltip`, `notificationsql`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES (14,'notes/tasks/events','products entry','modules/bms/products_notes.php',50,0,10,'','SELECT count(id) AS theresult FROM notes WHERE attachedtabledefid=4 AND attachedid={{id}}',1,NOW(),1,NOW());11 INSERT INTO `tabs` (`id`, ` name`, `tabgroup`, `location`, `displayorder`, `enableonnew`, `roleid`, `tooltip`, `notificationsql`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES (15,'general','invoices entry','modules/bms/invoices_addedit.php',10,1,10,'','',1,NOW(),1,NOW());12 INSERT INTO `tabs` (`id`, ` name`, `tabgroup`, `location`, `displayorder`, `enableonnew`, `roleid`, `tooltip`, `notificationsql`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES (16,'status history','invoices entry','modules/bms/invoices_statushistory.php',20,0,20,'','',1,NOW(),1,NOW());13 INSERT INTO `tabs` (`id`, ` name`, `tabgroup`, `location`, `displayorder`, `enableonnew`, `roleid`, `tooltip`, `notificationsql`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES (17,'attachments','invoices entry','modules/bms/invoices_attachments.php',30,0,10,'','SELECT count(id) AS theresult FROM attachments WHERE tabledefid=3 AND recordid={{id}}',1,NOW(),1,NOW());14 INSERT INTO `tabs` (`id`, ` name`, `tabgroup`, `location`, `displayorder`, `enableonnew`, `roleid`, `tooltip`, `notificationsql`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES (18,'notes/events/task','invoices entry','modules/bms/invoices_notes.php',40,0,10,'','SELECT count(id) AS theresult FROM notes WHERE attachedtabledefid=3 AND attachedid={{id}}',1,NOW(),1,NOW());15 INSERT INTO `tabs` (`id`, ` name`, `tabgroup`, `location`, `displayorder`, `enableonnew`, `roleid`, `tooltip`, `notificationsql`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('303', 'addresses', 'clients entry', 'modules/bms/clients_addresses.php', '12', '0', '0', NULL, NULL, 1, NOW(), 1, NOW());1 INSERT INTO `tabs` (`id`, `uuid`, `name`, `tabgroup`, `location`, `displayorder`, `enableonnew`, `roleid`, `tooltip`, `notificationsql`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('6', 'tab:becfca94-ae25-a42c-7909-247d5324e4b5', 'general', 'clients entry', 'modules/bms/clients_addedit.php', '10', '1', '10', '', '', 1, NOW(), 1, NOW()); 2 INSERT INTO `tabs` (`id`, `uuid`, `name`, `tabgroup`, `location`, `displayorder`, `enableonnew`, `roleid`, `tooltip`, `notificationsql`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('7', 'tab:ef895fc0-bbea-9bf5-47ac-4913c6dace13', 'purchase history', 'clients entry', 'modules/bms/clients_purchasehistory.php', '20', '0', '30', '', '', 1, NOW(), 1, NOW()); 3 INSERT INTO `tabs` (`id`, `uuid`, `name`, `tabgroup`, `location`, `displayorder`, `enableonnew`, `roleid`, `tooltip`, `notificationsql`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('8', 'tab:19e34181-65f0-bfcf-6e09-99d0575ebd74', 'attachments', 'clients entry', 'modules/bms/clients_attachments.php', '30', '0', '10', '', 'SELECT count(id) AS theresult FROM attachments WHERE tabledefid=2 AND recordid={{id}}', 1, NOW(), 1, NOW()); 4 INSERT INTO `tabs` (`id`, `uuid`, `name`, `tabgroup`, `location`, `displayorder`, `enableonnew`, `roleid`, `tooltip`, `notificationsql`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('9', 'tab:d8e888af-d147-98ae-6849-a159a7c9daae', 'notes/tasks/events', 'clients entry', 'modules/bms/clients_notes.php', '40', '0', '10', '', 'SELECT count(id) AS theresult FROM notes WHERE attachedtabledefid=2 AND attachedid={{id}}', 1, NOW(), 1, NOW()); 5 INSERT INTO `tabs` (`id`, `uuid`, `name`, `tabgroup`, `location`, `displayorder`, `enableonnew`, `roleid`, `tooltip`, `notificationsql`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('10', 'tab:17346362-261b-4d1d-fa77-99e84cfd9b8a', 'general', 'products entry', 'modules/bms/products_addedit.php', '10', '1', '10', '', '', 1, NOW(), 1, NOW()); 6 INSERT INTO `tabs` (`id`, `uuid`, `name`, `tabgroup`, `location`, `displayorder`, `enableonnew`, `roleid`, `tooltip`, `notificationsql`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('11', 'tab:9bfc7eea-5abb-f5d8-763f-f78fe499464d', 'prerequisites', 'products entry', 'modules/bms/products_prereq.php', '20', '0', '10', '', 'SELECT count(id) FROM prerequisites WHERE childid={{id}}', 1, NOW(), 1, NOW()); 7 INSERT INTO `tabs` (`id`, `uuid`, `name`, `tabgroup`, `location`, `displayorder`, `enableonnew`, `roleid`, `tooltip`, `notificationsql`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('12', 'tab:cd09d4a1-7d32-e08a-bd6e-5850bc9af88e', 'sales history', 'products entry', 'modules/bms/products_saleshistory.php', '30', '0', '30', '', '', 1, NOW(), 1, NOW()); 8 INSERT INTO `tabs` (`id`, `uuid`, `name`, `tabgroup`, `location`, `displayorder`, `enableonnew`, `roleid`, `tooltip`, `notificationsql`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('13', 'tab:4c853d8b-8895-a8c5-8ff6-1128e6e1a798', 'attachments', 'products entry', 'modules/bms/products_attachments.php', '40', '0', '10', '', 'SELECT count(id) AS theresult FROM attachments WHERE tabledefid=4 AND recordid={{id}}', 1, NOW(), 1, NOW()); 9 INSERT INTO `tabs` (`id`, `uuid`, `name`, `tabgroup`, `location`, `displayorder`, `enableonnew`, `roleid`, `tooltip`, `notificationsql`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('14', 'tab:d62cf7eb-fd2a-948a-6279-8a61d02390ae', 'notes/tasks/events', 'products entry', 'modules/bms/products_notes.php', '50', '0', '10', '', 'SELECT count(id) AS theresult FROM notes WHERE attachedtabledefid=4 AND attachedid={{id}}', 1, NOW(), 1, NOW()); 10 INSERT INTO `tabs` (`id`, `uuid`, `name`, `tabgroup`, `location`, `displayorder`, `enableonnew`, `roleid`, `tooltip`, `notificationsql`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('15', 'tab:20276b44-9cfa-403e-4c2a-ac6f0987ae20', 'general', 'invoices entry', 'modules/bms/invoices_addedit.php', '10', '1', '10', '', '', 1, NOW(), 1, NOW()); 11 INSERT INTO `tabs` (`id`, `uuid`, `name`, `tabgroup`, `location`, `displayorder`, `enableonnew`, `roleid`, `tooltip`, `notificationsql`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('16', 'tab:809d644e-fa40-5ad3-0426-3d84cf15b32e', 'status history', 'invoices entry', 'modules/bms/invoices_statushistory.php', '20', '0', '20', '', '', 1, NOW(), 1, NOW()); 12 INSERT INTO `tabs` (`id`, `uuid`, `name`, `tabgroup`, `location`, `displayorder`, `enableonnew`, `roleid`, `tooltip`, `notificationsql`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('17', 'tab:23687374-5c14-04af-74ac-0f74342e1019', 'attachments', 'invoices entry', 'modules/bms/invoices_attachments.php', '30', '0', '10', '', 'SELECT count(id) AS theresult FROM attachments WHERE tabledefid=3 AND recordid={{id}}', 1, NOW(), 1, NOW()); 13 INSERT INTO `tabs` (`id`, `uuid`, `name`, `tabgroup`, `location`, `displayorder`, `enableonnew`, `roleid`, `tooltip`, `notificationsql`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('18', 'tab:c4cbfabf-a00e-7b82-b411-0e442205360a', 'notes/events/task', 'invoices entry', 'modules/bms/invoices_notes.php', '40', '0', '10', '', 'SELECT count(id) AS theresult FROM notes WHERE attachedtabledefid=3 AND attachedid={{id}}', 1, NOW(), 1, NOW()); 14 INSERT INTO `tabs` (`id`, `uuid`, `name`, `tabgroup`, `location`, `displayorder`, `enableonnew`, `roleid`, `tooltip`, `notificationsql`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('300', 'tab:5a6ef814-2689-4e3b-2609-db43fb3cc001', 'credit', 'clients entry', 'modules/bms/clients_credit.php', '15', '0', '0', 'Credit Limits/History', NULL, 1, NOW(), 1, NOW()); 15 INSERT INTO `tabs` (`id`, `uuid`, `name`, `tabgroup`, `location`, `displayorder`, `enableonnew`, `roleid`, `tooltip`, `notificationsql`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('303', 'tab:625192d0-00e6-ae2c-5b8c-f433bbf6e546', 'addresses', 'clients entry', 'modules/bms/clients_addresses.php', '12', '0', '0', NULL, NULL, 1, NOW(), 1, NOW()); -
trunk/phpbms/modules/bms/install/updatev0.98.sql
r540 r542 17 17 ALTER TABLE `receipts` ENGINE=INNODB; 18 18 ALTER TABLE `shippingmethods` ENGINE=INNODB; 19 20 --ADD UUID-- 21 ALTER TABLE `addresses` ADD COLUMN `uuid` varchar(64) NOT NULL AFTER `id`;-- 22 ALTER TABLE `clientemailprojects` ADD COLUMN `uuid` varchar(64) NOT NULL AFTER `id`;-- 23 ALTER TABLE `clients` ADD COLUMN `uuid` varchar(64) NOT NULL AFTER `id`;-- 24 ALTER TABLE `discounts` ADD COLUMN `uuid` varchar(64) NOT NULL AFTER `id`;-- 25 ALTER TABLE `invoices` ADD COLUMN `uuid` varchar(64) NOT NULL AFTER `id`;-- 26 ALTER TABLE `invoicestatuses` ADD COLUMN `uuid` varchar(64) NOT NULL AFTER `id`;-- 27 ALTER TABLE `paymentmethods` ADD COLUMN `uuid` varchar(64) NOT NULL AFTER `id`;-- 28 ALTER TABLE `productcategories` ADD COLUMN `uuid` varchar(64) NOT NULL AFTER `id`;-- 29 ALTER TABLE `products` ADD COLUMN `uuid` varchar(64) NOT NULL AFTER `id`;-- 30 ALTER TABLE `receipts` ADD COLUMN `uuid` varchar(64) NOT NULL AFTER `id`;-- 31 ALTER TABLE `shippingmethods` ADD COLUMN `uuid` varchar(64) NOT NULL AFTER `id`;-- 32 ALTER TABLE `tax` ADD COLUMN `uuid` varchar(64) NOT NULL AFTER `id`;-- 19 33 ALTER TABLE `clients` ADD COLUMN `taxid` VARCHAR(64) default NULL AFTER `webaddress`; 34 --END ADD UUID-- 35 20 36 ALTER TABLE `receipts` MODIFY COLUMN `paymentmethodid` INTEGER NOT NULL DEFAULT 0; 21 37 INSERT INTO `settings` (`name`, `value`) VALUES ('company_taxid', ''); … … 48 64 UPDATE `tablefindoptions` SET `search`= 'addresses.address1=daddresses.address1 AND clients.id<>dclients.id' WHERE `name` = 'match addresses' AND `tabledefid` = '18'; 49 65 UPDATE `tablecolumns` SET `column`='IF(receipts.paymentmethodid = -1,concat( concat("Other... (", receipts.paymentother), ")"), paymentmethods.name)' WHERE `tabledefid` = '304' AND `name` = 'payment'; 66 --report updates-- 50 67 UPDATE `reports` SET `uuid`='reports:bac1d6eb-b2bb-9aa0-77c0-ff7f9046ca75' WHERE `name`='Invoice'; 51 68 UPDATE `reports` SET `uuid`='reports:a34dd4b5-6942-2b14-4a58-74345dce48de' WHERE `name`='Work Order'; … … 75 92 INSERT INTO `reports` (`uuid`, `name`, `type`, `tabledefid`, `displayorder`, `roleid`, `reportfile`, `description`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('reports:e25bdb7a-93be-b1d6-a292-cdec89c0c9fc', 'Summary', 'report', '303', '10', '80', 'modules/bms/report/aritems_summary.php', 'Items grouped and totaled by clients, with grand totals.', 1, NOW(), 1, NOW()); 76 93 INSERT INTO `reports` (`uuid`, `name`, `type`, `tabledefid`, `displayorder`, `roleid`, `reportfile`, `description`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('reports:916f34d8-0997-162c-4350-d93c3d283241', 'Payment Type Totals', 'report', '304', '10', '80', 'modules/bms/report/receipts_pttotals.php', 'Totals grouped by payment method.', 1, NOW(), 1, NOW()); 77 INSERT INTO `reports` (`uuid`, `name`, `type`, `tabledefid`, `displayorder`, `roleid`, `reportfile`, `description`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('reports:4851c350-4343-4dc3-4b7b-74c287de011b', 'Incoming Cash Flow', 'report', '3', '55', '50', 'modules/bms/report/incoming_cashflow.php', 'This report shows total incoming monies for a time period from both posted sales orders AND posted receipts. It can be grouped by week, month, quarter and year.\r\n\r\nThis report runs is unaffected by selected records, search or sort parameters. It requires input of it\'s own start and end dates.', 1, NOW(), 1, NOW()); 94 INSERT INTO `reports` (`uuid`, `name`, `type`, `tabledefid`, `displayorder`, `roleid`, `reportfile`, `description`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('reports:4851c350-4343-4dc3-4b7b-74c287de011b', 'Incoming Cash Flow', 'report', '3', '55', '50', 'modules/bms/report/incoming_cashflow.php', 'This report shows total incoming monies for a time period from both posted sales orders AND posted receipts. It can be grouped by week, month, quarter and year.\r\n\r\nThis report runs is unaffected by selected records, search or sort parameters. It requires input of its own start and end dates.', 1, NOW(), 1, NOW()); 95 --end report updates 96 --role updates-- 97 UPDATE `roles` SET `uuid`='role:3403a7e0-adb1-4d0b-3c6e-6d6bbe177d52' WHERE `id`='10'; 98 UPDATE `roles` SET `uuid`='role:de7e6679-8bb2-29ee-4883-2fcd756fb120' WHERE `id`='20'; 99 UPDATE `roles` SET `uuid`='role:259ead9f-100b-55b5-508a-27e33a6216bf' WHERE `id`='30'; 100 UPDATE `roles` SET `uuid`='role:8f5fb368-e7d9-5010-d8f6-b4a78adc0520' WHERE `id`='50'; 101 UPDATE `roles` SET `uuid`='role:c9439c3c-499b-7bcc-ee14-fec5bfcf5fc2' WHERE `id`='80'; 102 --end role updates-- 103 --shippingmethods updates-- 104 UPDATE `shippingmethods` SET `uuid`='shp:f34a3e10-e782-2675-f041-71f5c88f5aa9' WHERE `id`='1'; 105 UPDATE `shippingmethods` SET `uuid`='shp:e2e43816-667a-fdf3-6bec-4456bcf8bef0' WHERE `id`='2'; 106 UPDATE `shippingmethods` SET `uuid`='shp:0f07f7fd-0352-8df7-8294-a57e5e375808' WHERE `id`='3'; 107 UPDATE `shippingmethods` SET `uuid`='shp:6ef11711-7335-3e90-cf27-df5ea23c1480' WHERE `id`='4'; 108 UPDATE `shippingmethods` SET `uuid`='shp:1a0c53bd-6754-7d9f-4bea-bad57628187a' WHERE `id`='5'; 109 UPDATE `shippingmethods` SET `uuid`='shp:9e0bad1f-0545-6b09-3900-4e5943629037' WHERE `id`='6'; 110 UPDATE `shippingmethods` SET `uuid`='shp:ba131229-fb3d-d328-91c8-323480831b03' WHERE `id`='7'; 111 --end shippingmethods updates-- 112 --tabs update-- 113 UPDATE `tabs` SET `uuid`='tab:becfca94-ae25-a42c-7909-247d5324e4b5' WHERE `id`='6'; 114 UPDATE `tabs` SET `uuid`='tab:ef895fc0-bbea-9bf5-47ac-4913c6dace13' WHERE `id`='7'; 115 UPDATE `tabs` SET `uuid`='tab:19e34181-65f0-bfcf-6e09-99d0575ebd74' WHERE `id`='8'; 116 UPDATE `tabs` SET `uuid`='tab:d8e888af-d147-98ae-6849-a159a7c9daae' WHERE `id`='9'; 117 UPDATE `tabs` SET `uuid`='tab:17346362-261b-4d1d-fa77-99e84cfd9b8a' WHERE `id`='10'; 118 UPDATE `tabs` SET `uuid`='tab:9bfc7eea-5abb-f5d8-763f-f78fe499464d' WHERE `id`='11'; 119 UPDATE `tabs` SET `uuid`='tab:cd09d4a1-7d32-e08a-bd6e-5850bc9af88e' WHERE `id`='12'; 120 UPDATE `tabs` SET `uuid`='tab:4c853d8b-8895-a8c5-8ff6-1128e6e1a798' WHERE `id`='13'; 121 UPDATE `tabs` SET `uuid`='tab:d62cf7eb-fd2a-948a-6279-8a61d02390ae' WHERE `id`='14'; 122 UPDATE `tabs` SET `uuid`='tab:20276b44-9cfa-403e-4c2a-ac6f0987ae20' WHERE `id`='15'; 123 UPDATE `tabs` SET `uuid`='tab:809d644e-fa40-5ad3-0426-3d84cf15b32e' WHERE `id`='16'; 124 UPDATE `tabs` SET `uuid`='tab:23687374-5c14-04af-74ac-0f74342e1019' WHERE `id`='17'; 125 UPDATE `tabs` SET `uuid`='tab:c4cbfabf-a00e-7b82-b411-0e442205360a' WHERE `id`='18'; 126 UPDATE `tabs` SET `uuid`='tab:5a6ef814-2689-4e3b-2609-db43fb3cc001' WHERE `id`='300'; 127 UPDATE `tabs` SET `uuid`='tab:625192d0-00e6-ae2c-5b8c-f433bbf6e546' WHERE `id`='303'; 128 --end tabs update-- 78 129 INSERT INTO `widgets` (`uuid`, `type`, `title`, `file`, `roleid`, `moduleid`, `default`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('wdgt:c0a56726-d855-7443-66a2-7b84f443a84c', 'big', 'New Sales Orders', '../bms/widgets/recentsalesorders/class.php', '20', '2', '1', 1, NOW(), 1, NOW()); 79 130 INSERT INTO `widgets` (`uuid`, `type`, `title`, `file`, `roleid`, `moduleid`, `default`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('wdgt:26936c27-7b7c-07fc-1f35-97d2410688b5', 'big', 'New Clients', '../bms/widgets/recentclients/class.php', '20', '2', '1', 1, NOW(), 1, NOW()); … … 126 177 INSERT INTO `menu` (`uuid`, `name`, `link`, `parentid`, `displayorder`, `createdby`, `modifiedby`, `creationdate`, `modifieddate`, `roleid`) VALUES ('menu:1b9973a9-b1c7-8cf6-a5ea-ba041a19ac06', 'Post Records', 'modules/bms/post.php', 'menu:1e23c59e-c429-fec5-cc94-99b53c4fc6b0', '110', 1, 1, NOW(), NOW(), '50'); 127 178 INSERT INTO `menu` (`uuid`, `name`, `link`, `parentid`, `displayorder`, `createdby`, `modifiedby`, `creationdate`, `modifieddate`, `roleid`) VALUES ('menu:07b85ffa-178b-f20f-36db-c2ca99274124', 'Posting Sessions', 'search.php?id=307', 'menu:1e23c59e-c429-fec5-cc94-99b53c4fc6b0', '120', 1, 1, NOW(), NOW(), '50'); 128 UPDATE `tabledefs` SET `hascustomfields` = 1 WHERE `id` IN(306, 2, 5, 25, 302, 7,4, 304,3, 300, 6, 301);129 179 ALTER TABLE `addresses` ADD COLUMN `custom1` DOUBLE, ADD COLUMN `custom2` DOUBLE, ADD COLUMN `custom3` DATETIME, ADD COLUMN `custom4` DATETIME, ADD COLUMN `custom5` VARCHAR(255), ADD COLUMN `custom6` VARCHAR(255), ADD COLUMN `custom7` TINYINT(1) DEFAULT 0, ADD COLUMN `custom8` TINYINT(1) DEFAULT 0; 130 180 ALTER TABLE `clients` ADD COLUMN `custom1` DOUBLE, ADD COLUMN `custom2` DOUBLE, ADD COLUMN `custom3` DATETIME, ADD COLUMN `custom4` DATETIME, ADD COLUMN `custom5` VARCHAR(255), ADD COLUMN `custom6` VARCHAR(255), ADD COLUMN `custom7` TINYINT(1) DEFAULT 0, ADD COLUMN `custom8` TINYINT(1) DEFAULT 0; … … 141 191 -- Preping Product Categories to be more shopping cart synchronization friendly -- 142 192 ALTER TABLE `productcategories` ADD COLUMN `parentid` int(11) NOT NULL DEFAULT 0 AFTER `name`, ADD COLUMN `displayorder` INT(11) NOT NULL DEFAULT 0 AFTER `parentid`; 193 194 --Update tabledefs-- 195 UPDATE `tabledefs` SET `hascustomfields` = 1 WHERE `id` IN(306, 2, 5, 25, 302, 7,4, 304,3, 300, 6, 301); 143 196 UPDATE `tabledefs` SET `querytable` = '(productcategories LEFT JOIN productcategories AS `parents` ON productcategories.parentid = parents.id)' WHERE id = 7; 197 UPDATE `tabledefs` SET `uuid`='tbld:6d290174-8b73-e199-fe6c-bcf3d4b61083' WHERE `id`='2'; 198 UPDATE `tabledefs` SET `uuid`='tbld:62fe599d-c18f-3674-9e54-b62c2d6b1883' WHERE `id`='3'; 199 UPDATE `tabledefs` SET `uuid`='tbld:7a9e87ed-d165-c4a4-d9b9-0a4adc3c5a34' WHERE `id`='4'; 200 UPDATE `tabledefs` SET `uuid`='tbld:31423480-a9b0-f0ff-749e-b3b5e18ca93c' WHERE `id`='5'; 201 UPDATE `tabledefs` SET `uuid`='tbld:c9ff2c8c-ce1f-659a-9c55-31bca7cce70e' WHERE `id`='6'; 202 UPDATE `tabledefs` SET `uuid`='tbld:3342a3d4-c6a2-3a38-6576-419299859561' WHERE `id`='7'; 203 UPDATE `tabledefs` SET `uuid`='tbld:8179e105-5487-5173-d835-d9d510cc7f1b' WHERE `id`='8'; 204 UPDATE `tabledefs` SET `uuid`='tbld:f993cf23-ad4a-047b-e920-d45fee1dc08e' WHERE `id`='18'; 205 UPDATE `tabledefs` SET `uuid`='tbld:157b7707-5503-4161-4dcf-6811f8b0322f' WHERE `id`='22'; 206 UPDATE `tabledefs` SET `uuid`='tbld:455b8839-162b-3fcb-64b6-eeb946f873e1' WHERE `id`='25'; 207 UPDATE `tabledefs` SET `uuid`='tbld:fa8a0ddc-87d3-a9e9-60b0-1bab374b2993' WHERE `id`='300'; 208 UPDATE `tabledefs` SET `uuid`='tbld:380d4efa-a825-f377-6fa1-a030b8c58ffe' WHERE `id`='301'; 209 UPDATE `tabledefs` SET `uuid`='tbld:d6e4e1fb-4bfa-cb53-ab9c-1b3e7f907ae2' WHERE `id`='302'; 210 UPDATE `tabledefs` SET `uuid`='tbld:c595dbe7-6c77-1e02-5e81-c2e215736e9c' WHERE `id`='303'; 211 UPDATE `tabledefs` SET `uuid`='tbld:43678406-be25-909b-c715-7e2afc7db601' WHERE `id`='304'; 212 UPDATE `tabledefs` SET `uuid`='tbld:e3ce122f-7c43-cfca-fd32-11c663567a2a' WHERE `id`='305'; 213 UPDATE `tabledefs` SET `uuid`='tbld:27b99bda-7bec-b152-8397-a3b09c74cb23' WHERE `id`='306'; 214 UPDATE `tabledefs` SET `uuid`='tbld:97760a4f-1c1a-a108-d05f-5fc4ec59583c' WHERE `id`='307'; 215 --end Update tabledefs-- 216 144 217 DELETE FROM `tablecolumns` WHERE `tabledefid` = 7; 145 218 INSERT INTO `tablecolumns` (`tabledefid`, `name`, `column`, `align`, `footerquery`, `displayorder`, `sortorder`, `wrap`, `size`, `format`, `roleid`) VALUES ('7', 'name', 'if(productcategories.description, concat(\'[b]\', productcategories.name,\'[/b][br]\',productcategories.description), concat(\'[b]\', productcategories.name,\'[/b]\'))', 'left', '', '1', 'productcategories.name', '0', '100%', 'bbcode', '0'); … … 154 227 ) ENGINE=INNODB; 155 228 UPDATE `tabledefs` SET `querytable` = '(products LEFT JOIN productcategories ON products.categoryid = productcategories.id)' WHERE `id`=4; 156 INSERT INTO `smartsearches` (`id`, `name`, `fromclause`, `valuefield`, `displayfield`, `secondaryfield`, `classfield`, `searchfields`, `filterclause`, `rolefield`, `tabledefid`, `moduleid`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('10', 'Pick Product Category For Product', 'productcategories', 'productcategories.id', 'productcategories.name', '\'\'', '\'\'', 'productcategories.name', 'productcategories.inactive = 0', '\'\'', '7', '2', 1, NOW(), 1, NOW()); 229 --update/insert smartsearches-- 230 UPDATE `smartsearches` SET `uuid`='smrt:5cf171f7-2284-1492-62bb-872bc222eaef' WHERE `id`='1'; 231 UPDATE `smartsearches` SET `uuid`='smrt:1b16f1e8-edf2-332e-e61b-3759f7020d41' WHERE `id`='3'; 232 UPDATE `smartsearches` SET `uuid`='smrt:5634f7fb-a0c8-7e10-4c96-8bb043e7f478' WHERE `id`='4'; 233 UPDATE `smartsearches` SET `uuid`='smrt:32f76377-1822-17f5-674c-118b678378d4' WHERE `id`='6'; 234 UPDATE `smartsearches` SET `uuid`='smrt:a18ca9d4-58aa-7a47-faa7-1ad0ed5ba8c6' WHERE `id`='7'; 235 UPDATE `smartsearches` SET `uuid`='smrt:3b48afbf-f18f-a18d-8aa8-f51f27008750' WHERE `id`='8'; 236 INSERT INTO `smartsearches` (`uuid`, `name`, `fromclause`, `valuefield`, `displayfield`, `secondaryfield`, `classfield`, `searchfields`, `filterclause`, `rolefield`, `tabledefid`, `moduleid`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('smrt:eed8c810-f9c8-077b-4b3e-9aef451f8057 ', 'Pick Product Category For Product', 'productcategories', 'productcategories.id', 'productcategories.name', '\'\'', '\'\'', 'productcategories.name', 'productcategories.inactive = 0', '\'\'', '7', '2', 1, NOW(), 1, NOW()); 237 --end smartsearches-- 157 238 -- Adding UUID prefix for BMS tables 158 239 UPDATE `tabledefs` SET `prefix` = 'tax' WHERE id = 6; -
trunk/phpbms/modules/recurringinvoices/install/roles.sql
r285 r542 1 INSERT INTO `roles` (`id`, ` name`, `description`, `inactive`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES (400,'recurring invoice notification','',0,1,NOW(),1,NOW());1 INSERT INTO `roles` (`id`, `uuid`, `name`, `description`, `inactive`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('400', 'role:ddbc37d3-c450-beba-b720-6cec50b55d82', 'recurring invoice notification', '', '0', 1, NOW(), 1, NOW()); -
trunk/phpbms/modules/recurringinvoices/install/scheduler.sql
r285 r542 1 INSERT INTO `scheduler` (` name`, `job`, `crontab`, `lastrun`, `startdatetime`, `enddatetime`, `description`, `inactive`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('Recurr Invoices','../recurringinvoices/scheduler_recurr.php','0::0::*::*::*',NULL,'0000-00-00 00:00:00',NULL,'This job recurrs any invoices with repeat options.',0,1,NOW(),1,NOW());1 INSERT INTO `scheduler` (`uuid`, `name`, `job`, `crontab`, `lastrun`, `startdatetime`, `enddatetime`, `description`, `inactive`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('schd:ba7f18b4-3489-a970-bf4c-ed7e3053dabf', 'Recurr Invoices', '../recurringinvoices/scheduler_recurr.php', '0::0::*::*::*', '2009-05-26 00:00:01', '0000-00-00 00:00:00', NULL, 'This job recurrs any invoices with repeat options.', '0', 1, NOW(), 1, NOW()); -
trunk/phpbms/modules/recurringinvoices/install/tabledefs.sql
r517 r542 1 INSERT INTO `tabledefs` (`id`, ` displayname`, `type`, `moduleid`, `maintable`, `querytable`, `editfile`, `editroleid`, `addfile`, `addroleid`, `importfile`, `importroleid`, `searchroleid`, `advsearchroleid`, `viewsqlroleid`, `deletebutton`, `canpost`, `hascustomfields`, `defaultwhereclause`, `defaultsortorder`, `defaultsearchtype`, `defaultcriteriafindoptions`, `defaultcriteriaselection`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('400', 'Recurring Invoices', 'view', '200', 'invoices', '(recurringinvoices INNER JOIN invoices ON recurringinvoices.invoiceid = invoices.id) INNER JOIN clients ON invoices.clientid = clients.id', 'modules/recurringinvoices/invoices_recurrence.php', '30', 'N/A', '0', NULL, '-100', '20', '-100', '-100', 'NA', '0', '0', 'recurringinvoices.id != 0', 'invoices.invoicedate', NULL, NULL, NULL, 1, NOW(), 1, NOW());1 INSERT INTO `tabledefs` (`id`, `uuid`, `displayname`, `type`, `moduleid`, `maintable`, `querytable`, `editfile`, `editroleid`, `addfile`, `addroleid`, `importfile`, `importroleid`, `searchroleid`, `advsearchroleid`, `viewsqlroleid`, `deletebutton`, `canpost`, `hascustomfields`, `defaultwhereclause`, `defaultsortorder`, `defaultsearchtype`, `defaultcriteriafindoptions`, `defaultcriteriaselection`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('400', 'tbld:3434bf2d-1337-5cab-0a7a-25e04f1c6d8f', 'Recurring Invoices', 'view', '200', 'invoices', '(recurringinvoices INNER JOIN invoices ON recurringinvoices.invoiceid = invoices.id) INNER JOIN clients ON invoices.clientid = clients.id', 'modules/recurringinvoices/invoices_recurrence.php', '30', 'N/A', '0', NULL, '-100', '20', '-100', '-100', 'NA', '0', '0', 'recurringinvoices.id != 0', 'invoices.invoicedate', NULL, NULL, NULL, 1, NOW(), 1, NOW()); -
trunk/phpbms/modules/recurringinvoices/install/tabs.sql
r285 r542 1 INSERT INTO `tabs` (`id`, ` name`, `tabgroup`, `location`, `displayorder`, `enableonnew`, `roleid`, `tooltip`, `notificationsql`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES (500,'recurrence','invoices entry','modules/recurringinvoices/invoices_recurrence.php',25,0,20,'','',1,NOW(),1,NOW());1 INSERT INTO `tabs` (`id`, `uuid`, `name`, `tabgroup`, `location`, `displayorder`, `enableonnew`, `roleid`, `tooltip`, `notificationsql`, `createdby`, `creationdate`, `modifiedby`, `modifieddate`) VALUES ('500', 'tab:d303321e-7ff5-fe4b-29ec-fe3eb0305576', 'recurrence', 'invoices entry', 'modules/recurringinvoices/invoices_recurrence.php', '25', '0', '20', '', '', 1, NOW(), 1, NOW()); -
trunk/phpbms/modules/recurringinvoices/install/updatev1.03.sql
r513 r542 2 2 INSERT INTO `tableoptions` (`tabledefid`, `name`, `option`, `needselect`, `othercommand`, `roleid`, `displayorder`) VALUES ('400', 'import', '0', '0', '0', '-100', '0'); 3 3 INSERT INTO `menu` (`uuid`, `name`, `link`, `parentid`, `displayorder`, `createdby`, `modifiedby`, `creationdate`, `modifieddate`, `roleid`) VALUES ('menu:1f7541a0-7bbe-6b9f-e7c5-2db926557e53', 'Recurring Invoices', 'search.php?id=400', 'menu:8cf7d073-72b9-93db-6d07-14578e2a694f', '17', 1, 1, NOW(), NOW(), '30'); 4 UPDATE `roles` SET `uuid`='role:ddbc37d3-c450-beba-b720-6cec50b55d82' WHERE `id`='400'; 5 UPDATE `scheduler` SET `uuid`='schd:ba7f18b4-3489-a970-bf4c-ed7e3053dabf' WHERE `name`='Recurr Invoices'; 6 UPDATE `tabledefs` SET `uuid`='tbld:3434bf2d-1337-5cab-0a7a-25e04f1c6d8f' WHERE `id`='400'; 7 UPDATE `users` SET `uuid`='usr:170c4b04-b8fe-a528-fcea-5a213669f400' WHERE `id`='5'; 8 UPDATE `tabs` SET `uuid`='tab:d303321e-7ff5-fe4b-29ec-fe3eb0305576' WHERE `id`='500'; -
trunk/phpbms/modules/recurringinvoices/install/users.sql
r359 r542 1 INSERT INTO `users` (`id`, ` login`, `password`, `firstname`, `lastname`, `creationdate`, `revoked`, `createdby`, `modifiedby`, `lastlogin`, `modifieddate`, `email`, `phone`, `department`, `employeenumber`, `admin`, `portalaccess`) VALUES (5,'Reccurence','tÃ%ÃBÞTv:$ÃRtÃ`','phpBMS','Scheduler',NOW(),0,1,1,NULL,NOW(),'','','','',0,1);1 INSERT INTO `users` (`id`, `uuid`, `login`, `password`, `firstname`, `lastname`, `lastip`, `creationdate`, `revoked`, `createdby`, `modifiedby`, `lastlogin`, `modifieddate`, `email`, `phone`, `department`, `employeenumber`, `admin`, `portalaccess`) VALUES ('5', 'usr:170c4b04-b8fe-a528-fcea-5a213669f400', 'Reccurence', 'tÃ%ÃBÞTv:$ÃRtÃ`', 'phpBMS', 'Scheduler', '', NOW(), '0', 1, 1, NULL, NOW(), '', '', '', '', '0', '1');