init
This commit is contained in:
62
RuoYi-Vue/sql/module_management.sql
Normal file
62
RuoYi-Vue/sql/module_management.sql
Normal file
@@ -0,0 +1,62 @@
|
||||
-- ----------------------------
|
||||
-- 1、功能模块表
|
||||
-- ----------------------------
|
||||
drop table if exists sys_module;
|
||||
create table sys_module (
|
||||
module_id bigint(20) not null auto_increment comment '模块id',
|
||||
module_name varchar(50) not null comment '模块名称',
|
||||
module_alias varchar(50) default '' comment '模块别名',
|
||||
module_desc varchar(500) default '' comment '模块描述',
|
||||
status char(1) default '0' comment '状态(0正常 1停用)',
|
||||
del_flag char(1) default '0' comment '删除标志(0代表存在 2代表删除)',
|
||||
create_by varchar(64) default '' comment '创建者',
|
||||
create_time datetime comment '创建时间',
|
||||
update_by varchar(64) default '' comment '更新者',
|
||||
update_time datetime comment '更新时间',
|
||||
remark varchar(500) default null comment '备注',
|
||||
primary key (module_id)
|
||||
) engine=innodb auto_increment=100 comment = '功能模块表';
|
||||
|
||||
-- ----------------------------
|
||||
-- 2、代码片段管理表
|
||||
-- ----------------------------
|
||||
drop table if exists sys_code_snippet;
|
||||
create table sys_code_snippet (
|
||||
snippet_id bigint(20) not null auto_increment comment '代码片段id',
|
||||
module_id bigint(20) not null comment '功能模块id',
|
||||
snippet_content text not null comment '代码片段内容',
|
||||
insert_point varchar(255) default '' comment '插入点',
|
||||
param1 varchar(255) default null comment '参数1',
|
||||
param2 varchar(255) default null comment '参数2',
|
||||
param3 varchar(255) default null comment '参数3',
|
||||
param4 varchar(255) default null comment '参数4',
|
||||
param5 varchar(255) default null comment '参数5',
|
||||
status char(1) default '0' comment '状态(0正常 1停用)',
|
||||
del_flag char(1) default '0' comment '删除标志(0代表存在 2代表删除)',
|
||||
create_by varchar(64) default '' comment '创建者',
|
||||
create_time datetime comment '创建时间',
|
||||
update_by varchar(64) default '' comment '更新者',
|
||||
update_time datetime comment '更新时间',
|
||||
remark varchar(500) default null comment '备注',
|
||||
primary key (snippet_id),
|
||||
foreign key (module_id) references sys_module(module_id)
|
||||
) engine=innodb auto_increment=100 comment = '代码片段管理表';
|
||||
|
||||
-- ----------------------------
|
||||
-- 3、功能模块与项目关系表
|
||||
-- ----------------------------
|
||||
drop table if exists sys_project_module;
|
||||
create table sys_project_module (
|
||||
id bigint(20) not null auto_increment comment 'id',
|
||||
project_id bigint(20) not null comment '项目id',
|
||||
module_id bigint(20) not null comment '功能模块id',
|
||||
status char(1) default '0' comment '状态(0正常 1停用)',
|
||||
create_by varchar(64) default '' comment '创建者',
|
||||
create_time datetime comment '创建时间',
|
||||
update_by varchar(64) default '' comment '更新者',
|
||||
update_time datetime comment '更新时间',
|
||||
remark varchar(500) default null comment '备注',
|
||||
primary key (id),
|
||||
unique key idx_project_module (project_id, module_id),
|
||||
foreign key (module_id) references sys_module(module_id)
|
||||
) engine=innodb auto_increment=100 comment = '功能模块与项目关系表';
|
||||
Reference in New Issue
Block a user