Files
tiesheng-springboot/springboot-web/src/main/resources/db/migration/tiesheng_init_config.sql
2024-11-21 15:21:58 +08:00

42 lines
1.5 KiB
SQL
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

SET NAMES utf8mb4;
SET FOREIGN_KEY_CHECKS = 0;
CREATE TABLE `core_config_enum`
(
`id` varchar(50) NOT NULL,
`create_time` datetime NOT NULL,
`update_time` datetime NOT NULL,
`is_deleted` int(6) NOT NULL DEFAULT '0',
`type` varchar(50) DEFAULT NULL COMMENT '类型',
`name` varchar(255) DEFAULT NULL COMMENT '名称',
`remark` varchar(500) DEFAULT NULL COMMENT '备注',
`ext` varchar(255) DEFAULT NULL COMMENT '扩展字段',
PRIMARY KEY (`id`)
) ENGINE = InnoDB
DEFAULT CHARSET = utf8mb4
COLLATE = utf8mb4_general_ci COMMENT ='配置-枚举';
CREATE TABLE `core_config_system`
(
`id` varchar(50) NOT NULL,
`create_time` datetime NOT NULL,
`update_time` datetime NOT NULL,
`is_deleted` int(4) NOT NULL DEFAULT '0',
`config_key` varchar(255) NOT NULL,
`config_val` text,
`config_type` int(6) NOT NULL DEFAULT '0' COMMENT '类型:0-文本,1-图片,2-开关',
`remark` varchar(500) DEFAULT NULL COMMENT '说明',
`extra` varchar(255) DEFAULT NULL COMMENT '额外配置',
`read_only` int(6) NOT NULL DEFAULT '0' COMMENT '0-否1-是',
PRIMARY KEY (`id`),
UNIQUE KEY `uni_key` (`config_key`(50)) USING BTREE
) ENGINE = InnoDB
DEFAULT CHARSET = utf8mb4
COLLATE = utf8mb4_general_ci COMMENT ='配置-系统';
alter table core_config_enum
add sort int(10) not null default 0 comment '排序' after name;
SET FOREIGN_KEY_CHECKS = 1;