From c82bde97920aefc0a4f6eed6eadce9faa0882b2f Mon Sep 17 00:00:00 2001 From: 疯狂的狮子Li <15040126243@163.com> Date: 星期一, 13 三月 2023 23:41:16 +0800 Subject: [PATCH] fix 修复 关闭租户后 插入数据报无租户ID问题 使用默认值兼容 --- script/sql/ry_vue_5.X.sql | 24 ++++++++++++------------ 1 files changed, 12 insertions(+), 12 deletions(-) diff --git a/script/sql/ry_vue_5.X.sql b/script/sql/ry_vue_5.X.sql index 430e882..8232cbd 100644 --- a/script/sql/ry_vue_5.X.sql +++ b/script/sql/ry_vue_5.X.sql @@ -62,7 +62,7 @@ drop table if exists sys_dept; create table sys_dept ( dept_id bigint(20) not null comment '閮ㄩ棬id', - tenant_id varchar(20) not null comment '绉熸埛缂栧彿', + tenant_id varchar(20) default '000000' comment '绉熸埛缂栧彿', parent_id bigint(20) default 0 comment '鐖堕儴闂╥d', ancestors varchar(500) default '' comment '绁栫骇鍒楄〃', dept_name varchar(30) default '' comment '閮ㄩ棬鍚嶇О', @@ -103,7 +103,7 @@ drop table if exists sys_user; create table sys_user ( user_id bigint(20) not null comment '鐢ㄦ埛ID', - tenant_id varchar(20) not null comment '绉熸埛缂栧彿', + tenant_id varchar(20) default '000000' comment '绉熸埛缂栧彿', dept_id bigint(20) default null comment '閮ㄩ棬ID', user_name varchar(30) not null comment '鐢ㄦ埛璐﹀彿', nick_name varchar(30) not null comment '鐢ㄦ埛鏄电О', @@ -140,7 +140,7 @@ create table sys_post ( post_id bigint(20) not null comment '宀椾綅ID', - tenant_id varchar(20) not null comment '绉熸埛缂栧彿', + tenant_id varchar(20) default '000000' comment '绉熸埛缂栧彿', post_code varchar(64) not null comment '宀椾綅缂栫爜', post_name varchar(50) not null comment '宀椾綅鍚嶇О', post_sort int(4) not null comment '鏄剧ず椤哄簭', @@ -169,7 +169,7 @@ drop table if exists sys_role; create table sys_role ( role_id bigint(20) not null comment '瑙掕壊ID', - tenant_id varchar(20) not null comment '绉熸埛缂栧彿', + tenant_id varchar(20) default '000000' comment '绉熸埛缂栧彿', role_name varchar(30) not null comment '瑙掕壊鍚嶇О', role_key varchar(100) not null comment '瑙掕壊鏉冮檺瀛楃涓�', role_sort int(4) not null comment '鏄剧ず椤哄簭', @@ -498,7 +498,7 @@ drop table if exists sys_oper_log; create table sys_oper_log ( oper_id bigint(20) not null comment '鏃ュ織涓婚敭', - tenant_id varchar(20) not null comment '绉熸埛缂栧彿', + tenant_id varchar(20) default '000000' comment '绉熸埛缂栧彿', title varchar(50) default '' comment '妯″潡鏍囬', business_type int(2) default 0 comment '涓氬姟绫诲瀷锛�0鍏跺畠 1鏂板 2淇敼 3鍒犻櫎锛�', method varchar(100) default '' comment '鏂规硶鍚嶇О', @@ -529,7 +529,7 @@ create table sys_dict_type ( dict_id bigint(20) not null comment '瀛楀吀涓婚敭', - tenant_id varchar(20) not null comment '绉熸埛缂栧彿', + tenant_id varchar(20) default '000000' comment '绉熸埛缂栧彿', dict_name varchar(100) default '' comment '瀛楀吀鍚嶇О', dict_type varchar(100) default '' comment '瀛楀吀绫诲瀷', status char(1) default '0' comment '鐘舵�侊紙0姝e父 1鍋滅敤锛�', @@ -560,7 +560,7 @@ create table sys_dict_data ( dict_code bigint(20) not null comment '瀛楀吀缂栫爜', - tenant_id varchar(20) not null comment '绉熸埛缂栧彿', + tenant_id varchar(20) default '000000' comment '绉熸埛缂栧彿', dict_sort int(4) default 0 comment '瀛楀吀鎺掑簭', dict_label varchar(100) default '' comment '瀛楀吀鏍囩', dict_value varchar(100) default '' comment '瀛楀吀閿��', @@ -611,7 +611,7 @@ drop table if exists sys_config; create table sys_config ( config_id bigint(20) not null comment '鍙傛暟涓婚敭', - tenant_id varchar(20) not null comment '绉熸埛缂栧彿', + tenant_id varchar(20) default '000000' comment '绉熸埛缂栧彿', config_name varchar(100) default '' comment '鍙傛暟鍚嶇О', config_key varchar(100) default '' comment '鍙傛暟閿悕', config_value varchar(500) default '' comment '鍙傛暟閿��', @@ -638,7 +638,7 @@ drop table if exists sys_logininfor; create table sys_logininfor ( info_id bigint(20) not null comment '璁块棶ID', - tenant_id varchar(20) not null comment '绉熸埛缂栧彿', + tenant_id varchar(20) default '000000' comment '绉熸埛缂栧彿', user_name varchar(50) default '' comment '鐢ㄦ埛璐﹀彿', ipaddr varchar(128) default '' comment '鐧诲綍IP鍦板潃', login_location varchar(255) default '' comment '鐧诲綍鍦扮偣', @@ -659,7 +659,7 @@ drop table if exists sys_notice; create table sys_notice ( notice_id bigint(20) not null comment '鍏憡ID', - tenant_id varchar(20) not null comment '绉熸埛缂栧彿', + tenant_id varchar(20) default '000000' comment '绉熸埛缂栧彿', notice_title varchar(50) not null comment '鍏憡鏍囬', notice_type char(1) not null comment '鍏憡绫诲瀷锛�1閫氱煡 2鍏憡锛�', notice_content longblob default null comment '鍏憡鍐呭', @@ -747,7 +747,7 @@ drop table if exists sys_oss; create table sys_oss ( oss_id bigint(20) not null comment '瀵硅薄瀛樺偍涓婚敭', - tenant_id varchar(20) not null comment '绉熸埛缂栧彿', + tenant_id varchar(20) default '000000' comment '绉熸埛缂栧彿', file_name varchar(255) not null default '' comment '鏂囦欢鍚�', original_name varchar(255) not null default '' comment '鍘熷悕', file_suffix varchar(10) not null default '' comment '鏂囦欢鍚庣紑鍚�', @@ -767,7 +767,7 @@ drop table if exists sys_oss_config; create table sys_oss_config ( oss_config_id bigint(20) not null comment '涓诲缓', - tenant_id varchar(20) not null comment '绉熸埛缂栧彿', + tenant_id varchar(20) default '000000'comment '绉熸埛缂栧彿', config_key varchar(20) not null default '' comment '閰嶇疆key', access_key varchar(255) default '' comment 'accessKey', secret_key varchar(255) default '' comment '绉橀挜', -- Gitblit v1.9.3