From a8b7c3d8c58f2a221aacec296793d65985e2798b Mon Sep 17 00:00:00 2001
From: zhengkunwang223 <31820853+zhengkunwang223@users.noreply.github.com>
Date: Fri, 2 Jun 2023 14:31:19 +0800
Subject: [PATCH] =?UTF-8?q?feat:=20=E5=A2=9E=E5=8A=A0=E4=B8=80=E4=BA=9B?=
=?UTF-8?q?=E6=8F=90=E7=A4=BA=E4=BF=A1=E6=81=AF=20(#1234)?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
Makefile | 7 +++++++
backend/app/service/app.go | 2 +-
frontend/src/lang/modules/en.ts | 2 ++
frontend/src/lang/modules/zh.ts | 1 +
frontend/src/views/app-store/installed/index.vue | 5 +++++
5 files changed, 16 insertions(+), 1 deletion(-)
diff --git a/Makefile b/Makefile
index a01cd7bf1..edcf5aa05 100644
--- a/Makefile
+++ b/Makefile
@@ -10,6 +10,13 @@ WEB_PATH=$(BASE_PAH)/frontend
SERVER_PATH=$(BASE_PAH)/backend
MAIN= $(BASE_PAH)/cmd/server/main.go
APP_NAME=1panel
+ASSERT_PATH= $(BASE_PAH)/cmd/server/web/asserts
+
+clean_asserts:
+ rm -rf $(ASSERT_PATH)
+
+upx_bin:
+ upx $(BUILD_PATH)/$(APP_NAME)
build_frontend:
cd $(WEB_PATH) && npm install && npm run build:dev
diff --git a/backend/app/service/app.go b/backend/app/service/app.go
index 64034b9cb..c2e5102ad 100644
--- a/backend/app/service/app.go
+++ b/backend/app/service/app.go
@@ -812,7 +812,7 @@ func (a AppService) SyncAppListFromRemote() error {
} else {
if d.Status == constant.AppTakeDown {
runtime, _ := runtimeRepo.GetFirst(runtimeRepo.WithDetailId(d.ID))
- if runtime.ID > 0 {
+ if runtime != nil {
continue
}
deleteDetails = append(deleteDetails, d)
diff --git a/frontend/src/lang/modules/en.ts b/frontend/src/lang/modules/en.ts
index eb82dfcc4..47a938414 100644
--- a/frontend/src/lang/modules/en.ts
+++ b/frontend/src/lang/modules/en.ts
@@ -1176,6 +1176,8 @@ const message = {
takeDown: 'TakeDown',
allReadyInstalled: 'Installed',
installHelper: 'Configuring image acceleration can solve the problem of image pull failure',
+ upgradeHelper:
+ 'If the upgrade fails or the abnormal application needs to be synchronized to the normal state first',
},
website: {
website: 'Website',
diff --git a/frontend/src/lang/modules/zh.ts b/frontend/src/lang/modules/zh.ts
index 7bbcf68d0..a091642e8 100644
--- a/frontend/src/lang/modules/zh.ts
+++ b/frontend/src/lang/modules/zh.ts
@@ -1156,6 +1156,7 @@ const message = {
takeDown: '已废弃',
allReadyInstalled: '已安装',
installHelper: '配置镜像加速可以解决镜像拉取失败的问题',
+ upgradeHelper: '升级失败或者异常应用需要先同步到正常状态',
},
website: {
website: '网站',
diff --git a/frontend/src/views/app-store/installed/index.vue b/frontend/src/views/app-store/installed/index.vue
index 45d7494d4..7d4c393ce 100644
--- a/frontend/src/views/app-store/installed/index.vue
+++ b/frontend/src/views/app-store/installed/index.vue
@@ -64,6 +64,11 @@
+