Compare commits

...

1 Commits

Author SHA1 Message Date
4b5d681efe Update 2025-11-08 14:54:22 +01:00
3 changed files with 5 additions and 5 deletions

View File

@@ -2,14 +2,14 @@ package basket
import "time" import "time"
type BasketEntity struct { type Basket struct {
ID string `db:"id" json:"id"` ID string `db:"id" json:"id"`
State string `db:"state" json:"state"` State string `db:"state" json:"state"`
CreatedAt time.Time `db:"created_at" json:"created_at"` CreatedAt time.Time `db:"created_at" json:"created_at"`
UpdatedAt *time.Time `db:"updated_at" json:"updated_at,omitempty"` UpdatedAt *time.Time `db:"updated_at" json:"updated_at,omitempty"`
} }
type BasketItemEntity struct { type BasketItem struct {
ID string `db:"id" json:"id"` ID string `db:"id" json:"id"`
BasketID string `db:"basket_id" json:"basket_id"` BasketID string `db:"basket_id" json:"basket_id"`
ProductID string `db:"product_id" json:"product_id"` ProductID string `db:"product_id" json:"product_id"`

View File

@@ -4,14 +4,14 @@ import (
"time" "time"
) )
type OrderEntity struct { type Order struct {
ID string `db:"id" json:"id"` ID string `db:"id" json:"id"`
State string `db:"state" json:"state"` State string `db:"state" json:"state"`
CreatedAt time.Time `db:"created_at" json:"created_at"` CreatedAt time.Time `db:"created_at" json:"created_at"`
UpdatedAt *time.Time `db:"updated_at" json:"updated_at,omitempty"` UpdatedAt *time.Time `db:"updated_at" json:"updated_at,omitempty"`
} }
type OrderItemEntity struct { type OrderItem struct {
ID string `db:"id" json:"id"` ID string `db:"id" json:"id"`
OrderID string `db:"order_id" json:"order_id"` OrderID string `db:"order_id" json:"order_id"`
ProductID int `db:"product_id" json:"product_id"` ProductID int `db:"product_id" json:"product_id"`

View File

@@ -1,6 +1,6 @@
package pricing package pricing
type ProductPriceEntity struct { type ProductPrice struct {
ID int `db:"id"` ID int `db:"id"`
PID string `db:"pid"` PID string `db:"pid"`
Price int `db:"price"` Price int `db:"price"`