| | |
| | | create table if not exists sys_dept |
| | | ( |
| | | dept_id int8, |
| | | tenant_id varchar(20) not null, |
| | | tenant_id varchar(20) default '000000'::varchar, |
| | | parent_id int8 default 0, |
| | | ancestors varchar(500)default ''::varchar, |
| | | dept_name varchar(30) default ''::varchar, |
| | |
| | | create table if not exists sys_user |
| | | ( |
| | | user_id int8, |
| | | tenant_id varchar(20) not null, |
| | | tenant_id varchar(20) default '000000'::varchar, |
| | | dept_id int8, |
| | | user_name varchar(30) not null, |
| | | nick_name varchar(30) not null, |
| | |
| | | create table if not exists sys_post |
| | | ( |
| | | post_id int8, |
| | | tenant_id varchar(20) not null, |
| | | tenant_id varchar(20) default '000000'::varchar, |
| | | post_code varchar(64) not null, |
| | | post_name varchar(50) not null, |
| | | post_sort int4 not null, |
| | |
| | | create table if not exists sys_role |
| | | ( |
| | | role_id int8, |
| | | tenant_id varchar(20) not null, |
| | | tenant_id varchar(20) default '000000'::varchar, |
| | | role_name varchar(30) not null, |
| | | role_key varchar(100) not null, |
| | | role_sort int4 not null, |
| | |
| | | insert into sys_menu values('6', '系统管理', '0', '2', 'tenant', null, '', '1', '0', 'M', '0', '0', '', 'chart', 103, 1, now(), null, null, '租户管理目录'); |
| | | insert into sys_menu values('2', '系统监控', '0', '3', 'monitor', null, '', '1', '0', 'M', '0', '0', '', 'monitor', 103, 1, now(), null, null, '系统监控目录'); |
| | | insert into sys_menu values('3', '系统工具', '0', '4', 'tool', null, '', '1', '0', 'M', '0', '0', '', 'tool', 103, 1, now(), null, null, '系统工具目录'); |
| | | insert into sys_menu values('4', 'PLUS官网', '0', '5', 'https://gitee.com/JavaLionLi/RuoYi-Vue-Plus', null, '', '0', '0', 'M', '0', '0', '', 'guide', 103, 1, now(), null, null, 'RuoYi-Vue-Plus官网地址'); |
| | | insert into sys_menu values('4', 'PLUS官网', '0', '5', 'https://gitee.com/dromara/RuoYi-Vue-Plus', null, '', '0', '0', 'M', '0', '0', '', 'guide', 103, 1, now(), null, null, 'RuoYi-Vue-Plus官网地址'); |
| | | -- 二级菜单 |
| | | insert into sys_menu values('100', '用户管理', '1', '1', 'user', 'system/user/index', '', '1', '0', 'C', '0', '0', 'system:user:list', 'user', 103, 1, now(), null, null, '用户管理菜单'); |
| | | insert into sys_menu values('101', '角色管理', '1', '2', 'role', 'system/role/index', '', '1', '0', 'C', '0', '0', 'system:role:list', 'peoples', 103, 1, now(), null, null, '角色管理菜单'); |
| | |
| | | create table if not exists sys_oper_log |
| | | ( |
| | | oper_id int8, |
| | | tenant_id varchar(20) not null, |
| | | tenant_id varchar(20) default '000000'::varchar, |
| | | title varchar(50) default ''::varchar, |
| | | business_type int4 default 0, |
| | | method varchar(100) default ''::varchar, |
| | |
| | | create table if not exists sys_dict_type |
| | | ( |
| | | dict_id int8, |
| | | tenant_id varchar(20) not null, |
| | | tenant_id varchar(20) default '000000'::varchar, |
| | | dict_name varchar(100) default ''::varchar, |
| | | dict_type varchar(100) default ''::varchar, |
| | | status char default '0'::bpchar, |
| | |
| | | create table if not exists sys_dict_data |
| | | ( |
| | | dict_code int8, |
| | | tenant_id varchar(20) not null, |
| | | tenant_id varchar(20) default '000000'::varchar, |
| | | dict_sort int4 default 0, |
| | | dict_label varchar(100) default ''::varchar, |
| | | dict_value varchar(100) default ''::varchar, |
| | |
| | | create table if not exists sys_config |
| | | ( |
| | | config_id int8, |
| | | tenant_id varchar(20) not null, |
| | | tenant_id varchar(20) default '000000'::varchar, |
| | | config_name varchar(100) default ''::varchar, |
| | | config_key varchar(100) default ''::varchar, |
| | | config_value varchar(500) default ''::varchar, |
| | |
| | | insert into sys_config values(2, '000000', '用户管理-账号初始密码', 'sys.user.initPassword', '123456', 'Y', 103, 1, now(), null, null, '初始化密码 123456' ); |
| | | insert into sys_config values(3, '000000', '主框架页-侧边栏主题', 'sys.index.sideTheme', 'theme-dark', 'Y', 103, 1, now(), null, null, '深色主题theme-dark,浅色主题theme-light' ); |
| | | insert into sys_config values(5, '000000', '账号自助-是否开启用户注册功能', 'sys.account.registerUser', 'false', 'Y', 103, 1, now(), null, null, '是否开启注册用户功能(true开启,false关闭)'); |
| | | insert into sys_config values(6, '000000', '用户配置-密码最大错误次数', 'sys.user.maxRetryCount', '5', 'Y', 103, 1,now(), null, null, '密码最大错误次数'); |
| | | insert into sys_config values(7, '000000', '用户配置-密码锁定时间', 'sys.user.lockTime', '10', 'Y', 103, 1, now(), null, null, '密码锁定时间(分钟)'); |
| | | insert into sys_config values(8, '000000', '账号自助-短信开关', 'sys.account.smsEnabled', 'false', 'Y', 103, 1, now(), null, null, '是否开启短信功能(true开启,false关闭)'); |
| | | insert into sys_config values(9, '000000', '账号自助-验证码模板id', 'sys.account.templateId', '', 'Y', 103, 1, now(), null, null, '验证码模板id'); |
| | | insert into sys_config values(11, '000000', 'OSS预览列表资源开关', 'sys.oss.previewListResource', 'true', 'Y', 103, 1, now(), null, null, 'true:开启, false:关闭'); |
| | | |
| | | |
| | |
| | | create table if not exists sys_logininfor |
| | | ( |
| | | info_id int8, |
| | | tenant_id varchar(20) not null, |
| | | tenant_id varchar(20) default '000000'::varchar, |
| | | user_name varchar(50) default ''::varchar, |
| | | ipaddr varchar(128) default ''::varchar, |
| | | login_location varchar(255) default ''::varchar, |
| | |
| | | create table if not exists sys_notice |
| | | ( |
| | | notice_id int8, |
| | | tenant_id varchar(20) not null, |
| | | tenant_id varchar(20) default '000000'::varchar, |
| | | notice_title varchar(50) not null, |
| | | notice_type char not null, |
| | | notice_content text, |
| | |
| | | create table if not exists sys_oss |
| | | ( |
| | | oss_id int8, |
| | | tenant_id varchar(20) not null, |
| | | tenant_id varchar(20) default '000000'::varchar, |
| | | file_name varchar(255) default ''::varchar not null, |
| | | original_name varchar(255) default ''::varchar not null, |
| | | file_suffix varchar(10) default ''::varchar not null, |
| | |
| | | create table if not exists sys_oss_config |
| | | ( |
| | | oss_config_id int8, |
| | | tenant_id varchar(20) not null, |
| | | tenant_id varchar(20) default '000000'::varchar, |
| | | config_key varchar(20) default ''::varchar not null, |
| | | access_key varchar(255) default ''::varchar, |
| | | secret_key varchar(255) default ''::varchar, |
| | |
| | | comment on column sys_oss_config.is_https is '是否https(Y=是,N=否)'; |
| | | comment on column sys_oss_config.region is '域'; |
| | | comment on column sys_oss_config.access_policy is '桶权限类型(0=private 1=public 2=custom)'; |
| | | comment on column sys_oss_config.status is '状态(0=正常,1=停用)'; |
| | | comment on column sys_oss_config.status is '是否默认(0=是,1=否)'; |
| | | comment on column sys_oss_config.ext1 is '扩展字段'; |
| | | comment on column sys_oss_config.create_dept is '创建部门'; |
| | | comment on column sys_oss_config.create_by is '创建者'; |