From 779addfcb462145a786f0b47454b01ee713d0604 Mon Sep 17 00:00:00 2001
From: trom <107225647+see-more@users.noreply.github.com>
Date: Fri, 16 Aug 2024 11:23:44 +0800
Subject: [PATCH] =?UTF-8?q?fix:mysql=E5=8D=87=E7=BA=A7=E5=88=B08.4?=
=?UTF-8?q?=E5=90=8E=E6=9F=A5=E8=AF=A2=E4=BC=9A=E5=87=BA=E9=94=99=EF=BC=8C?=
=?UTF-8?q?=E5=AE=B9=E5=99=A8=E7=9A=84command=E5=9B=9E=E6=98=BE=E4=BD=BF?=
=?UTF-8?q?=E7=94=A8=20text=20area=20(#6147)?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
* style:容器的command参数回显应该使用 text area而不是text input,且不应该过滤'\n'
* chore:prettier格式化
* fix:mysql升级到8.4后,数据库管理 - 当前状态 查询会出错
* chore:修改逻辑判断
---
backend/app/service/database_mysql.go | 5 ++++-
frontend/src/views/container/container/operate/index.vue | 6 +++++-
2 files changed, 9 insertions(+), 2 deletions(-)
diff --git a/backend/app/service/database_mysql.go b/backend/app/service/database_mysql.go
index 07b39b50e..06feef640 100644
--- a/backend/app/service/database_mysql.go
+++ b/backend/app/service/database_mysql.go
@@ -533,7 +533,10 @@ func (u *MysqlService) LoadStatus(req dto.OperationWithNameAndType) (*dto.MysqlS
info.Position = "OFF"
rows, err := executeSqlForRows(app.ContainerName, app.Key, app.Password, "show master status;")
if err != nil {
- return nil, err
+ rows, err = executeSqlForRows(app.ContainerName, app.Key, app.Password, "SHOW BINARY LOG STATUS;")
+ if err != nil {
+ return nil, err
+ }
}
if len(rows) > 2 {
itemValue := strings.Split(rows[1], "\t")
diff --git a/frontend/src/views/container/container/operate/index.vue b/frontend/src/views/container/container/operate/index.vue
index c6aa4dd16..6304eddff 100644
--- a/frontend/src/views/container/container/operate/index.vue
+++ b/frontend/src/views/container/container/operate/index.vue
@@ -201,7 +201,11 @@
-
+