3
"appVersion": "1.8.0-alpha",
6
"step": "Alter the Log Table - Part 1",
7
"action": "ALTER TABLE `log` DROP `scheduleID`,DROP `layoutID`,DROP `mediaID`,DROP `RequestUri`,DROP `RemoteAddr`,DROP `UserAgent`;"
10
"step": "Alter the Log Table - Part 2",
11
"action": "ALTER TABLE `log` CHANGE `type` `type` VARCHAR( 254 ) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL;"
14
"step": "Alter the Log Table - Part 3",
15
"action": "ALTER TABLE `log` ADD `channel` VARCHAR( 5 ) NOT NULL AFTER `logdate`, ADD `runNo` VARCHAR( 10 ) NOT NULL AFTER `logid`;"
18
"step": "Alter the Module Table",
19
"action": "ALTER TABLE `module` ADD `viewPath` VARCHAR( 254 ) NOT NULL DEFAULT '../modules', ADD `class` VARCHAR( 254 ) NOT NULL;"
22
"step": "Add Permissions Table",
23
"action": "CREATE TABLE IF NOT EXISTS `permission` (`permissionId` int(11) NOT NULL AUTO_INCREMENT,`entityId` int(11) NOT NULL,`groupId` int(11) NOT NULL,`objectId` int(11) NOT NULL,`view` tinyint(4) NOT NULL,`edit` tinyint(4) NOT NULL,`delete` tinyint(4) NOT NULL,PRIMARY KEY (`permissionId`)) ENGINE=InnoDB DEFAULT CHARSET=utf8 AUTO_INCREMENT=1;"
26
"step": "Add Permission Entity Table",
27
"action": "CREATE TABLE IF NOT EXISTS `permissionentity` (`entityId` int(11) NOT NULL AUTO_INCREMENT,`entity` varchar(50) NOT NULL,PRIMARY KEY (`entityId`),UNIQUE KEY `entity` (`entity`)) ENGINE=InnoDB DEFAULT CHARSET=utf8 AUTO_INCREMENT=10 ;"
30
"step": "Populate Permission Entities",
31
"action": "INSERT INTO `permissionentity` (`entityId`, `entity`) VALUES(5, 'Xibo\\\\Entity\\\\Campaign'),(9, 'Xibo\\\\Entity\\\\DataSet'),(3, 'Xibo\\\\Entity\\\\DisplayGroup'),(4, 'Xibo\\\\Entity\\\\Media'),(1, 'Xibo\\\\Entity\\\\Page'),(8, 'Xibo\\\\Entity\\\\Playlist'),(7, 'Xibo\\\\Entity\\\\Region'),(6, 'Xibo\\\\Entity\\\\Widget');"
34
"step": "Convert Page Permissions",
35
"action": "INSERT INTO `permission` (`groupId`, `entityId`, `objectId`, `view`, `edit`, `delete`) SELECT groupId, 1, pageId, 1, 0, 0 FROM `lkpagegroup`;"
38
"step": "Remove Page Permissions table",
39
"action": "DROP TABLE `lkpagegroup`;"
42
"step": "Remove Menu Permissions table",
43
"action": "DROP TABLE `lkmenuitemgroup`;"
46
"step": "Convert Campaign/Layout Permissions",
47
"action": "INSERT INTO `permission` (`groupId`, `entityId`, `objectId`, `view`, `edit`, `delete`) SELECT groupId, 5, campaignId, view, edit, del FROM `lkcampaigngroup`;"
50
"step": "Remove old Campaign/Layout Permissions table",
51
"action": "DROP TABLE `lkcampaigngroup`;"
54
"step": "Convert Media Permissions",
55
"action": "INSERT INTO `permission` (`groupId`, `entityId`, `objectId`, `view`, `edit`, `delete`) SELECT groupId, 4, mediaId, view, edit, del FROM `lkmediagroup`;"
58
"step": "Remove old Media Permissions table",
59
"action": "DROP TABLE `lkmediagroup`;"
62
"step": "Convert DataSet Permissions",
63
"action": "INSERT INTO `permission` (`groupId`, `entityId`, `objectId`, `view`, `edit`, `delete`) SELECT groupId, 9, dataSetId, view, edit, del FROM `lkdatasetgroup`;"
66
"step": "Remove old DataSet Permissions table",
67
"action": "DROP TABLE `lkdatasetgroup`;"
70
"step": "Convert Display Group Permissions",
71
"action": "INSERT INTO `permission` (`groupId`, `entityId`, `objectId`, `view`, `edit`, `delete`) SELECT groupId, 3, displayGroupId, view, edit, del FROM `lkdisplaygroupgroup`;"
74
"step": "Remove old Display Group Permissions table",
75
"action": "DROP TABLE `lkdisplaygroupgroup`;"
78
"step": "Alter page table - part 1",
79
"action": "ALTER TABLE `pages` DROP FOREIGN KEY `pages_ibfk_1` ;"
82
"step": "Alter page table - part 2",
83
"action": "ALTER TABLE `pages` DROP `pagegroupID`;"
86
"step": "Alter page table - part 3",
87
"action": "ALTER TABLE `pages` ADD `title` VARCHAR( 50 ) NOT NULL, ADD `asHome` TINYINT NOT NULL DEFAULT '0';"
90
"step": "Add New Pages",
91
"action": "INSERT INTO `pages` (`pageID`, `name`, `title`) VALUES (NULL, 'region', ''), (NULL, 'playlist', ''), (NULL, 'maintenance', '');"
94
"step": "Link Region Page",
95
"action": "INSERT INTO `permission` (`groupId`, `entityId`, `objectId`, `view`, `edit`, `delete`) SELECT `groupId`, 1, (SELECT pageId FROM `pages` WHERE `name` = 'region'), `view`, `edit`, `delete` FROM `permission` WHERE `objectId` = (SELECT pageId FROM `pages` WHERE `name` = 'layout') AND `entityId` = 1;"
98
"step": "Link Playlist Page",
99
"action": "INSERT INTO `permission` (`groupId`, `entityId`, `objectId`, `view`, `edit`, `delete`) SELECT `groupId`, 1, (SELECT pageId FROM `pages` WHERE `name` = 'playlist'), `view`, `edit`, `delete` FROM `permission` WHERE `objectId` = (SELECT pageId FROM `pages` WHERE `name` = 'layout') AND `entityId` = 1;"
102
"step": "Set Page Names",
103
"action": "UPDATE `pages` SET title = CONCAT(UCASE(LEFT(name, 1)), SUBSTRING(name, 2)), asHome = 1;"
106
"step": "Change audit log page name",
107
"action": "UPDATE `pages` SET `name` = 'audit' WHERE `name` = 'auditlog';"
110
"step": "Set Page Home Flag",
111
"action": "UPDATE `pages` SET asHome = 0 WHERE `name` IN ('update','admin','manual','help','clock','preview','region','playlist','maintenance');"
114
"step": "Remove menu and menu items",
115
"action": "DROP TABLE `menuitem`, `menu`, `pagegroup`;"
118
"step": "Rename the Library page",
119
"action": "UPDATE `pages` SET `name` = 'library', `title` = 'Library' WHERE `pages`.`name` = 'content';"
122
"step": "Rename the Applications page",
123
"action": "UPDATE `pages` SET `name` = 'applications', `title` = 'Applications' WHERE `pages`.`name` = 'oauth';"
126
"step": "Rename the Media Dashboard page",
127
"action": "UPDATE `pages` SET `title` = 'Media Dashboard' WHERE `pages`.`name` = 'mediamanager';"
130
"step": "Rename the Status Dashboard page",
131
"action": "UPDATE `pages` SET `title` = 'Status Dashboard' WHERE `pages`.`name` = 'statusdashboard';"
134
"step": "Rename the Display Profile page",
135
"action": "UPDATE `pages` SET `title` = 'Display Profiles' WHERE `pages`.`name` = 'displayprofile';"
138
"step": "Rename the Display Group page",
139
"action": "UPDATE `pages` SET `title` = 'Display Groups' WHERE `pages`.`name` = 'displaygroup';"
142
"step": "Rename the Home page",
143
"action": "UPDATE `pages` SET `title` = 'Home' WHERE `pages`.`name` = 'index';"
146
"step": "Rename the Audit Trail page",
147
"action": "UPDATE `pages` SET `title` = 'Audit Trail' WHERE `pages`.`name` = 'auditlog';"
150
"step": "Add new attributes to the Layout Structure",
151
"action": "ALTER TABLE `layout` ADD `width` DECIMAL NOT NULL ,ADD `height` DECIMAL NOT NULL ,ADD `backgroundColor` VARCHAR( 25 ) NULL ,ADD `backgroundzIndex` INT NOT NULL DEFAULT '1',ADD `schemaVersion` TINYINT NOT NULL;"
154
"step": "Set all Users Home page - Part 1",
155
"action": "UPDATE `user` SET homepage = IFNULL((SELECT pageId FROM `pages` WHERE pages.name = `user`.homepage LIMIT 1), 1);"
158
"step": "Update Users Home page - Part 2",
159
"action": "ALTER TABLE `user` CHANGE `homepage` `homePageId` INT NOT NULL DEFAULT '1' COMMENT 'The users homepage';"
162
"step": "Remove the Counter Module",
163
"action": "DELETE FROM module WHERE module = 'counter';"
166
"step": "Upgrade Layouts - Ensure Layout XML field is nullable",
167
"action": "ALTER TABLE layout MODIFY xml longtext;"
170
"step": "Add Layout status message column",
171
"action": "ALTER TABLE `layout` ADD `statusMessage` TEXT NULL;"
174
"step": "Upgrade Layouts - Convert existing Layouts",
176
"action": "Xibo\\Upgrade\\LayoutStructureStep"
179
"step": "Upgrade Layouts - Clean up",
180
"action": "DROP TABLE `lklayoutmedia`;"
183
"step": "Upgrade Layouts - Clean up",
184
"action": "ALTER TABLE `layout` DROP `xml`;"
187
"step": "Upgrade API - Part 1",
188
"action": "DROP TABLE `oauth_log`, `oauth_server_nonce`, `oauth_server_token`, `oauth_server_registry`;"
191
"step": "Upgrade API - Part 2",
193
"action": "Xibo\\Upgrade\\OAuthServerInstallStep"
196
"step": "Upgrade API - Drop the File Table",
197
"action": "DROP TABLE `file`;"
200
"step": "Removal all old XMDS nonces",
201
"action": "TRUNCATE TABLE `xmdsnonce`;"
204
"step": "Upgrade XMDS - Part 1",
205
"action": "RENAME TABLE `xmdsnonce` TO `requiredfile`;"
208
"step": "Upgrade XMDS - Part 2",
209
"action": "ALTER TABLE `requiredfile` ADD `requestKey` VARCHAR( 10 ) NOT NULL, ADD `bytesRequested` BIGINT NOT NULL, ADD `complete` TINYINT NOT NULL;"
212
"step": "Upgrade XMDS - Part 3",
213
"action": "ALTER TABLE `requiredfile` CHANGE `nonceId` `rfId` BIGINT( 20 ) NOT NULL AUTO_INCREMENT;"
216
"step": "Upgrade XMDS - Part 4",
217
"action": "ALTER TABLE `requiredfile` CHANGE `regionId` `regionId` INT NULL;"
220
"step": "Upgrade XMDS - Part 5",
221
"action": "ALTER TABLE `requiredfile` DROP `fileId`;"
224
"step": "Remove Media Inventory from the Display Table",
225
"action": "ALTER TABLE `display` DROP `MediaInventoryXml`;"
228
"step": "Remove international date format setting",
229
"action": "DELETE FROM `setting` WHERE setting = 'USE_INTL_DATEFORMAT';"
232
"step": "Update audit setting with new levels",
233
"action": "UPDATE `setting` SET options = 'Emergency|Alert|Critical|Error|Warning|Notice|Info|Debug', value = 'Error' WHERE setting = 'audit';"
236
"step": "Update default permission setting options",
237
"action": "UPDATE `setting` SET `options` = 'private|group|public' WHERE `setting`.`setting` IN ('MEDIA_DEFAULT', 'LAYOUT_DEFAULT');"
240
"step": "Add new settings",
241
"action": "INSERT INTO `setting` (`settingid`, `setting`, `value`, `fieldType`, `helptext`, `options`, `cat`, `userChange`, `title`, `validation`, `ordering`, `default`, `userSee`, `type`) VALUES (NULL, 'INSTANCE_SUSPENDED', '0', 'checkbox', 'Is this instance suspended?', NULL, 'general', '0', 'Instance Suspended', '', '120', '0', '0', 'checkbox'),(NULL, 'INHERIT_PARENT_PERMISSIONS', '1', 'checkbox', 'Inherit permissions from Parent when adding a new item?', NULL, 'permissions', '1', 'Inherit permissions', '', '50', '1', '1', 'checkbox');"
244
"step": "Add new DataType for DataSets",
245
"action": "INSERT INTO `datatype` (`DataTypeID`, `DataType`) VALUES ('5', 'Library Image');"
248
"step": "Update existing DataType",
249
"action": "UPDATE `datatype` SET `DataType` = 'External Image' WHERE `datatype`.`DataTypeID` =4 AND `datatype`.`DataType` = 'Image' LIMIT 1 ;"
252
"step": "Convert existing DataSets",
254
"action": "Xibo\\Upgrade\\DataSetConvertStep"
257
"step": "Remove Layout/DataSet Link Table",
258
"action": "DROP TABLE `lkdatasetlayout`;"
261
"step": "De-dupe any Media/Display Group Assignments",
262
"action": "CREATE TABLE `temp_lkmediadisplaygroup` AS SELECT `mediaid` ,`displaygroupid` FROM `lkmediadisplaygroup` WHERE 1 GROUP BY `mediaid` ,`displaygroupid`; DROP TABLE `lkmediadisplaygroup`; RENAME TABLE `temp_lkmediadisplaygroup` TO `lkmediadisplaygroup`;"
265
"step": "Add Unique Key to Media/Display Group Assignments",
266
"action": "ALTER TABLE `lkmediadisplaygroup` ADD UNIQUE (`mediaid` ,`displaygroupid`);"
269
"step": "Add Unique Key to Campaign/Layout assignments",
270
"action": "ALTER TABLE `lkcampaignlayout` ADD UNIQUE (`CampaignID` ,`LayoutID` ,`DisplayOrder`);"
273
"step": "Upgrade Schedule - Part 1",
274
"action": "CREATE TABLE IF NOT EXISTS `lkscheduledisplaygroup` (`eventId` int(11) NOT NULL,`displayGroupId` int(11) NOT NULL,PRIMARY KEY (`eventId`,`displayGroupId`)) ENGINE=InnoDB DEFAULT CHARSET=utf8;"
277
"step": "Upgrade Schedule - Part 2",
278
"action": "ALTER TABLE `schedule_detail` DROP FOREIGN KEY `schedule_detail_ibfk_8` ;"
281
"step": "Upgrade Schedule - Part 3",
282
"action": "ALTER TABLE `schedule_detail` DROP `DisplayGroupID`;"
285
"step": "Upgrade Schedule - Part 4",
287
"action": "Xibo\\Upgrade\\ScheduleConvertStep"
290
"step": "Upgrade Schedule - Part 5",
291
"action": "ALTER TABLE `schedule` DROP `DisplayGroupIDs`;"
294
"step": "Upgrade Image Module",
295
"action": "UPDATE `module` SET `class` = '\\\\Xibo\\\\Widget\\\\Image' WHERE module = 'Image';"
298
"step": "Upgrade Video Module",
299
"action": "UPDATE `module` SET `class` = '\\\\Xibo\\\\Widget\\\\Video' WHERE module = 'Video';"
302
"step": "Upgrade Flash Module",
303
"action": "UPDATE `module` SET `class` = '\\\\Xibo\\\\Widget\\\\Flash' WHERE module = 'Flash';"
306
"step": "Upgrade PowerPoint Module",
307
"action": "UPDATE `module` SET `class` = '\\\\Xibo\\\\Widget\\\\PowerPoint' WHERE module = 'PowerPoint';"
310
"step": "Upgrade WebPage Module",
311
"action": "UPDATE `module` SET `class` = '\\\\Xibo\\\\Widget\\\\WebPage' WHERE module = 'Webpage';"
314
"step": "Upgrade Ticker Module",
315
"action": "UPDATE `module` SET `class` = '\\\\Xibo\\\\Widget\\\\Ticker' WHERE module = 'Ticker';"
318
"step": "Upgrade Text Module",
319
"action": "UPDATE `module` SET `class` = '\\\\Xibo\\\\Widget\\\\Text' WHERE module = 'Text';"
322
"step": "Upgrade Embedded Module",
323
"action": "UPDATE `module` SET `class` = '\\\\Xibo\\\\Widget\\\\Embedded' WHERE module = 'Embedded';"
326
"step": "Upgrade DataSet View Module",
327
"action": "UPDATE `module` SET `class` = '\\\\Xibo\\\\Widget\\\\DataSetView' WHERE module = 'datasetview';"
330
"step": "Upgrade Shell Command Module",
331
"action": "UPDATE `module` SET `class` = '\\\\Xibo\\\\Widget\\\\ShellCommand' WHERE module = 'shellcommand';"
334
"step": "Upgrade Local Video Module",
335
"action": "UPDATE `module` SET `class` = '\\\\Xibo\\\\Widget\\\\LocalVideo' WHERE module = 'localvideo';"
338
"step": "Upgrade Generic File Module",
339
"action": "UPDATE `module` SET `class` = '\\\\Xibo\\\\Widget\\\\GenericFile' WHERE module = 'genericfile';"
342
"step": "Upgrade Clock Module",
343
"action": "UPDATE `module` SET `class` = '\\\\Xibo\\\\Widget\\\\Clock' WHERE module = 'Clock';"
346
"step": "Upgrade Font Module",
347
"action": "UPDATE `module` SET `class` = '\\\\Xibo\\\\Widget\\\\Font' WHERE module = 'Font';"
350
"step": "Upgrade Twitter Module",
351
"action": "UPDATE `module` SET `class` = '\\\\Xibo\\\\Widget\\\\Twitter' WHERE module = 'Twitter';"
354
"step": "Upgrade Forecast Module",
355
"action": "UPDATE `module` SET `class` = '\\\\Xibo\\\\Widget\\\\ForecastIo' WHERE module = 'forecastio';"
358
"step": "Upgrade Finance Module",
359
"action": "UPDATE `module` SET `class` = '\\\\Xibo\\\\Widget\\\\Finance' WHERE module = 'Finance';"
362
"step": "Set db version so that changes to Users are activated",
363
"action": "UPDATE `version` SET `DBVersion` = 120;"