From 7a42996e97148b8d723191802ee3d136eec45589 Mon Sep 17 00:00:00 2001 From: zengqiao Date: Thu, 15 Sep 2022 12:55:06 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E6=97=A5=E5=BF=97=E8=A1=A8?= =?UTF-8?q?=E5=AD=97=E6=AE=B5=E8=BF=87=E7=9F=AD=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- docs/install_guide/版本升级手册.md | 9 +++++++++ km-dist/init/sql/ddl-logi-security.sql | 15 ++++++++------- 2 files changed, 17 insertions(+), 7 deletions(-) diff --git a/docs/install_guide/版本升级手册.md b/docs/install_guide/版本升级手册.md index 75b5ad0c..65fba968 100644 --- a/docs/install_guide/版本升级手册.md +++ b/docs/install_guide/版本升级手册.md @@ -28,6 +28,15 @@ INSERT INTO `logi_security_role_permission` (`role_id`, `permission_id`, `is_del INSERT INTO `logi_security_role_permission` (`role_id`, `permission_id`, `is_delete`, `app_name`) VALUES ('1677', '2010', '0', 'know-streaming'); INSERT INTO `logi_security_role_permission` (`role_id`, `permission_id`, `is_delete`, `app_name`) VALUES ('1677', '3000', '0', 'know-streaming'); +-- 修改字段长度 +ALTER TABLE `logi_security_oplog` + CHANGE COLUMN `operator_ip` `operator_ip` VARCHAR(64) NOT NULL COMMENT '操作者ip' , + CHANGE COLUMN `operator` `operator` VARCHAR(64) NULL DEFAULT NULL COMMENT '操作者账号' , + CHANGE COLUMN `operate_page` `operate_page` VARCHAR(64) NOT NULL DEFAULT '' COMMENT '操作页面' , + CHANGE COLUMN `operate_type` `operate_type` VARCHAR(64) NOT NULL COMMENT '操作类型' , + CHANGE COLUMN `target_type` `target_type` VARCHAR(64) NOT NULL COMMENT '对象分类' , + CHANGE COLUMN `target` `target` VARCHAR(1024) NOT NULL COMMENT '操作对象' , + CHANGE COLUMN `operation_methods` `operation_methods` VARCHAR(64) NOT NULL DEFAULT '' COMMENT '操作方式' ; ``` --- diff --git a/km-dist/init/sql/ddl-logi-security.sql b/km-dist/init/sql/ddl-logi-security.sql index 69fcdc66..3e37e5b0 100644 --- a/km-dist/init/sql/ddl-logi-security.sql +++ b/km-dist/init/sql/ddl-logi-security.sql @@ -33,13 +33,13 @@ DROP TABLE IF EXISTS `logi_security_oplog`; CREATE TABLE `logi_security_oplog` ( id int auto_increment primary key, - operator_ip varchar(20) not null comment '操作者ip', - operator varchar(20) null comment '操作者账号', - operate_page varchar(16) not null default '' comment '操作页面', - operate_type varchar(16) not null comment '操作类型', - target_type varchar(16) not null comment '对象分类', - target varchar(20) not null comment '操作对象', - operation_methods varchar(20) not null default '' comment '操作方式', + operator_ip varchar(64) not null comment '操作者ip', + operator varchar(64) null comment '操作者账号', + operate_page varchar(64) not null default '' comment '操作页面', + operate_type varchar(64) not null comment '操作类型', + target_type varchar(64) not null comment '对象分类', + target varchar(1024) not null comment '操作对象', + operation_methods varchar(64) not null default '' comment '操作方式', detail text null comment '日志详情', create_time timestamp default CURRENT_TIMESTAMP null, update_time timestamp default CURRENT_TIMESTAMP null on update CURRENT_TIMESTAMP comment '更新时间', @@ -47,6 +47,7 @@ CREATE TABLE `logi_security_oplog` app_name varchar(16) null comment '应用名称' ) ENGINE=InnoDB AUTO_INCREMENT=1592 DEFAULT CHARSET=utf8 comment '操作日志'; + DROP TABLE IF EXISTS `logi_security_oplog_extra`; CREATE TABLE `logi_security_oplog_extra` (