appcertificate

package
v1.0.1 Latest Latest
Warning

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

Go to latest
Published: Jul 5, 2021 License: AGPL-3.0 Imports: 13 Imported by: 0

Documentation

Overview

Package certificate 封装AppCertificate资源相关操作

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AppCertificate

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

AppCertificate 资源对象操作封装

func New

func New(options ...Option) *AppCertificate

New 新建 AppCertificate 实例,通过 AppCertificate 实例操作企业资源

func (*AppCertificate) Create

func (c *AppCertificate) Create(userID string, orgID uint64, createReq *apistructs.CertificateQuoteRequest) error

Create 引用AppCertificate

func (*AppCertificate) Delete

func (c *AppCertificate) Delete(appID, certificateID int64) error

Delete 取消引用Certificate

func (*AppCertificate) ListAllAppCertificates

ListAllAppCertificates 列出所有应用下的引用证书

func (*AppCertificate) ModifyApprovalStatus

func (c *AppCertificate) ModifyApprovalStatus(approvalID int64, status apistructs.ApprovalStatus) error

ModifyApprovalStatus 修改AppCertificate审批转态

func (*AppCertificate) PushConfigs

func (c *AppCertificate) PushConfigs(certificatePushReq *apistructs.PushCertificateConfigsRequest) error

PushConfigs 推送Certificate配置到配置管理

type Option

type Option func(*AppCertificate)

Option 定义 AppCertificate 对象的配置选项

func WithApp

func WithApp(app *application.Application) Option

WithApp 配置 app

func WithApprove

func WithApprove(approve *approve.Approve) Option

WithApprove 配置 approve

func WithBundle

func WithBundle(bdl *bundle.Bundle) Option

WithBundle 配置 bundle

func WithCertificate

func WithCertificate(cer *certificate.Certificate) Option

WithCertificate 配置 证书

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