3 migrations (email_mailboxes, email_templates, email_logs), full CRUD for SMTP mailboxes with encrypted passwords (IntegrationSecretCipher), native SMTP connection test via stream_socket_client, sidebar navigation. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
17 lines
807 B
SQL
17 lines
807 B
SQL
CREATE TABLE IF NOT EXISTS `email_mailboxes` (
|
|
`id` INT UNSIGNED NOT NULL AUTO_INCREMENT,
|
|
`name` VARCHAR(100) NOT NULL,
|
|
`smtp_host` VARCHAR(255) NOT NULL,
|
|
`smtp_port` SMALLINT UNSIGNED NOT NULL DEFAULT 587,
|
|
`smtp_encryption` ENUM('tls','ssl','none') NOT NULL DEFAULT 'tls',
|
|
`smtp_username` VARCHAR(255) NOT NULL,
|
|
`smtp_password_encrypted` TEXT NOT NULL,
|
|
`sender_email` VARCHAR(255) NOT NULL,
|
|
`sender_name` VARCHAR(200) DEFAULT NULL,
|
|
`is_default` TINYINT(1) NOT NULL DEFAULT 0,
|
|
`is_active` TINYINT(1) NOT NULL DEFAULT 1,
|
|
`created_at` DATETIME NOT NULL DEFAULT CURRENT_TIMESTAMP,
|
|
`updated_at` DATETIME NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
|
|
PRIMARY KEY (`id`)
|
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
|