mirror of
https://github.com/TeaOSLab/EdgeCommon.git
synced 2025-11-11 18:30:24 +08:00
用户创建服务时刻自动添加到分组、自动添加统计功能、设置是否需要绑定套餐
This commit is contained in:
@@ -14,6 +14,7 @@ const (
|
|||||||
|
|
||||||
SettingCodeUserUIConfig SettingCode = "userUIConfig" // 用户界面配置
|
SettingCodeUserUIConfig SettingCode = "userUIConfig" // 用户界面配置
|
||||||
SettingCodeUserRegisterConfig SettingCode = "userRegisterConfig" // 用户注册配置
|
SettingCodeUserRegisterConfig SettingCode = "userRegisterConfig" // 用户注册配置
|
||||||
|
SettingCodeUserServerConfig SettingCode = "userServerConfig" // 用户服务设置
|
||||||
|
|
||||||
SettingCodeNSAccessLogSetting SettingCode = "nsAccessLogSetting" // NS相关全局配置
|
SettingCodeNSAccessLogSetting SettingCode = "nsAccessLogSetting" // NS相关全局配置
|
||||||
SettingCodeNSNodeMonitor SettingCode = "nsNodeMonitor" // 监控NS节点状态
|
SettingCodeNSNodeMonitor SettingCode = "nsNodeMonitor" // 监控NS节点状态
|
||||||
|
|||||||
@@ -5,7 +5,6 @@ package userconfigs
|
|||||||
type UserRegisterConfig struct {
|
type UserRegisterConfig struct {
|
||||||
IsOn bool `yaml:"isOn" json:"isOn"` // 是否启用用户注册
|
IsOn bool `yaml:"isOn" json:"isOn"` // 是否启用用户注册
|
||||||
ClusterId int64 `yaml:"clusterId" json:"clusterId"` // 用户创建服务集群
|
ClusterId int64 `yaml:"clusterId" json:"clusterId"` // 用户创建服务集群
|
||||||
ServerGroupIds []int64 `yaml:"serverGroupIds" json:"serverGroupIds"` // 用户注册的服务所在分组
|
|
||||||
ComplexPassword bool `yaml:"complexPassword" json:"complexPassword"` // 必须使用复杂密码
|
ComplexPassword bool `yaml:"complexPassword" json:"complexPassword"` // 必须使用复杂密码
|
||||||
Features []string `yaml:"features" json:"features"` // 默认启用的功能
|
Features []string `yaml:"features" json:"features"` // 默认启用的功能
|
||||||
RequireVerification bool `yaml:"requireVerification" json:"requireVerification"` // 是否需要审核
|
RequireVerification bool `yaml:"requireVerification" json:"requireVerification"` // 是否需要审核
|
||||||
|
|||||||
18
pkg/userconfigs/user_server_config.go
Normal file
18
pkg/userconfigs/user_server_config.go
Normal file
@@ -0,0 +1,18 @@
|
|||||||
|
// Copyright 2022 Liuxiangchao iwind.liu@gmail.com. All rights reserved.
|
||||||
|
|
||||||
|
package userconfigs
|
||||||
|
|
||||||
|
// UserServerConfig 用户服务设置
|
||||||
|
type UserServerConfig struct {
|
||||||
|
GroupId int64 `yaml:"groupId" json:"groupId"` // 分组
|
||||||
|
RequirePlan bool `yaml:"requirePlan" json:"requirePlan"` // 必须使用套餐
|
||||||
|
EnableStat bool `yaml:"enableStat" json:"enableStat"` // 开启统计
|
||||||
|
}
|
||||||
|
|
||||||
|
func DefaultUserServerConfig() *UserServerConfig {
|
||||||
|
return &UserServerConfig{
|
||||||
|
GroupId: 0,
|
||||||
|
RequirePlan: false,
|
||||||
|
EnableStat: true,
|
||||||
|
}
|
||||||
|
}
|
||||||
Reference in New Issue
Block a user