Documentation ¶
Index ¶
- func RandLabel() string
- func RandName() string
- func RandUID() string
- func SortStringsAndCheck(sl []string) (ok bool)
- func StringSliceHas(sl []string, v string) bool
- type ApplyRulesBody
- type BoolRes
- type CacheLabelsInfoRes
- type ConsolePagination
- type Group
- type GroupBody
- type GroupMember
- type GroupMembersRes
- type GroupMembersURL
- type GroupPaginationURL
- type GroupRes
- type GroupURL
- type GroupUpdateBody
- type GroupsBody
- type GroupsRes
- type GroupsURL
- type HIDRuleHIDURL
- type LabelBody
- type LabelGroupInfo
- type LabelGroupsInfoRes
- type LabelGroupsRes
- type LabelInfo
- type LabelInfoRes
- type LabelReleaseInfo
- type LabelReleaseInfoRes
- type LabelRuleBody
- type LabelRuleInfo
- type LabelRuleInfoRes
- type LabelRulesInfoRes
- type LabelUpdateBody
- type LabelUserInfo
- type LabelUsersInfoRes
- type LabelUsersRes
- type LabelsInfoRes
- type LogProductLabelPaginationURL
- type LogProductModuleSettingURL
- type Module
- type ModuleInfo
- type ModuleInfoRes
- type ModuleUpdateBody
- type ModulesInfoRes
- type MyLabel
- type MyLabelsRes
- type MySetting
- type MySettingsQueryURL
- type MySettingsQueryURLClient
- type MySettingsRes
- type NameDescBody
- type OperationLogListItem
- type OperationLogListReq
- type OperationLogListRes
- type Pagination
- type PercentRule
- type Product
- type ProductLabelHIDURL
- type ProductLabelPaginationURL
- type ProductLabelUIDURL
- type ProductLabelURL
- type ProductModuleSettingHIDURL
- type ProductModuleSettingUIDURL
- type ProductModuleSettingURL
- type ProductModuleURL
- type ProductPaginationURL
- type ProductRes
- type ProductStatistics
- type ProductStatisticsRes
- type ProductURL
- type ProductUpdateBody
- type ProductsRes
- type RecallBody
- type Search
- type SettingBody
- type SettingGroupInfo
- type SettingGroupsInfoRes
- type SettingInfo
- type SettingInfoRes
- type SettingReleaseInfo
- type SettingReleaseInfoRes
- type SettingRuleBody
- type SettingRuleInfo
- type SettingRuleInfoRes
- type SettingRulesInfoRes
- type SettingUpdateBody
- type SettingUserInfo
- type SettingUsersInfoRes
- type SettingsInfoRes
- type StringRes
- type SuccessResponseType
- type UIDHIDURL
- type UIDPaginationURL
- type UIDProductURL
- type UIDURL
- type UidsBody
- type UrbsAcAclAddBody
- type UrbsAcAclCheckBody
- type UrbsAcAclURL
- type UrbsAcUserBody
- type UrbsAcUserListRes
- type UrbsAcUserUidUrl
- type UrbsAcUserUpdateBody
- type UrbsAcUserUrl
- type UrbsAcUsersBody
- type UrbsSettingUser
- type User
- type UserRes
- type UsersBody
- type UsersGroupsBody
- type UsersRes
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func SortStringsAndCheck ¶
SortStringsAndCheck sort string slice and check empty or duplicate value.
Types ¶
type ApplyRulesBody ¶ added in v0.10.0
ApplyRulesBody ...
func (*ApplyRulesBody) Validate ¶ added in v0.10.0
func (t *ApplyRulesBody) Validate() error
Validate 实现 gear.BodyTemplate。
type CacheLabelsInfoRes ¶ added in v0.9.0
type CacheLabelsInfoRes struct { SuccessResponseType Timestamp int64 `json:"timestamp"` // labels 数组生成时间 Result []schema.UserCacheLabel `json:"result"` // 空数组也保留 }
CacheLabelsInfoRes ...
type ConsolePagination ¶ added in v0.4.0
type ConsolePagination struct { Search PageToken string `json:"pageToken" query:"pageToken"` Skip int `json:"skip,omitempty" query:"skip"` PageSize int `json:"pageSize,omitempty" query:"pageSize"` }
ConsolePagination 分页
func (*ConsolePagination) GetNextPageToken ¶ added in v0.4.0
func (pg *ConsolePagination) GetNextPageToken() string
GetNextPageToken ...
func (*ConsolePagination) Validate ¶ added in v0.4.0
func (pg *ConsolePagination) Validate() error
Validate ...
type Group ¶ added in v0.3.0
type Group struct { CreatedAt time.Time `json:"createdAt"` UpdatedAt time.Time `json:"updatedAt"` SyncAt int64 `json:"syncAt"` UID string `json:"uid"` Kind string `json:"kind"` Desc string `json:"desc"` Status int64 `json:"status"` }
Group ...
type GroupBody ¶
type GroupBody struct { UID string `json:"uid"` Kind string `json:"kind"` Desc string `json:"desc"` }
GroupBody ...
type GroupMember ¶ added in v0.3.0
type GroupMember struct { User string `json:"user"` CreatedAt time.Time `json:"createdAt"` SyncAt int64 `json:"syncAt"` // 归属关系同步时间戳,1970 以来的秒数,应该与 group.syncAt 相等 }
GroupMember ...
type GroupMembersRes ¶ added in v0.3.0
type GroupMembersRes struct { SuccessResponseType Result []GroupMember `json:"result"` }
GroupMembersRes ...
type GroupMembersURL ¶
type GroupMembersURL struct { Kind string `json:"kind" query:"kind"` UID string `json:"uid" param:"uid"` User string `json:"user" query:"user"` // 根据用户 uid 删除一个成员 SyncLt int64 `json:"syncLt" query:"syncLt"` // 或根据 syncLt 删除同步时间小于指定值的所有成员 }
GroupMembersURL ...
func (*GroupMembersURL) Validate ¶
func (t *GroupMembersURL) Validate() error
Validate 实现 gear.BodyTemplate。
type GroupPaginationURL ¶ added in v1.2.0
type GroupPaginationURL struct { Pagination UID string `json:"uid" param:"uid"` Kind string `json:"kind" query:"kind"` }
GroupPaginationURL ...
func (*GroupPaginationURL) Validate ¶ added in v1.2.0
func (t *GroupPaginationURL) Validate() error
Validate 实现 gear.BodyTemplate。
type GroupRes ¶ added in v0.3.0
type GroupRes struct { SuccessResponseType Result Group `json:"result"` }
GroupRes ...
type GroupUpdateBody ¶
type GroupUpdateBody struct {
Desc *string `json:"desc"`
}
GroupUpdateBody ...
func (*GroupUpdateBody) Validate ¶
func (t *GroupUpdateBody) Validate() error
Validate 实现 gear.BodyTemplate。
type GroupsRes ¶ added in v0.3.0
type GroupsRes struct { SuccessResponseType Result []Group `json:"result"` }
GroupsRes ...
type GroupsURL ¶
type GroupsURL struct { Pagination Kind string `json:"kind" query:"kind"` }
GroupsURL ...
type HIDRuleHIDURL ¶ added in v0.3.0
type HIDRuleHIDURL struct { HID string `json:"hid" param:"hid"` RuleHID string `json:"ruleHID" param:"ruleHID"` }
HIDRuleHIDURL ...
func (*HIDRuleHIDURL) Validate ¶ added in v0.3.0
func (t *HIDRuleHIDURL) Validate() error
Validate 实现 gear.BodyTemplate。
type LabelBody ¶
type LabelBody struct { UidsBody Name string `json:"name"` Desc string `json:"desc"` Channels *[]string `json:"channels"` Clients *[]string `json:"clients"` }
LabelBody ...
type LabelGroupInfo ¶ added in v0.3.0
type LabelGroupInfo struct { ID int64 `json:"-"` LabelHID string `json:"labelHID"` AssignedAt time.Time `json:"assignedAt"` Release int64 `json:"release"` Group string `json:"group"` Kind string `json:"kind"` Desc string `json:"desc"` Status int64 `json:"status"` }
LabelGroupInfo ...
type LabelGroupsInfoRes ¶ added in v0.3.0
type LabelGroupsInfoRes struct { SuccessResponseType Result []LabelGroupInfo `json:"result"` }
LabelGroupsInfoRes ...
type LabelGroupsRes ¶ added in v0.3.0
type LabelGroupsRes struct { SuccessResponseType Result []*Group `json:"result"` }
LabelGroupsRes ...
type LabelInfo ¶ added in v0.3.0
type LabelInfo struct { ID int64 `json:"-"` HID string `json:"hid"` Product string `json:"product"` Name string `json:"name"` Desc string `json:"desc"` Channels []string `json:"channels"` Clients []string `json:"clients"` Status int64 `json:"status"` Release int64 `json:"release"` CreatedAt time.Time `json:"createdAt"` UpdatedAt time.Time `json:"updatedAt"` OfflineAt *time.Time `json:"offlineAt"` Users []*User `json:"users"` }
LabelInfo ...
type LabelInfoRes ¶ added in v0.3.0
type LabelInfoRes struct {
Result LabelInfo `json:"result"`
}
LabelInfoRes ...
type LabelReleaseInfo ¶ added in v0.3.0
type LabelReleaseInfo struct { Release int64 `json:"release"` Users []string `json:"users"` Groups []string `json:"groups"` }
LabelReleaseInfo ...
type LabelReleaseInfoRes ¶ added in v0.3.0
type LabelReleaseInfoRes struct { SuccessResponseType Result LabelReleaseInfo `json:"result"` // 空数组也保留 }
LabelReleaseInfoRes ...
type LabelRuleBody ¶ added in v0.3.0
type LabelRuleBody struct { PercentRule Desc string `json:"desc"` // 操作说明 }
LabelRuleBody ...
type LabelRuleInfo ¶ added in v0.3.0
type LabelRuleInfo struct { ID int64 `json:"-"` HID string `json:"hid"` LabelHID string `json:"labelHID"` Kind string `json:"kind"` Rule interface{} `json:"rule"` Release int64 `json:"release"` CreatedAt time.Time `json:"createdAt"` UpdatedAt time.Time `json:"updatedAt"` }
LabelRuleInfo ...
type LabelRuleInfoRes ¶ added in v0.3.0
type LabelRuleInfoRes struct { SuccessResponseType Result LabelRuleInfo `json:"result"` // 空数组也保留 }
LabelRuleInfoRes ...
type LabelRulesInfoRes ¶ added in v0.3.0
type LabelRulesInfoRes struct { SuccessResponseType Result []LabelRuleInfo `json:"result"` // 空数组也保留 }
LabelRulesInfoRes ...
type LabelUpdateBody ¶
type LabelUpdateBody struct { Desc *string `json:"desc"` Channels *[]string `json:"channels"` Clients *[]string `json:"clients"` *UidsBody }
LabelUpdateBody ...
func (*LabelUpdateBody) Validate ¶
func (t *LabelUpdateBody) Validate() error
Validate 实现 gear.BodyTemplate。
type LabelUserInfo ¶ added in v0.3.0
type LabelUserInfo struct { ID int64 `json:"-"` LabelHID string `json:"labelHID"` AssignedAt time.Time `json:"assignedAt"` Release int64 `json:"release"` User string `json:"user"` }
LabelUserInfo ...
type LabelUsersInfoRes ¶ added in v0.3.0
type LabelUsersInfoRes struct { SuccessResponseType Result []LabelUserInfo `json:"result"` }
LabelUsersInfoRes ...
type LabelUsersRes ¶ added in v0.3.0
type LabelUsersRes struct { SuccessResponseType Result []*User `json:"result"` }
LabelUsersRes ...
type LabelsInfoRes ¶ added in v0.3.0
type LabelsInfoRes struct { SuccessResponseType Result []*LabelInfo `json:"result"` }
LabelsInfoRes ...
type LogProductLabelPaginationURL ¶ added in v0.4.0
type LogProductLabelPaginationURL struct { ConsolePagination ProductURL Label string `json:"label" param:"label"` }
LogProductLabelPaginationURL ...
func (*LogProductLabelPaginationURL) Validate ¶ added in v0.4.0
func (t *LogProductLabelPaginationURL) Validate() error
Validate 实现 gear.BodyTemplate。
type LogProductModuleSettingURL ¶ added in v0.4.0
type LogProductModuleSettingURL struct { ConsolePagination ProductURL Module string `json:"module" param:"module"` Setting string `json:"setting" param:"setting"` }
LogProductModuleSettingURL ...
func (*LogProductModuleSettingURL) Validate ¶ added in v0.4.0
func (t *LogProductModuleSettingURL) Validate() error
Validate 实现 gear.BodyTemplate。
type Module ¶ added in v0.3.0
type Module struct { CreatedAt time.Time `json:"createdAt"` UpdatedAt time.Time `json:"updatedAt"` OfflineAt *time.Time `json:"offlineAt"` Name string `json:"name"` Desc string `json:"desc"` Status int64 `json:"status"` }
Module ...
type ModuleInfo ¶ added in v0.3.0
ModuleInfo ...
type ModuleInfoRes ¶ added in v0.3.0
type ModuleInfoRes struct { SuccessResponseType Result ModuleInfo `json:"result"` }
ModuleInfoRes ...
type ModuleUpdateBody ¶
ModuleUpdateBody ...
func (*ModuleUpdateBody) Validate ¶
func (t *ModuleUpdateBody) Validate() error
Validate 实现 gear.BodyTemplate。
type ModulesInfoRes ¶ added in v0.3.0
type ModulesInfoRes struct { SuccessResponseType Result []*ModuleInfo `json:"result"` }
ModulesInfoRes ...
type MyLabel ¶ added in v0.3.0
type MyLabel struct { ID int64 `json:"-"` HID string `json:"hid"` Product string `json:"product"` Name string `json:"name"` Desc string `json:"desc"` Release int64 `json:"release"` AssignedAt time.Time `json:"assignedAt"` }
MyLabel ...
type MyLabelsRes ¶ added in v0.3.0
type MyLabelsRes struct { SuccessResponseType Result []*MyLabel `json:"result"` // 空数组也保留 }
MyLabelsRes ...
type MySetting ¶ added in v0.3.0
type MySetting struct { HID string `json:"hid,omitempty"` Product string `json:"product"` Module string `json:"module"` Name string `json:"name"` Desc string `json:"desc,omitempty"` Value string `json:"value"` LastValue string `json:"lastValue,omitempty"` Release int64 `json:"release,omitempty"` AssignedAt time.Time `json:"assignedAt"` UpdatedAt time.Time `json:"updated_at,omitempty"` //兼容 }
MySetting ...
type MySettingsQueryURL ¶
type MySettingsQueryURL struct { Pagination Kind string `json:"kind" query:"kind"` UID string `json:"uid" param:"uid"` Product string `json:"product" query:"product"` Module string `json:"module" query:"module"` Setting string `json:"setting" query:"setting"` Channel string `json:"channel" query:"channel"` Client string `json:"client" query:"client"` WithLabel bool `json:"withLabel" query:"withLabel"` }
MySettingsQueryURL ...
func (*MySettingsQueryURL) Validate ¶
func (t *MySettingsQueryURL) Validate() error
Validate 实现 gear.BodyTemplate。
type MySettingsQueryURLClient ¶
type MySettingsQueryURLClient struct { Pagination Product string `json:"product" query:"product"` Channel string `json:"channel" query:"channel"` Client string `json:"client" query:"client"` }
MySettingsQueryURLClient ...
func (*MySettingsQueryURLClient) Validate ¶
func (t *MySettingsQueryURLClient) Validate() error
Validate 实现 gear.BodyTemplate。
type MySettingsRes ¶ added in v0.3.0
type MySettingsRes struct { SuccessResponseType Result []*MySetting `json:"result"` // 空数组也保留 }
MySettingsRes ...
type NameDescBody ¶
NameDescBody ...
func (*NameDescBody) Validate ¶
func (t *NameDescBody) Validate() error
Validate 实现 gear.BodyTemplate。
type OperationLogListItem ¶ added in v0.3.0
type OperationLogListItem struct { HID string `json:"hid"` Operator string `json:"operator"` // 操作人 OperatorName string `json:"operatorName"` // 操作人 Action string `json:"action"` // 操作行为 Desc string `json:"desc"` // 操作说明 CreatedAt time.Time `json:"createdAt"` Groups []string `json:"groups,omitempty"` // 群组 Users []string `json:"users,omitempty"` // 用户 Value string `json:"value,omitempty"` Kind string `json:"kind"` Percent *int `json:"percent,omitempty"` // 灰度百分比 }
OperationLogListItem ...
type OperationLogListReq ¶ added in v0.3.0
type OperationLogListReq struct { Pagination ProductURL Label string `json:"label" query:"label"` Module string `json:"module" query:"module"` Setting string `json:"setting" query:"setting"` }
OperationLogListReq ...
func (*OperationLogListReq) Validate ¶ added in v0.3.0
func (t *OperationLogListReq) Validate() error
Validate 实现 gear.BodyTemplate。
type OperationLogListRes ¶ added in v0.3.0
type OperationLogListRes struct { SuccessResponseType Result []*OperationLogListItem `json:"result"` // 空数组也保留 }
OperationLogListRes ...
type Pagination ¶
type Pagination struct { Search PageToken string `json:"pageToken" query:"pageToken"` Skip int `json:"skip,omitempty" query:"skip"` PageSize int `json:"pageSize,omitempty" query:"pageSize"` }
Pagination 分页
type PercentRule ¶ added in v0.3.0
type PercentRule struct { Kind string `json:"kind"` Rule struct { Value int `json:"value"` } `json:"rule"` }
PercentRule ...
type Product ¶ added in v0.3.0
type Product struct { CreatedAt time.Time `json:"createdAt"` UpdatedAt time.Time `json:"updatedAt"` DeletedAt *time.Time `json:"deletedAt"` OfflineAt *time.Time `json:"offlineAt"` Name string `json:"name"` Desc string `json:"desc"` Status int64 `json:"status"` Users []*User `json:"users"` }
Product ...
type ProductLabelHIDURL ¶ added in v0.3.0
type ProductLabelHIDURL struct { ProductLabelURL HID string `json:"hid" param:"hid"` }
ProductLabelHIDURL ...
func (*ProductLabelHIDURL) Validate ¶ added in v0.3.0
func (t *ProductLabelHIDURL) Validate() error
Validate 实现 gear.BodyTemplate。
type ProductLabelPaginationURL ¶ added in v0.3.0
type ProductLabelPaginationURL struct { Pagination ProductURL Label string `json:"label" param:"label"` }
ProductLabelPaginationURL ...
func (*ProductLabelPaginationURL) Validate ¶ added in v0.3.0
func (t *ProductLabelPaginationURL) Validate() error
Validate 实现 gear.BodyTemplate。
type ProductLabelUIDURL ¶ added in v0.4.0
type ProductLabelUIDURL struct { ProductLabelURL Kind string `json:"kind" query:"kind"` UID string `json:"uid" param:"uid"` }
ProductLabelUIDURL ...
func (*ProductLabelUIDURL) Validate ¶ added in v0.4.0
func (t *ProductLabelUIDURL) Validate() error
Validate 实现 gear.BodyTemplate。
type ProductLabelURL ¶
type ProductLabelURL struct { ProductPaginationURL Label string `json:"label" param:"label"` }
ProductLabelURL ...
func (*ProductLabelURL) Validate ¶
func (t *ProductLabelURL) Validate() error
Validate 实现 gear.BodyTemplate。
type ProductModuleSettingHIDURL ¶ added in v0.3.0
type ProductModuleSettingHIDURL struct { ProductModuleSettingURL HID string `json:"hid" param:"hid"` }
ProductModuleSettingHIDURL ...
func (*ProductModuleSettingHIDURL) Validate ¶ added in v0.3.0
func (t *ProductModuleSettingHIDURL) Validate() error
Validate 实现 gear.BodyTemplate。
type ProductModuleSettingUIDURL ¶ added in v0.4.0
type ProductModuleSettingUIDURL struct { ProductModuleSettingURL Kind string `json:"kind" query:"kind"` UID string `json:"uid" param:"uid"` }
ProductModuleSettingUIDURL ...
func (*ProductModuleSettingUIDURL) Validate ¶ added in v0.4.0
func (t *ProductModuleSettingUIDURL) Validate() error
Validate 实现 gear.BodyTemplate。
type ProductModuleSettingURL ¶
type ProductModuleSettingURL struct { ProductModuleURL Setting string `json:"setting" param:"setting"` }
ProductModuleSettingURL ...
func (*ProductModuleSettingURL) Validate ¶
func (t *ProductModuleSettingURL) Validate() error
Validate 实现 gear.BodyTemplate。
type ProductModuleURL ¶
type ProductModuleURL struct { Pagination ProductURL Module string `json:"module" param:"module"` }
ProductModuleURL ...
func (*ProductModuleURL) Validate ¶
func (t *ProductModuleURL) Validate() error
Validate 实现 gear.BodyTemplate。
type ProductPaginationURL ¶
type ProductPaginationURL struct { Pagination Product string `json:"product" param:"product"` }
ProductPaginationURL ...
func (*ProductPaginationURL) Validate ¶
func (t *ProductPaginationURL) Validate() error
Validate 实现 gear.BodyTemplate。
type ProductRes ¶ added in v0.3.0
type ProductRes struct { SuccessResponseType Result Product `json:"result"` }
ProductRes ...
type ProductStatistics ¶ added in v0.3.0
type ProductStatistics struct { Labels int64 `json:"labels"` Modules int64 `json:"modules"` Settings int64 `json:"settings"` Release int64 `json:"release"` Status int64 `json:"status"` }
ProductStatistics ...
type ProductStatisticsRes ¶ added in v0.3.0
type ProductStatisticsRes struct {
Result ProductStatistics `json:"result"`
}
ProductStatisticsRes ...
type ProductURL ¶
type ProductURL struct {
Product string `json:"product" param:"product"`
}
ProductURL ...
type ProductUpdateBody ¶
ProductUpdateBody ...
func (*ProductUpdateBody) Validate ¶
func (t *ProductUpdateBody) Validate() error
Validate 实现 gear.BodyTemplate。
type ProductsRes ¶ added in v0.3.0
type ProductsRes struct { SuccessResponseType Result []*Product `json:"result"` }
ProductsRes ...
type RecallBody ¶ added in v0.3.0
RecallBody ...
func (*RecallBody) Validate ¶ added in v0.3.0
func (t *RecallBody) Validate() error
Validate 实现 gear.BodyTemplate。
type SettingBody ¶ added in v0.4.0
type SettingBody struct { UidsBody Name string `json:"name"` Desc string `json:"desc"` Channels *[]string `json:"channels"` Clients *[]string `json:"clients"` Values *[]string `json:"values"` }
SettingBody ...
func (*SettingBody) Validate ¶ added in v0.4.0
func (t *SettingBody) Validate() error
Validate 实现 gear.BodyTemplate。
type SettingGroupInfo ¶ added in v0.3.0
type SettingGroupInfo struct { SettingHID string `json:"settingHID"` AssignedAt time.Time `json:"assignedAt"` Release int64 `json:"release"` Group string `json:"group"` Kind string `json:"kind"` Desc string `json:"desc"` Status int64 `json:"status"` Value string `json:"value"` LastValue string `json:"lastValue"` }
SettingGroupInfo ...
type SettingGroupsInfoRes ¶ added in v0.3.0
type SettingGroupsInfoRes struct { SuccessResponseType Result []SettingGroupInfo `json:"result"` }
SettingGroupsInfoRes ...
type SettingInfo ¶ added in v0.3.0
type SettingInfo struct { HID string `json:"hid"` Product string `json:"product"` Module string `json:"module"` Name string `json:"name"` Desc string `json:"desc"` Channels []string `json:"channels"` Clients []string `json:"clients"` Values []string `json:"values"` Status int64 `json:"status"` Release int64 `json:"release"` CreatedAt time.Time `json:"createdAt"` UpdatedAt time.Time `json:"updatedAt"` OfflineAt *time.Time `json:"offlineAt"` Users []*User `json:"users"` }
SettingInfo ...
type SettingInfoRes ¶ added in v0.3.0
type SettingInfoRes struct {
Result SettingInfo `json:"result"`
}
SettingInfoRes ...
type SettingReleaseInfo ¶ added in v0.3.0
type SettingReleaseInfo struct { Release int64 `json:"release"` Users []string `json:"users"` Groups []string `json:"groups"` Value string `json:"value"` }
SettingReleaseInfo ...
type SettingReleaseInfoRes ¶ added in v0.3.0
type SettingReleaseInfoRes struct { SuccessResponseType Result SettingReleaseInfo `json:"result"` // 空数组也保留 }
SettingReleaseInfoRes ...
type SettingRuleBody ¶ added in v0.3.0
type SettingRuleBody struct { PercentRule Value string `json:"value"` Desc string `json:"desc"` // 操作说明 }
SettingRuleBody ...
type SettingRuleInfo ¶ added in v0.3.0
type SettingRuleInfo struct { ID int64 `json:"-"` HID string `json:"hid"` SettingHID string `json:"settingHID"` Kind string `json:"kind"` Rule interface{} `json:"rule"` Value string `json:"value"` Release int64 `json:"release"` CreatedAt time.Time `json:"createdAt"` UpdatedAt time.Time `json:"updatedAt"` }
SettingRuleInfo ...
type SettingRuleInfoRes ¶ added in v0.3.0
type SettingRuleInfoRes struct { SuccessResponseType Result SettingRuleInfo `json:"result"` // 空数组也保留 }
SettingRuleInfoRes ...
type SettingRulesInfoRes ¶ added in v0.3.0
type SettingRulesInfoRes struct { SuccessResponseType Result []SettingRuleInfo `json:"result"` // 空数组也保留 }
SettingRulesInfoRes ...
type SettingUpdateBody ¶
type SettingUpdateBody struct { Desc *string `json:"desc"` Channels *[]string `json:"channels"` Clients *[]string `json:"clients"` Values *[]string `json:"values"` *UidsBody }
SettingUpdateBody ...
func (*SettingUpdateBody) Validate ¶
func (t *SettingUpdateBody) Validate() error
Validate 实现 gear.BodyTemplate。
type SettingUserInfo ¶ added in v0.3.0
type SettingUserInfo struct { SettingHID string `json:"settingHID"` AssignedAt time.Time `json:"assignedAt"` Release int64 `json:"release"` User string `json:"user"` Value string `json:"value"` LastValue string `json:"lastValue"` }
SettingUserInfo ...
type SettingUsersInfoRes ¶ added in v0.3.0
type SettingUsersInfoRes struct { SuccessResponseType Result []*SettingUserInfo `json:"result"` }
SettingUsersInfoRes ...
type SettingsInfoRes ¶ added in v0.3.0
type SettingsInfoRes struct { SuccessResponseType Result []*SettingInfo `json:"result"` }
SettingsInfoRes ...
type StringRes ¶
type StringRes struct { SuccessResponseType Result string `json:"result"` }
StringRes ...
type SuccessResponseType ¶
type SuccessResponseType struct { TotalSize int `json:"totalSize,omitempty"` NextPageToken string `json:"nextPageToken,omitempty"` Result interface{} `json:"result"` }
SuccessResponseType 定义了标准的 API 接口成功时返回数据模型
type UIDPaginationURL ¶
type UIDPaginationURL struct { Pagination UID string `json:"uid" param:"uid"` }
UIDPaginationURL ...
func (*UIDPaginationURL) Validate ¶
func (t *UIDPaginationURL) Validate() error
Validate 实现 gear.BodyTemplate。
type UIDProductURL ¶
type UIDProductURL struct { Pagination UID string `json:"uid" param:"uid"` Product string `json:"product" query:"product"` }
UIDProductURL ...
func (*UIDProductURL) Validate ¶
func (t *UIDProductURL) Validate() error
Validate 实现 gear.BodyTemplate。
type UrbsAcAclAddBody ¶ added in v0.4.0
type UrbsAcAclAddBody struct { Product string `json:"product" valid:"required"` Label string `json:"label"` Module string `json:"module"` Setting string `json:"setting"` Permission string `json:"permission"` }
UrbsAcAclAddBody ...
func (*UrbsAcAclAddBody) Validate ¶ added in v0.4.0
func (t *UrbsAcAclAddBody) Validate() error
Validate 实现 gear.BodyTemplate。
type UrbsAcAclCheckBody ¶ added in v0.4.0
type UrbsAcAclCheckBody struct { Product string `json:"product"` Label string `json:"label"` Module string `json:"module"` Setting string `json:"setting"` }
UrbsAcAclCheckBody ...
func (*UrbsAcAclCheckBody) Validate ¶ added in v0.4.0
func (t *UrbsAcAclCheckBody) Validate() error
Validate 实现 gear.BodyTemplate。
type UrbsAcAclURL ¶ added in v0.3.0
type UrbsAcAclURL struct {
Uid string `json:"uid" param:"uid"`
}
UrbsAcAclURL ...
func (*UrbsAcAclURL) Validate ¶ added in v0.3.0
func (t *UrbsAcAclURL) Validate() error
Validate 实现 gear.BodyTemplate。
type UrbsAcUserBody ¶ added in v0.3.0
UrbsAcUserBody ...
type UrbsAcUserListRes ¶ added in v0.3.0
type UrbsAcUserListRes struct { SuccessResponseType Result []*schema.UrbsAcUser `json:"result"` // 空数组也保留 }
UrbsAcUserListRes ...
type UrbsAcUserUidUrl ¶ added in v0.4.0
type UrbsAcUserUidUrl struct {
Uid string `json:"uid" param:"uid"`
}
UrbsAcUserUidUrl ...
func (*UrbsAcUserUidUrl) Validate ¶ added in v0.4.0
func (t *UrbsAcUserUidUrl) Validate() error
Validate 实现 gear.BodyTemplate。
type UrbsAcUserUpdateBody ¶ added in v0.4.0
type UrbsAcUserUpdateBody struct {
Name string `json:"name"`
}
UrbsAcUserUpdateBody ...
func (*UrbsAcUserUpdateBody) Validate ¶ added in v0.4.0
func (t *UrbsAcUserUpdateBody) Validate() error
Validate 实现 gear.BodyTemplate。
type UrbsAcUserUrl ¶ added in v0.3.0
type UrbsAcUserUrl struct {
Key string `json:"key" query:"key"`
}
UrbsAcUserUrl ...
func (*UrbsAcUserUrl) Validate ¶ added in v0.3.0
func (t *UrbsAcUserUrl) Validate() error
Validate 实现 gear.BodyTemplate。
type UrbsAcUsersBody ¶ added in v0.3.0
type UrbsAcUsersBody struct {
Users []*UrbsAcUserBody `json:"users"`
}
UrbsAcUsersBody ...
func (*UrbsAcUsersBody) Validate ¶ added in v0.3.0
func (t *UrbsAcUsersBody) Validate() error
Validate 实现 gear.BodyTemplate。
type UrbsSettingUser ¶ added in v0.3.0
type UrbsSettingUser struct { CreatedAt time.Time `json:"createdAt"` UID string `json:"uid"` ActiveAt int64 `json:"activeAt"` Labels string `json:"labels"` }
UrbsSettingUser ...
type UserRes ¶ added in v0.3.0
type UserRes struct { SuccessResponseType Result UrbsSettingUser `json:"result"` }
UserRes ...
type UsersGroupsBody ¶
type UsersGroupsBody struct { Users []string `json:"users"` Groups []string `json:"groups"` Desc string `json:"desc"` // 操作说明 Value string `json:"value"` }
UsersGroupsBody ...
func (*UsersGroupsBody) Validate ¶
func (t *UsersGroupsBody) Validate() error
Validate 实现 gear.BodyTemplate。
type UsersRes ¶ added in v0.3.0
type UsersRes struct { SuccessResponseType Result []UrbsSettingUser `json:"result"` }
UsersRes ...