cloudaccount

package
v1.0.0-rc Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 24, 2021 License: AGPL-3.0 Imports: 7 Imported by: 0

Documentation

Overview

Package account 账号逻辑封装

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type CloudAccount

type CloudAccount struct {
	// contains filtered or unexported fields
}

CloudAccount 账号逻辑封装

func New

func New(options ...Option) *CloudAccount

New 新建 CloudAccount 实例,操作账号资源

func (*CloudAccount) Create

Create 创建账号

func (*CloudAccount) Delete

func (a *CloudAccount) Delete(orgID, accountID int64) error

Delete 删除云账号

func (*CloudAccount) GetByID

func (a *CloudAccount) GetByID(orgID, accountID int64) (*apistructs.CloudAccountAllInfo, error)

Get 获取云账号

func (*CloudAccount) ListByOrgID

func (a *CloudAccount) ListByOrgID(orgID int64) ([]apistructs.CloudAccountInfo, error)

List 列出云账号

func (*CloudAccount) Update

func (a *CloudAccount) Update(orgID, accountID int64, updateReq *apistructs.CloudAccountUpdateRequest) (*apistructs.CloudAccountInfo, error)

Update 跟新账号

type Option

type Option func(*CloudAccount)

Option 定义 CloudAccount 对象的配置选项

func WithDBClient

func WithDBClient(db *dao.DBClient) Option

WithDBClient 配置 db client

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL