2013-07-12 15:02:50 +02:00
|
|
|
alter table `domain` add column `ldap_id` int default 0;
|
|
|
|
|
2013-07-24 22:29:28 +02:00
|
|
|
alter table `audit` add column `domain` varchar(128) not null;
|
2013-07-12 15:02:50 +02:00
|
|
|
|
|
|
|
create index `audit_idx5` on `audit`(`domain`);
|
|
|
|
|
2013-07-31 09:10:26 +02:00
|
|
|
alter table archiving_rule add column domain varchar(255) default null;
|
|
|
|
alter table retention_rule add column domain varchar(255) default null;
|
|
|
|
|
2013-07-31 10:57:45 +02:00
|
|
|
alter table retention_rule drop index `from`;
|
|
|
|
create unique index `entry` on retention_rule (`domain`,`from`,`to`,`subject`,`_size`,`size`,`attachment_type`,`_attachment_size`,`attachment_size`,`spam`);
|
2013-07-31 09:10:26 +02:00
|
|
|
|
2013-08-02 12:30:09 +02:00
|
|
|
drop view if exists `v_messages`;
|
|
|
|
create view `v_messages` AS select `metadata`.`id` AS `id`,`metadata`.`piler_id` AS `piler_id`,`metadata`.`from` AS `from`,`metadata`.`fromdomain` AS `fromdomain`,`rcpt`.`to` AS `to`,`rcpt`.`todomain` AS `todomain`,`metadata`.`subject` AS `subject`, `metadata`.`size` AS `size`, `metadata`.`direction` AS `direction`, `metadata`.`sent` AS `sent`, `metadata`.`retained` AS `retained`, `metadata`.`arrived` AS `arrived`, `metadata`.`digest` AS `digest`, `metadata`.`bodydigest` AS `bodydigest` from (`metadata` join `rcpt`) where (`metadata`.`id` = `rcpt`.`id`);
|
|
|
|
|
2013-08-06 06:36:56 +02:00
|
|
|
update user_settings set theme='mobile' where theme='orig';
|
|
|
|
|
2013-07-12 15:02:50 +02:00
|
|
|
create table if not exists `ldap` (
|
|
|
|
`id` int not null auto_increment primary key,
|
|
|
|
`description` varchar(255) not null,
|
|
|
|
`ldap_type` varchar(255) not null,
|
|
|
|
`ldap_host` varchar(255) not null,
|
|
|
|
`ldap_base_dn` varchar(255) not null,
|
|
|
|
`ldap_bind_dn` varchar(255) not null,
|
2013-07-23 22:44:34 +02:00
|
|
|
`ldap_bind_pw` varchar(255) not null,
|
|
|
|
`ldap_auditor_member_dn` varchar(255) default null
|
2013-07-12 15:02:50 +02:00
|
|
|
) Engine=InnoDB;
|
|
|
|
|
2013-07-16 07:36:48 +02:00
|
|
|
create table if not exists `customer_settings` (
|
2013-07-23 22:44:34 +02:00
|
|
|
`id` int not null auto_increment primary key,
|
2013-07-16 07:36:48 +02:00
|
|
|
`domain` varchar(255) not null unique,
|
|
|
|
`branding_text` varchar(255) default null,
|
|
|
|
`branding_url` varchar(255) default null,
|
2013-07-18 17:13:49 +02:00
|
|
|
`branding_logo` varchar(255) default null,
|
2013-07-16 07:36:48 +02:00
|
|
|
`support_link` varchar(255) default null,
|
2013-08-09 22:11:16 +02:00
|
|
|
`background_colour` varchar(255) default null,
|
|
|
|
`text_colour` varchar(255) default null
|
2013-07-24 22:14:05 +02:00
|
|
|
) Engine=InnoDB;
|
2013-07-12 15:02:50 +02:00
|
|
|
|
2013-07-24 22:14:05 +02:00
|
|
|
create table if not exists `online` (
|
2013-07-25 14:38:44 +02:00
|
|
|
`username` varchar(255) not null,
|
2013-07-24 22:14:05 +02:00
|
|
|
`ts` int default 0,
|
|
|
|
`last_activity` int default 0,
|
2013-07-25 14:38:44 +02:00
|
|
|
`ipaddr` varchar(255) default null,
|
|
|
|
unique(`username`,`ipaddr`)
|
2013-07-24 22:14:05 +02:00
|
|
|
) Engine=InnoDB;
|
2013-07-12 15:02:50 +02:00
|
|
|
|
2013-08-25 21:57:04 +02:00
|
|
|
create table if not exists `import` (
|
|
|
|
`id` int not null auto_increment primary key,
|
|
|
|
`type` varchar(255) not null,
|
|
|
|
`username` varchar(255) not null,
|
|
|
|
`password` varchar(255) not null,
|
|
|
|
`server` varchar(255) not null,
|
|
|
|
`created` int default 0,
|
|
|
|
`started` int default 0,
|
|
|
|
`finished` int default 0,
|
|
|
|
`updated` int default 0,
|
|
|
|
`status` int default 0,
|
|
|
|
`total` int default 0,
|
|
|
|
`imported` int default 0,
|
|
|
|
`duplicate` int default 0,
|
|
|
|
`error` int default 0,
|
|
|
|
`cleared` int default 0
|
|
|
|
) Engine=InnoDB;
|
|
|
|
|