warehouse

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Dec 5, 2022 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Query

type Query interface {
	New() Query

	Get() (*Warehouse, error)
	Select() ([]Warehouse, error)

	Insert(Warehouse) (Warehouse, error)
	Update(Warehouse) (Warehouse, error)
	Delete(id int64) error

	Page(pageParams pgdb.OffsetPageParams) Query

	FilterById(ids ...int64) Query
	FilterByCafeId(ids ...int64) Query
	FilterByAddressId(ids ...int64) Query
	FilterByCapacity(capacities ...int64) Query
}

func NewQuery

func NewQuery(db *sqlx.DB) Query

type Warehouse

type Warehouse struct {
	Id        int64 `db:"ID" structs:"-"`
	CafeId    int64 `db:"CAFE_ID" structs:"cafe_id"`
	AddressId int64 `db:"ADDRESS_ID" structs:"address_id"`
	Capacity  int64 `db:"CAPACITY" structs:"capacity"`
}

Jump to

Keyboard shortcuts

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