price

package
v0.4.5 Latest Latest
Warning

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

Go to latest
Published: Aug 12, 2023 License: AGPL-3.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func UpsertAllByType added in v0.3.9

func UpsertAllByType(db *gorm.DB, commodityType config.CommodityType, prices []Price)

func UpsertAllByTypeAndID added in v0.3.9

func UpsertAllByTypeAndID(db *gorm.DB, commodityType config.CommodityType, commodityID string, prices []*Price)

Types

type Price

type Price struct {
	ID            uint                 `gorm:"primaryKey" json:"id"`
	Date          time.Time            `json:"date"`
	CommodityType config.CommodityType `json:"commodity_type"`
	CommodityID   string               `json:"commodity_id"`
	CommodityName string               `json:"commodity_name"`
	Value         float64              `json:"value"`
}

func (Price) Less

func (p Price) Less(o btree.Item) bool

Jump to

Keyboard shortcuts

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