response

package
v1.1.1 Latest Latest
Warning

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

Go to latest
Published: Aug 29, 2024 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Health

type Health struct {
	Version   string `json:"version"`   // 系统版本号
	Name      string `json:"name"`      // 系统名称
	BuildTime string `json:"buildTime"` // 编译时间
	GitBranch string `json:"gitBranch"` // Git分支
	GitCommit string `json:"gitCommit"` // Git提交号
	StartTime string `json:"startTime"` // 服务启动时间
	Now       string `json:"now"`       // 服务器当前时间
}

Health define the response structure of Health()

func (*Health) GetBuildTime

func (h *Health) GetBuildTime() string

GetBuildTime get build time

func (*Health) GetGitBranch

func (h *Health) GetGitBranch() string

GetGitBranch get git branch

func (*Health) GetGitCommit

func (h *Health) GetGitCommit() string

GetGitCommit get git commit

func (*Health) GetName

func (h *Health) GetName() string

GetName get name

func (*Health) GetNow

func (h *Health) GetNow() string

GetNow get now time

func (*Health) GetStartTime

func (h *Health) GetStartTime() string

GetStartTime get start time

func (*Health) GetVersion

func (h *Health) GetVersion() string

GetVersion get version

type Login

type Login struct {
	AccessToken       string `json:"accessToken"` // 访问令牌
	ExpiresIn         int    `json:"expiresIn"`   // 过期时间
	UserId            int    `json:"userId"`
	Did               string `json:"did"`
	UserName          string `json:"userName"`
	EnterpriseCName   string `json:"enterpriseCName"`
	MemberType        int    `json:"memberType"`
	IsOperatingCenter int    `json:"isOperatingCenter"`
	IsFirst           int    `json:"isFirst"`
	OldAccessToken    string `json:"access_token,omitempty"` // 访问令牌
	OldExpiresIn      int    `json:"expires_in,omitempty"`   // 过期时间
}

Login define the response structure of Login

func (*Login) GetAccessToken

func (l *Login) GetAccessToken() string

GetAccessToken return access token

func (*Login) GetExpiresIn

func (l *Login) GetExpiresIn() int

GetExpiresIn return expires in

type Response

type Response[T any] struct {
	Code int32  `json:"code"`
	Msg  string `json:"msg"`
	Data T
}

type VcInfo

type VcInfo struct {
	Vc     *core.VerifiableCredential `json:"vc"`     // 凭证
	Status string                     `json:"status"` // 状态
}

VcInfo define the response structure of VcGet

func (*VcInfo) GetStatus

func (vcInfo *VcInfo) GetStatus() string

GetStatus get status of VcInfo

func (*VcInfo) GetVc

func (vcInfo *VcInfo) GetVc() *core.VerifiableCredential

GetVc get vc of VcInfo

type VcPage

type VcPage struct {
	VcList []*core.VerifiableCredential `json:"vcList"` // 凭证列表
	Page   *module.Page                 `json:"page"`   // 分页结构
}

VcPage define the response structure of VcList

func (*VcPage) GetPage

func (v *VcPage) GetPage() *module.Page

GetPage get page of VcPage

func (*VcPage) GetVcList

func (v *VcPage) GetVcList() []*core.VerifiableCredential

GetVcList get vcList of VcPage

type VctId

type VctId struct {
	Id string `json:"id"`
}

VctId define the response structure of VctCreate

func (*VctId) GetId

func (v *VctId) GetId() string

GetId return the id of the VctId

type VctInfo

type VctInfo struct {
	Id                   string                       `json:"id"`                   // VCT ID
	Name                 string                       `json:"name"`                 // VCT名称
	Type                 string                       `json:"type"`                 // VCT类型
	VcType               string                       `json:"vcType"`               // VC类型
	Schema               string                       `json:"$schema"`              // VCT Schema
	Created              string                       `json:"created"`              // 创建时间
	Creator              string                       `json:"creator"`              // 创建者
	Version              string                       `json:"version"`              // 版本
	Required             []string                     `json:"required"`             // 必填字段
	Properties           map[string]*request.Property `json:"properties"`           // 属性
	AdditionalProperties bool                         `json:"additionalProperties"` // 是否允许额外属性
}

VctInfo define the structure of VctInfo

func (*VctInfo) GetAdditionalProperties

func (v *VctInfo) GetAdditionalProperties() bool

GetAdditionalProperties get additional properties of VctInfo

func (*VctInfo) GetCreated

func (v *VctInfo) GetCreated() string

GetCreated get created of VctInfo

func (*VctInfo) GetCreator

func (v *VctInfo) GetCreator() string

GetCreator get creator of VctInfo

func (*VctInfo) GetId

func (v *VctInfo) GetId() string

GetId get id of VctInfo

func (*VctInfo) GetName

func (v *VctInfo) GetName() string

GetName get name of VctInfo

func (*VctInfo) GetProperties

func (v *VctInfo) GetProperties() map[string]*request.Property

GetProperties get properties of VctInfo

func (*VctInfo) GetRequired

func (v *VctInfo) GetRequired() []string

GetRequired get required of VctInfo

func (*VctInfo) GetSchema

func (v *VctInfo) GetSchema() string

GetSchema get schema of VctInfo

func (*VctInfo) GetType

func (v *VctInfo) GetType() string

GetType get type of VctInfo

func (*VctInfo) GetVcType

func (v *VctInfo) GetVcType() string

GetVcType get vc type of VctInfo

func (*VctInfo) GetVersion

func (v *VctInfo) GetVersion() string

GetVersion get version of VctInfo

type VctList

type VctList struct {
	List []VctInfo    `json:"list"` // VCT列表
	Page *module.Page `json:"page"` // 分页结构
}

VctList define the response structure of VctList

func (*VctList) GetList

func (v *VctList) GetList() []VctInfo

GetList get list of VctList

func (*VctList) GetPage

func (v *VctList) GetPage() *module.Page

GetPage get page of VctList

Jump to

Keyboard shortcuts

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