Documentation
¶
Index ¶
- Variables
- func Query(db *datastore.Datastore) datastore.Query
- type InventoryLevel
- func (l InventoryLevel) AvailableQuantity() int
- func (l *InventoryLevel) Defaults()
- func (l *InventoryLevel) Init(db *datastore.Datastore)
- func (l InventoryLevel) Kind() string
- func (l *InventoryLevel) Load(ps []datastore.Property) (err error)
- func (l *InventoryLevel) Save() ([]datastore.Property, error)
Constants ¶
This section is empty.
Variables ¶
View Source
var IgnoreFieldMismatch = datastore.IgnoreFieldMismatch
Functions ¶
Types ¶
type InventoryLevel ¶
type InventoryLevel struct {
mixin.BaseModel
InventoryItemId string `json:"inventoryItemId"`
LocationId string `json:"locationId"`
StockedQuantity int `json:"stockedQuantity"`
ReservedQuantity int `json:"reservedQuantity"`
IncomingQuantity int `json:"incomingQuantity"`
// Arbitrary key/value pairs
Metadata Map `json:"metadata,omitempty" datastore:"-"`
Metadata_ string `json:"-" datastore:",noindex"`
}
func New ¶
func New(db *datastore.Datastore) *InventoryLevel
func (InventoryLevel) AvailableQuantity ¶
func (l InventoryLevel) AvailableQuantity() int
AvailableQuantity returns stock minus reserved.
func (*InventoryLevel) Defaults ¶
func (l *InventoryLevel) Defaults()
func (*InventoryLevel) Init ¶
func (l *InventoryLevel) Init(db *datastore.Datastore)
func (InventoryLevel) Kind ¶
func (l InventoryLevel) Kind() string
Click to show internal directories.
Click to hide internal directories.