mirror of https://github.com/sipwise/db-schema.git
Change-Id: I1113faf6b43f87a0e54f15a589e54a00c44eb518ipeshinskaya/11147
parent
88f528fcb2
commit
816c3fb049
@ -0,0 +1,7 @@
|
||||
use provisioning;
|
||||
set autocommit=0;
|
||||
|
||||
alter table autoprov_devices drop column type ;
|
||||
drop table autoprov_device_extensions;
|
||||
|
||||
commit;
|
@ -0,0 +1,18 @@
|
||||
use provisioning;
|
||||
set autocommit=0;
|
||||
|
||||
alter table autoprov_devices add column type enum('basic','extension') default 'basic',
|
||||
change column bootstrap_method `bootstrap_method` enum('http','redirect_panasonic','redirect_yealink','redirect_polycom') DEFAULT NULL;
|
||||
|
||||
create table if not exists autoprov_device_extensions (
|
||||
`id` int(11) unsigned NOT NULL AUTO_INCREMENT,
|
||||
`device_id` int(11) unsigned NOT NULL,
|
||||
`extension_id` int(11) unsigned NOT NULL,
|
||||
`order` int(11) unsigned,
|
||||
PRIMARY KEY (`id`),
|
||||
KEY `fk_dev_dev_const` (`device_id`),
|
||||
KEY `fk_dev_ext_const` (`extension_id`),
|
||||
CONSTRAINT `fk_dev_dev_const` FOREIGN KEY (`device_id`) REFERENCES `autoprov_devices` (`id`) ON DELETE CASCADE ON UPDATE CASCADE,
|
||||
CONSTRAINT `fk_dev_ext_const` FOREIGN KEY (`extension_id`) REFERENCES `autoprov_devices` (`id`) ON DELETE CASCADE ON UPDATE CASCADE
|
||||
);
|
||||
commit;
|
Loading…
Reference in new issue