mirror of
https://github.com/yunionio/cloudpods.git
synced 2026-09-19 10:46:58 +08:00
fix: update fields permission tags
This commit is contained in:
@@ -55,13 +55,13 @@ type SHostnetwork struct {
|
||||
SHostJointsBase
|
||||
|
||||
// 宿主机ID
|
||||
BaremetalId string `width:"36" charset:"ascii" nullable:"false" list:"admin"`
|
||||
BaremetalId string `width:"36" charset:"ascii" nullable:"false" list:"domain"`
|
||||
// 网络ID
|
||||
NetworkId string `width:"36" charset:"ascii" nullable:"false" list:"admin"`
|
||||
NetworkId string `width:"36" charset:"ascii" nullable:"false" list:"domain"`
|
||||
// IP地址
|
||||
IpAddr string `width:"16" charset:"ascii" list:"admin"`
|
||||
IpAddr string `width:"16" charset:"ascii" list:"domain"`
|
||||
// MAC地址
|
||||
MacAddr string `width:"18" charset:"ascii" list:"admin"`
|
||||
MacAddr string `width:"18" charset:"ascii" list:"domain"`
|
||||
}
|
||||
|
||||
func (manager *SHostnetworkManager) GetMasterFieldName() string {
|
||||
|
||||
@@ -62,17 +62,17 @@ type SHoststorage struct {
|
||||
SHostJointsBase
|
||||
|
||||
// 宿主机Id
|
||||
HostId string `width:"36" charset:"ascii" nullable:"false" list:"admin" create:"required" json:"host_id"`
|
||||
HostId string `width:"36" charset:"ascii" nullable:"false" list:"domain" create:"required" json:"host_id"`
|
||||
// 存储Id
|
||||
StorageId string `width:"36" charset:"ascii" nullable:"false" list:"admin" create:"required" json:"storage_id"`
|
||||
StorageId string `width:"36" charset:"ascii" nullable:"false" list:"domain" create:"required" json:"storage_id"`
|
||||
|
||||
// 挂载点
|
||||
MountPoint string `width:"256" charset:"ascii" nullable:"false" list:"admin" update:"admin" create:"required" json:"mount_point"`
|
||||
MountPoint string `width:"256" charset:"ascii" nullable:"false" list:"domain" update:"domain" create:"required" json:"mount_point"`
|
||||
|
||||
// 配置信息
|
||||
Config *jsonutils.JSONArray `nullable:"true" get:"admin" json:"config"`
|
||||
Config *jsonutils.JSONArray `nullable:"true" get:"domain" json:"config"`
|
||||
// 真实容量大小
|
||||
RealCapacity int64 `nullable:"true" list:"admin" json:"real_capacity"`
|
||||
RealCapacity int64 `nullable:"true" list:"domain" json:"real_capacity"`
|
||||
}
|
||||
|
||||
func (manager *SHoststorageManager) GetMasterFieldName() string {
|
||||
|
||||
@@ -55,18 +55,18 @@ func init() {
|
||||
type SHostwire struct {
|
||||
SHostJointsBase
|
||||
|
||||
Bridge string `width:"16" charset:"ascii" nullable:"false" list:"admin" update:"admin" create:"admin_required"`
|
||||
Bridge string `width:"16" charset:"ascii" nullable:"false" list:"domain" update:"domain" create:"domain_required"`
|
||||
// 接口名称
|
||||
Interface string `width:"16" charset:"ascii" nullable:"false" list:"admin" update:"admin" create:"admin_required"`
|
||||
Interface string `width:"16" charset:"ascii" nullable:"false" list:"domain" update:"domain" create:"domain_required"`
|
||||
// 是否是主地址
|
||||
IsMaster bool `nullable:"true" default:"false" list:"admin" update:"admin" create:"admin_optional"`
|
||||
IsMaster bool `nullable:"true" default:"false" list:"domain" update:"domain" create:"domain_optional"`
|
||||
// MAC地址
|
||||
MacAddr string `width:"18" charset:"ascii" list:"admin" update:"admin" create:"admin_required"`
|
||||
MacAddr string `width:"18" charset:"ascii" list:"domain" update:"domain" create:"domain_required"`
|
||||
|
||||
// 宿主机Id
|
||||
HostId string `width:"128" charset:"ascii" nullable:"false" list:"admin" create:"admin_required"`
|
||||
HostId string `width:"128" charset:"ascii" nullable:"false" list:"domain" create:"domain_required"`
|
||||
// 二层网络Id
|
||||
WireId string `width:"128" charset:"ascii" nullable:"false" list:"admin" create:"admin_required"`
|
||||
WireId string `width:"128" charset:"ascii" nullable:"false" list:"domain" create:"domain_required"`
|
||||
}
|
||||
|
||||
func (manager *SHostwireManager) GetMasterFieldName() string {
|
||||
|
||||
@@ -61,9 +61,9 @@ func init() {
|
||||
type SLoadbalancerNetwork struct {
|
||||
db.SVirtualJointResourceBase
|
||||
|
||||
LoadbalancerId string `width:"36" charset:"ascii" nullable:"false" list:"admin"`
|
||||
NetworkId string `width:"36" charset:"ascii" nullable:"false" list:"admin"`
|
||||
IpAddr string `width:"16" charset:"ascii" list:"admin"`
|
||||
LoadbalancerId string `width:"36" charset:"ascii" nullable:"false" list:"user"`
|
||||
NetworkId string `width:"36" charset:"ascii" nullable:"false" list:"user"`
|
||||
IpAddr string `width:"16" charset:"ascii" list:"user"`
|
||||
}
|
||||
|
||||
func (manager *SLoadbalancernetworkManager) GetMasterFieldName() string {
|
||||
|
||||
@@ -39,7 +39,7 @@ import (
|
||||
|
||||
type SManagedResourceBase struct {
|
||||
// 云订阅ID
|
||||
ManagerId string `width:"128" charset:"ascii" nullable:"true" list:"admin" create:"optional"`
|
||||
ManagerId string `width:"128" charset:"ascii" nullable:"true" list:"user" create:"optional"`
|
||||
}
|
||||
|
||||
type SManagedResourceBaseManager struct {
|
||||
|
||||
@@ -57,7 +57,7 @@ type SNetworkinterfacenetwork struct {
|
||||
Primary bool `nullable:"false" list:"user"`
|
||||
IpAddr string `width:"16" charset:"ascii" nullable:"false" list:"user"`
|
||||
NetworkinterfaceId string `width:"36" charset:"ascii" nullable:"false" list:"user" create:"required" index:"true"` // Column(VARCHAR(36, charset='ascii'), nullable=False)
|
||||
NetworkId string `width:"36" charset:"ascii" nullable:"false" list:"admin"`
|
||||
NetworkId string `width:"36" charset:"ascii" nullable:"false" list:"user"`
|
||||
}
|
||||
|
||||
func (manager *SNetworkinterfacenetworkManager) GetMasterFieldName() string {
|
||||
|
||||
Reference in New Issue
Block a user