model

package
v0.0.0-...-e1e387d Latest Latest
Warning

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

Go to latest
Published: Dec 18, 2024 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type InventoryItem

type InventoryItem struct {
	ID        int `json:"id"`
	ProductID int `json:"product_id" db:"product_id" validate:"required"`
	Quantity  int `json:"quantity" db:"quantity" validate:"min=0,required"`
}

func (*InventoryItem) FromJSON

func (i *InventoryItem) FromJSON(r io.Reader) error

func (*InventoryItem) ToJSON

func (i *InventoryItem) ToJSON(w io.Writer) error

func (*InventoryItem) Validate

func (i *InventoryItem) Validate() error

Jump to

Keyboard shortcuts

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