mirror of
https://github.com/1Panel-dev/1Panel.git
synced 2024-11-24 02:59:16 +08:00
fix: 解决部分应用参数数据库显示错误的问题 (#6136)
This commit is contained in:
parent
dca3c92d72
commit
5134caa103
@ -709,6 +709,22 @@ func (a *AppInstallService) GetParams(id uint) (*response.AppConfig, error) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
appParam.Values = form.Values
|
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)
|
params = append(params, appParam)
|
||||||
} else {
|
} else {
|
||||||
|
Loading…
Reference in New Issue
Block a user