Changeset 1526247
- Timestamp:
- 11/01/2016 07:58:31 PM (9 years ago)
- File:
-
- 1 edited
-
swiftad/trunk/swiftad-setup.php (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
swiftad/trunk/swiftad-setup.php
r1493345 r1526247 187 187 188 188 189 190 191 dbDelta("CREATE TABLE {$wpdb->prefix}swiftad_displayad ( 192 id bigint(20) unsigned NOT NULL AUTO_INCREMENT, 193 postid bigint(20) unsigned NOT NULL, 194 status varchar(15) COLLATE utf8mb4_unicode_ci NOT NULL DEFAULT 'live', 195 run int(11) NOT NULL DEFAULT 1, 196 ad_code text COLLATE utf8mb4_unicode_ci NOT NULL, 197 ad_target varchar(16) COLLATE utf8mb4_unicode_ci NOT NULL, 198 ad_size varchar(8) COLLATE utf8mb4_unicode_ci DEFAULT NULL, 199 ad_type varchar(16) COLLATE utf8mb4_unicode_ci DEFAULT NULL, 200 impressions int(11) NOT NULL DEFAULT 0, 201 order_id int(15) NOT NULL DEFAULT 0, 202 lineitem_id int(15) NOT NULL DEFAULT 0, 203 slotid varchar(64) COLLATE utf8mb4_unicode_ci NOT NULL, 204 startdate date NOT NULL, 205 starttime varchar(12) COLLATE utf8mb4_unicode_ci NOT NULL, 206 enddate date NOT NULL, 207 endtime varchar(12) COLLATE utf8mb4_unicode_ci NOT NULL, 208 fc varchar(6) COLLATE utf8mb4_unicode_ci NOT NULL, 209 fc_impressions varchar(8) COLLATE utf8mb4_unicode_ci NOT NULL, 210 fc_howmany varchar(8) COLLATE utf8mb4_unicode_ci NOT NULL, 211 fc_type varchar(16) COLLATE utf8mb4_unicode_ci NOT NULL, 212 fc_lifetime varchar(32) COLLATE utf8mb4_unicode_ci NOT NULL, 213 gd varchar(6) COLLATE utf8mb4_unicode_ci NOT NULL, 214 geo text COLLATE utf8mb4_unicode_ci NOT NULL, 215 post_status varchar(20) COLLATE utf8mb4_unicode_ci NOT NULL DEFAULT 'off', 216 created datetime NOT NULL, 217 timestamp timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP, 218 PRIMARY KEY (id), 219 UNIQUE KEY postid (postid), 220 KEY startdate (startdate), 221 KEY enddate (enddate), 222 KEY status (status) 189 dbDelta("CREATE TABLE {$wpdb->prefix}swiftad_displayad ( 190 id bigint(20) unsigned NOT NULL AUTO_INCREMENT, 191 postid bigint(20) unsigned NOT NULL, 192 status varchar(15) NOT NULL DEFAULT 'live', 193 run int(11) NOT NULL DEFAULT 1, 194 ad_code text NOT NULL, 195 ad_target varchar(16) NOT NULL, 196 ad_size varchar(8) DEFAULT NULL, 197 ad_type varchar(16) DEFAULT NULL, 198 impressions int(11) NOT NULL DEFAULT 0, 199 order_id int(15) NOT NULL DEFAULT 0, 200 lineitem_id int(15) NOT NULL DEFAULT 0, 201 slotid varchar(64) NOT NULL, 202 startdate date NOT NULL, 203 starttime varchar(12) NOT NULL, 204 enddate date NOT NULL, 205 endtime varchar(12) NOT NULL, 206 fc varchar(6) NOT NULL, 207 fc_impressions varchar(8) NOT NULL, 208 fc_howmany varchar(8) NOT NULL, 209 fc_type varchar(16) NOT NULL, 210 fc_lifetime varchar(32) NOT NULL, 211 gd varchar(6) NOT NULL, 212 geo text NOT NULL, 213 post_status varchar(20) NOT NULL DEFAULT 'off', 214 created datetime NOT NULL, 215 timestamp timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP, 216 PRIMARY KEY (id), 217 UNIQUE KEY postid (postid), 218 KEY startdate (startdate), 219 KEY enddate (enddate), 220 KEY status (status) 223 221 ) ".$charset_collate.$engine.";"); 224 222 225 223 226 224 227 dbDelta("CREATE TABLE {$wpdb->prefix}swiftad_inventory (228 id bigint(20) unsigned NOT NULL AUTO_INCREMENT,229 name varchar(64) COLLATE utf8mb4_unicode_ciNOT NULL,230 description text COLLATE utf8mb4_unicode_ciNOT NULL,231 status varchar(15) COLLATE utf8mb4_unicode_ciNOT NULL DEFAULT 'active',232 code varchar(15) COLLATE utf8mb4_unicode_ciNOT NULL,233 size varchar(32) COLLATE utf8mb4_unicode_ciNOT NULL,234 slotid varchar(64) COLLATE utf8mb4_unicode_ciNOT NULL,235 created datetime NOT NULL,236 timestamp timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,237 PRIMARY KEY (id),238 UNIQUE KEY code (code),239 KEY status (status)225 dbDelta("CREATE TABLE {$wpdb->prefix}swiftad_inventory ( 226 id bigint(20) unsigned NOT NULL AUTO_INCREMENT, 227 name varchar(64) NOT NULL, 228 description text NOT NULL, 229 status varchar(15) NOT NULL DEFAULT 'active', 230 code varchar(15) NOT NULL, 231 size varchar(32) NOT NULL, 232 slotid varchar(64) NOT NULL, 233 created datetime NOT NULL, 234 timestamp timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP, 235 PRIMARY KEY (id), 236 UNIQUE KEY code (code), 237 KEY status (status) 240 238 ) ".$charset_collate.$engine.";"); 241 242 243 dbDelta("CREATE TABLE {$wpdb->prefix}swiftad_abtest (244 id bigint(20) unsigned NOT NULL AUTO_INCREMENT,245 name varchar(64) COLLATE utf8mb4_unicode_ciNOT NULL DEFAULT 'A/B Test',246 hypothesis text,247 postid_a bigint(20) unsigned NOT NULL,248 postid_b bigint(20) unsigned NOT NULL,249 run_a int(4) NOT NULL,250 run_b int(4) NOT NULL,251 inventory varchar(64) COLLATE utf8mb4_unicode_ciNULL,252 startdate date NOT NULL,253 starttime varchar(12) NOT NULL,254 enddate date NOT NULL,255 endtime varchar(12) NOT NULL,256 status varchar(15) COLLATE utf8mb4_unicode_ciNOT NULL,257 created datetime NOT NULL,258 timestamp timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,259 PRIMARY KEY (id),260 KEY startdate (startdate),261 KEY enddate (enddate),262 KEY status (status)263 ) ".$charset_collate.$engine.";");264 265 266 267 268 } 269 239 240 241 dbDelta("CREATE TABLE {$wpdb->prefix}swiftad_abtest ( 242 id bigint(20) unsigned NOT NULL AUTO_INCREMENT, 243 name varchar(64) NOT NULL DEFAULT 'A/B Test', 244 hypothesis text, 245 postid_a bigint(20) unsigned NOT NULL, 246 postid_b bigint(20) unsigned NOT NULL, 247 run_a int(4) NOT NULL, 248 run_b int(4) NOT NULL, 249 inventory varchar(64) NULL, 250 startdate date NOT NULL, 251 starttime varchar(12) NOT NULL, 252 enddate date NOT NULL, 253 endtime varchar(12) NOT NULL, 254 status varchar(15) NOT NULL, 255 created datetime NOT NULL, 256 timestamp timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP, 257 PRIMARY KEY (id), 258 KEY startdate (startdate), 259 KEY enddate (enddate), 260 KEY status (status) 261 ) ".$charset_collate.$engine.";"); 262 263 264 265 266 } 267
Note: See TracChangeset
for help on using the changeset viewer.