Documentation
¶
Index ¶
- type BaseModel
- type Business
- func (b *Business) All(ctx kratos.Context, scopes Scopes) ([]*Business, error)
- func (b *Business) Create(ctx kratos.Context) error
- func (b *Business) DeleteByID(ctx kratos.Context, id int64) error
- func (b *Business) OneByID(ctx kratos.Context, id int64) error
- func (b *Business) Page(ctx kratos.Context, options *PageOptions) ([]*Business, int64, error)
- func (b *Business) Update(ctx kratos.Context) error
- type BusinessValue
- func (bv *BusinessValue) All(ctx kratos.Context, scopes Scopes) ([]*BusinessValue, error)
- func (bv *BusinessValue) AllByEnvAndServer(ctx kratos.Context, envId, srvId int64) ([]*BusinessValue, error)
- func (bv *BusinessValue) Create(ctx kratos.Context) error
- func (bv *BusinessValue) DeleteByID(ctx kratos.Context, id int64) error
- func (bv *BusinessValue) OneByID(ctx kratos.Context, id int64) error
- func (bv *BusinessValue) Update(ctx kratos.Context) error
- type CreateModel
- type DeleteModel
- type Environment
- func (e *Environment) All(ctx kratos.Context) ([]*Environment, error)
- func (e *Environment) Create(ctx kratos.Context) error
- func (e *Environment) DeleteByID(ctx kratos.Context, id int64) error
- func (e *Environment) OneByID(ctx kratos.Context, id int64) error
- func (e *Environment) OneByKeyword(ctx kratos.Context, keyword string) error
- func (e *Environment) UpdateByID(ctx kratos.Context, id int64) error
- type OperateLog
- type PageOptions
- type Resource
- func (r *Resource) All(ctx kratos.Context, scopes Scopes) ([]*Resource, error)
- func (r *Resource) Create(ctx kratos.Context) error
- func (r *Resource) DeleteByID(ctx kratos.Context, id int64) error
- func (r *Resource) OneByID(ctx kratos.Context, id int64) error
- func (r *Resource) Page(ctx kratos.Context, options *PageOptions) ([]*Resource, int64, error)
- func (r *Resource) Update(ctx kratos.Context) error
- type ResourceServer
- type ResourceValue
- func (rv *ResourceValue) All(ctx kratos.Context, scopes Scopes) ([]*ResourceValue, error)
- func (rv *ResourceValue) AllByEnvAndServer(ctx kratos.Context, envId, srvId int64) ([]*ResourceValue, error)
- func (rv *ResourceValue) Create(ctx kratos.Context) error
- func (rv *ResourceValue) Creates(ctx kratos.Context, list []*ResourceValue) error
- func (rv *ResourceValue) Update(ctx kratos.Context) error
- type Scopes
- type Server
- func (s *Server) All(ctx kratos.Context, scopes Scopes) ([]*Server, error)
- func (s *Server) Create(ctx kratos.Context) error
- func (s *Server) DeleteByID(ctx kratos.Context, id int64) error
- func (s *Server) OneByID(ctx kratos.Context, id int64) error
- func (s *Server) OneByKeyword(ctx kratos.Context, keyword string) error
- func (s *Server) Page(ctx kratos.Context, options *PageOptions) ([]*Server, int64, error)
- func (s *Server) Update(ctx kratos.Context) error
- type Template
- func (t *Template) Create(ctx kratos.Context) error
- func (t *Template) Current(ctx kratos.Context, srvId int64) error
- func (t *Template) OneById(ctx kratos.Context, id int64) error
- func (t *Template) Page(ctx kratos.Context, options *PageOptions) ([]*Template, int64, error)
- func (t *Template) UseVersionByID(ctx kratos.Context, srvId, id int64) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Business ¶ added in v1.0.1
type Business struct {
BaseModel
ServerID int64 `json:"server_id"`
Keyword string `json:"keyword"`
Description string `json:"description"`
Operator string `json:"operator"`
OperatorID int64 `json:"operator_id"`
}
func (*Business) DeleteByID ¶ added in v1.0.1
DeleteByID 删除指定id的业务字段
type BusinessValue ¶ added in v1.0.1
type BusinessValue struct {
BaseModel
EnvironmentID int64 `json:"environment_id"`
BusinessID int64 `json:"business_id"`
Value string `json:"value"`
Operator string `json:"operator"`
OperatorID int64 `json:"operator_id"`
Environment Environment `json:"environment"`
Business Business `json:"business"`
}
func (*BusinessValue) All ¶ added in v1.0.1
func (bv *BusinessValue) All(ctx kratos.Context, scopes Scopes) ([]*BusinessValue, error)
All 查询所有业务字段
func (*BusinessValue) AllByEnvAndServer ¶ added in v1.0.1
func (bv *BusinessValue) AllByEnvAndServer(ctx kratos.Context, envId, srvId int64) ([]*BusinessValue, error)
func (*BusinessValue) Create ¶ added in v1.0.1
func (bv *BusinessValue) Create(ctx kratos.Context) error
Create 新建业务字段
func (*BusinessValue) DeleteByID ¶ added in v1.0.1
func (bv *BusinessValue) DeleteByID(ctx kratos.Context, id int64) error
DeleteByID 删除指定id的业务字段
type CreateModel ¶
type DeleteModel ¶
type Environment ¶
type Environment struct {
BaseModel
Keyword string `json:"keyword"`
Name string `json:"name"`
Description string `json:"description"`
Token string `json:"token,omitempty"`
Status *bool `json:"status"`
Operator string `json:"operator"`
OperatorID int64 `json:"operator_id"`
}
func (*Environment) All ¶
func (e *Environment) All(ctx kratos.Context) ([]*Environment, error)
All 查询所有环境
func (*Environment) DeleteByID ¶
func (e *Environment) DeleteByID(ctx kratos.Context, id int64) error
DeleteByID 删除指定id的环境
func (*Environment) OneByID ¶ added in v1.0.1
func (e *Environment) OneByID(ctx kratos.Context, id int64) error
OneByID 通过id查找指定环境
func (*Environment) OneByKeyword ¶
func (e *Environment) OneByKeyword(ctx kratos.Context, keyword string) error
OneByKeyword 通过关键词查找指定环境
func (*Environment) UpdateByID ¶
func (e *Environment) UpdateByID(ctx kratos.Context, id int64) error
UpdateByID 更新指定id的环境
type OperateLog ¶ added in v1.0.1
type OperateLog struct {
ServerID int64 `json:"server_id"`
EnvironmentID int64 `json:"environment_id"`
Config string `json:"config"`
Compare string `json:"compare"`
Operator string `json:"operator"`
OperatorId int64 `json:"operator_id"`
Server Server `json:"server"`
Environment Environment `json:"environment"`
}
func (*OperateLog) OneById ¶ added in v1.0.1
func (ol *OperateLog) OneById(ctx kratos.Context, id int64) error
func (*OperateLog) Page ¶ added in v1.0.1
func (ol *OperateLog) Page(ctx kratos.Context, options PageOptions) ([]*OperateLog, int64, error)
type PageOptions ¶
type Resource ¶ added in v1.0.1
type Resource struct {
BaseModel
Keyword string `json:"keyword"`
Description string `json:"description"`
Fields string `json:"fields"`
Tag string `json:"tag"`
Operator string `json:"operator"`
OperatorID int64 `json:"operator_id"`
}
func (*Resource) DeleteByID ¶ added in v1.0.1
DeleteByID 删除指定id的资源
type ResourceServer ¶ added in v1.0.1
type ResourceServer struct {
CreateModel
ServerID int64 `json:"server_id"`
ResourceID int64 `json:"resource_id"`
Operator string `json:"operator"`
OperatorID int64 `json:"operator_id"`
Resource Resource `json:"resource"`
Server Server `json:"server"`
}
func (*ResourceServer) All ¶ added in v1.0.1
func (rs *ResourceServer) All(ctx kratos.Context, scopes Scopes) ([]*ResourceServer, error)
All 查询全部资源
func (*ResourceServer) Create ¶ added in v1.0.1
func (rs *ResourceServer) Create(ctx kratos.Context) error
Create 新建资源
func (*ResourceServer) DeleteByID ¶ added in v1.0.1
func (rs *ResourceServer) DeleteByID(ctx kratos.Context, id int64) error
DeleteByID 删除指定id的资源
type ResourceValue ¶ added in v1.0.1
type ResourceValue struct {
BaseModel
EnvironmentID int64 `json:"environment_id"`
ResourceID int64 `json:"resource_id"`
Values string `json:"values"`
Operator string `json:"operator"`
OperatorID int64 `json:"operator_id"`
Environment Environment `json:"environment"`
Resource Resource `json:"resource"`
}
func (*ResourceValue) All ¶ added in v1.0.1
func (rv *ResourceValue) All(ctx kratos.Context, scopes Scopes) ([]*ResourceValue, error)
All 查询全部资源
func (*ResourceValue) AllByEnvAndServer ¶ added in v1.0.1
func (rv *ResourceValue) AllByEnvAndServer(ctx kratos.Context, envId, srvId int64) ([]*ResourceValue, error)
func (*ResourceValue) Create ¶ added in v1.0.1
func (rv *ResourceValue) Create(ctx kratos.Context) error
Create 新建资源
func (*ResourceValue) Creates ¶ added in v1.0.1
func (rv *ResourceValue) Creates(ctx kratos.Context, list []*ResourceValue) error
Creates 批量创建资源
type Server ¶ added in v1.0.1
type Server struct {
BaseModel
Keyword string `json:"keyword"`
Name string `json:"name"`
Description string `json:"description"`
Operator string `json:"operator"`
OperatorID int64 `json:"operator_id"`
}
func (*Server) DeleteByID ¶ added in v1.0.1
DeleteByID 删除指定id的资源
func (*Server) OneByKeyword ¶ added in v1.0.1
type Template ¶ added in v1.0.1
type Template struct {
BaseModel
ServerID int64 `json:"server_id"`
Content string `json:"content"`
Version string `json:"version"`
IsUse bool `json:"is_use"`
Description *string `json:"description"`
Operator string `json:"operator"`
OperatorID int64 `json:"operator_id"`
}
Click to show internal directories.
Click to hide internal directories.