From 3fcb6ec5db5b6abde5c80c591b3288fcd71ce44e Mon Sep 17 00:00:00 2001 From: zhengkunwang <31820853+zhengkunwang223@users.noreply.github.com> Date: Thu, 15 Aug 2024 15:12:28 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E8=A7=A3=E5=86=B3=E9=83=A8=E5=88=86?= =?UTF-8?q?=E5=BA=94=E7=94=A8=E5=8F=82=E6=95=B0=E6=95=B0=E6=8D=AE=E5=BA=93?= =?UTF-8?q?=E6=98=BE=E7=A4=BA=E9=94=99=E8=AF=AF=E7=9A=84=E9=97=AE=E9=A2=98?= =?UTF-8?q?=20(#6136)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- backend/app/service/app_install.go | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/backend/app/service/app_install.go b/backend/app/service/app_install.go index c948a16ad484..210b5b9ed308 100644 --- a/backend/app/service/app_install.go +++ b/backend/app/service/app_install.go @@ -709,6 +709,22 @@ func (a *AppInstallService) GetParams(id uint) (*response.AppConfig, error) { } } appParam.Values = form.Values + } else if form.Type == "apps" { + if m, ok := form.Child.(map[string]interface{}); ok { + result := make(map[string]string) + for key, value := range m { + if strVal, ok := value.(string); ok { + result[key] = strVal + } + } + if envKey, ok := result["envKey"]; ok { + serviceName := envs[envKey] + if serviceName != nil { + appInstall, _ := appInstallRepo.GetFirst(appInstallRepo.WithServiceName(serviceName.(string))) + appParam.ShowValue = appInstall.Name + } + } + } } params = append(params, appParam) } else {