feat: sync httpdns sdk/platform updates without large binaries
This commit is contained in:
@@ -25,20 +25,16 @@ func (this *CreatePopupAction) Init() {
|
||||
func (this *CreatePopupAction) RunGet(params struct{}) {
|
||||
// 检查是否启用了 HTTPDNS 功能(全局用户注册设置中)
|
||||
var hasHTTPDNSFeature = false
|
||||
var defaultHttpdnsClusterId int64 = 0
|
||||
|
||||
resp, err := this.RPC().SysSettingRPC().ReadSysSetting(this.AdminContext(), &pb.ReadSysSettingRequest{Code: systemconfigs.SettingCodeUserRegisterConfig})
|
||||
if err == nil && len(resp.ValueJSON) > 0 {
|
||||
var config = userconfigs.DefaultUserRegisterConfig()
|
||||
if json.Unmarshal(resp.ValueJSON, config) == nil {
|
||||
hasHTTPDNSFeature = config.HTTPDNSIsOn
|
||||
if len(config.HTTPDNSDefaultClusterIds) > 0 {
|
||||
defaultHttpdnsClusterId = config.HTTPDNSDefaultClusterIds[0]
|
||||
}
|
||||
}
|
||||
}
|
||||
this.Data["hasHTTPDNSFeature"] = hasHTTPDNSFeature
|
||||
this.Data["httpdnsClusterId"] = defaultHttpdnsClusterId
|
||||
this.Data["httpdnsClusterId"] = 0
|
||||
|
||||
// 加载所有 HTTPDNS 集群
|
||||
var httpdnsClusters = []maps.Map{}
|
||||
|
||||
Reference in New Issue
Block a user