models

package
v0.0.0-...-33e56a9 Latest Latest
Warning

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

Go to latest
Published: Jun 24, 2025 License: Apache-2.0 Imports: 7 Imported by: 2 modules, 1 package

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

View Source
const (

	// SkuPriceAccountingModeCREDIT captures enum value "CREDIT"
	SkuPriceAccountingModeCREDIT string = "CREDIT"

	// SkuPriceAccountingModeCASH captures enum value "CASH"
	SkuPriceAccountingModeCASH string = "CASH"

	// SkuPriceAccountingModeBOTH captures enum value "BOTH"
	SkuPriceAccountingModeBOTH string = "BOTH"

	// SkuPriceAccountingModeNONE captures enum value "NONE"
	SkuPriceAccountingModeNONE string = "NONE"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Cycle

type Cycle struct {

	// ID
	ID string `json:"ID,omitempty" gorm:"primary_key;unique;default:md5(random()::text || clock_timestamp()::text)::uuid"`

	// resource type
	// Required: true
	ResourceType *string `json:"ResourceType"`

	// sku list
	// Required: true
	SkuList datamodels.JSONdb `json:"SkuList" gorm:"type:jsonb"`

	// state
	// Required: true
	State *string `json:"State"`
}

Cycle cycle

swagger:model Cycle

func (*Cycle) MarshalBinary

func (m *Cycle) MarshalBinary() ([]byte, error)

MarshalBinary interface implementation

func (*Cycle) UnmarshalBinary

func (m *Cycle) UnmarshalBinary(b []byte) error

UnmarshalBinary interface implementation

func (*Cycle) Validate

func (m *Cycle) Validate(formats strfmt.Registry) error

Validate validates this cycle

type ErrorResponse

type ErrorResponse struct {

	// error string
	// Required: true
	ErrorString *string `json:"errorString"`
}

ErrorResponse error response

swagger:model ErrorResponse

func (*ErrorResponse) MarshalBinary

func (m *ErrorResponse) MarshalBinary() ([]byte, error)

MarshalBinary interface implementation

func (*ErrorResponse) UnmarshalBinary

func (m *ErrorResponse) UnmarshalBinary(b []byte) error

UnmarshalBinary interface implementation

func (*ErrorResponse) Validate

func (m *ErrorResponse) Validate(formats strfmt.Registry) error

Validate validates this error response

type ItemCreatedResponse

type ItemCreatedResponse struct {

	// ID
	ID string `json:"ID,omitempty"`

	// link
	Link string `json:"Link,omitempty"`

	// message
	Message string `json:"Message,omitempty"`
}

ItemCreatedResponse item created response

swagger:model ItemCreatedResponse

func (*ItemCreatedResponse) MarshalBinary

func (m *ItemCreatedResponse) MarshalBinary() ([]byte, error)

MarshalBinary interface implementation

func (*ItemCreatedResponse) UnmarshalBinary

func (m *ItemCreatedResponse) UnmarshalBinary(b []byte) error

UnmarshalBinary interface implementation

func (*ItemCreatedResponse) Validate

func (m *ItemCreatedResponse) Validate(formats strfmt.Registry) error

Validate validates this item created response

type Plan

type Plan struct {

	// discount
	Discount float64 `json:"Discount,omitempty" gorm:"type:numeric(23,13);default:0.0"`

	// ID
	ID string `json:"ID,omitempty" gorm:"primary_key;unique;default:md5(random()::text || clock_timestamp()::text)::uuid"`

	// name
	// Required: true
	Name *string `json:"Name"`

	// offered end date
	// Required: true
	// Format: date
	OfferedEndDate *strfmt.Date `json:"OfferedEndDate" gorm:"type:date"`

	// offered start date
	// Required: true
	// Format: date
	OfferedStartDate *strfmt.Date `json:"OfferedStartDate" gorm:"type:date"`

	// sku prices
	SkuPrices []*SkuPrice `json:"SkuPrices" gorm:"-"`
}

Plan plan

swagger:model Plan

func (*Plan) MarshalBinary

func (m *Plan) MarshalBinary() ([]byte, error)

MarshalBinary interface implementation

func (*Plan) UnmarshalBinary

func (m *Plan) UnmarshalBinary(b []byte) error

UnmarshalBinary interface implementation

func (*Plan) Validate

func (m *Plan) Validate(formats strfmt.Registry) error

Validate validates this plan

type Sku

type Sku struct {

	// ID
	ID string `json:"ID,omitempty" gorm:"primary_key;unique;default:md5(random()::text || clock_timestamp()::text)::uuid"`

	// name
	// Required: true
	Name *string `json:"Name"`

	// unit
	Unit string `json:"Unit,omitempty"`
}

Sku sku

swagger:model Sku

func (*Sku) MarshalBinary

func (m *Sku) MarshalBinary() ([]byte, error)

MarshalBinary interface implementation

func (*Sku) UnmarshalBinary

func (m *Sku) UnmarshalBinary(b []byte) error

UnmarshalBinary interface implementation

func (*Sku) Validate

func (m *Sku) Validate(formats strfmt.Registry) error

Validate validates this sku

type SkuBundle

type SkuBundle struct {

	// ID
	ID string `json:"ID,omitempty" gorm:"primary_key;unique;default:md5(random()::text || clock_timestamp()::text)::uuid"`

	// name
	// Required: true
	Name *string `json:"Name"`

	// sku prices
	SkuPrices datamodels.JSONdb `json:"SkuPrices,omitempty" gorm:"type:jsonb"`
}

SkuBundle sku bundle

swagger:model SkuBundle

func (*SkuBundle) MarshalBinary

func (m *SkuBundle) MarshalBinary() ([]byte, error)

MarshalBinary interface implementation

func (*SkuBundle) UnmarshalBinary

func (m *SkuBundle) UnmarshalBinary(b []byte) error

UnmarshalBinary interface implementation

func (*SkuBundle) Validate

func (m *SkuBundle) Validate(formats strfmt.Registry) error

Validate validates this sku bundle

type SkuPrice

type SkuPrice struct {

	// accounting mode
	// Enum: [CREDIT CASH BOTH NONE]
	AccountingMode *string `json:"AccountingMode,omitempty" gorm:"index;default:CREDIT"`

	// discount
	Discount float64 `json:"Discount,omitempty" gorm:"type:numeric(23,13);default:0.0"`

	// ID
	ID string `json:"ID,omitempty" gorm:"primary_key;unique;default:md5(random()::text || clock_timestamp()::text)::uuid"`

	// plan ID
	// Required: true
	PlanID *string `json:"PlanID"`

	// sku ID
	// Required: true
	SkuID *string `json:"SkuID"`

	// sku name
	SkuName string `json:"SkuName,omitempty"`

	// unit
	// Required: true
	Unit *string `json:"Unit"`

	// unit credit price
	UnitCreditPrice float64 `json:"UnitCreditPrice,omitempty" gorm:"type:numeric(23,13)"`

	// unit price
	// Required: true
	UnitPrice *float64 `json:"UnitPrice" gorm:"type:numeric(23,13)"`
}

SkuPrice sku price

swagger:model SkuPrice

func (*SkuPrice) MarshalBinary

func (m *SkuPrice) MarshalBinary() ([]byte, error)

MarshalBinary interface implementation

func (*SkuPrice) UnmarshalBinary

func (m *SkuPrice) UnmarshalBinary(b []byte) error

UnmarshalBinary interface implementation

func (*SkuPrice) Validate

func (m *SkuPrice) Validate(formats strfmt.Registry) error

Validate validates this sku price

type Status

type Status struct {

	// average response time
	AverageResponseTime float64 `json:"AverageResponseTime,omitempty"`

	// d b state
	DBState string `json:"DBState,omitempty"`

	// last request
	LastRequest string `json:"LastRequest,omitempty"`

	// requests bo t
	RequestsBoT int64 `json:"RequestsBoT,omitempty"`

	// requests last hour
	RequestsLastHour int64 `json:"RequestsLastHour,omitempty"`

	// requests today
	RequestsToday int64 `json:"RequestsToday,omitempty"`

	// system state
	// Required: true
	SystemState *string `json:"SystemState"`
}

Status status

swagger:model Status

func (*Status) MarshalBinary

func (m *Status) MarshalBinary() ([]byte, error)

MarshalBinary interface implementation

func (*Status) UnmarshalBinary

func (m *Status) UnmarshalBinary(b []byte) error

UnmarshalBinary interface implementation

func (*Status) Validate

func (m *Status) Validate(formats strfmt.Registry) error

Validate validates this status

Jump to

Keyboard shortcuts

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