tag-registry-product-link: seed 100 real preset IDs (seed-registry cmd), products/orders schema + tag linkage, fix case-sensitive tag-code bind
This commit is contained in:
@@ -8,6 +8,23 @@ import (
|
||||
"github.com/jackc/pgx/v5/pgtype"
|
||||
)
|
||||
|
||||
type Order struct {
|
||||
ID int64 `json:"id"`
|
||||
AccountID pgtype.Int8 `json:"account_id"`
|
||||
Status string `json:"status"`
|
||||
CreatedAt pgtype.Timestamptz `json:"created_at"`
|
||||
UpdatedAt pgtype.Timestamptz `json:"updated_at"`
|
||||
}
|
||||
|
||||
type Product struct {
|
||||
ID int64 `json:"id"`
|
||||
Sku string `json:"sku"`
|
||||
Name string `json:"name"`
|
||||
ItemType pgtype.Text `json:"item_type"`
|
||||
CreatedAt pgtype.Timestamptz `json:"created_at"`
|
||||
UpdatedAt pgtype.Timestamptz `json:"updated_at"`
|
||||
}
|
||||
|
||||
type Scan struct {
|
||||
ID int64 `json:"id"`
|
||||
TagID int64 `json:"tag_id"`
|
||||
@@ -33,6 +50,8 @@ type Tag struct {
|
||||
CreatedAt pgtype.Timestamptz `json:"created_at"`
|
||||
UpdatedAt pgtype.Timestamptz `json:"updated_at"`
|
||||
SmsEnabled bool `json:"sms_enabled"`
|
||||
ProductID pgtype.Int8 `json:"product_id"`
|
||||
OrderID pgtype.Int8 `json:"order_id"`
|
||||
}
|
||||
|
||||
type User struct {
|
||||
|
||||
Reference in New Issue
Block a user