feat: update multiple tomtom keys and switch tomtom key and add comming soon button

This commit is contained in:
2026-05-19 17:35:39 +02:00
parent 48bdba750e
commit 93120f6bfe
18 changed files with 341 additions and 69 deletions
+10 -9
View File
@@ -3,16 +3,17 @@ package models
import "time"
type Product struct {
ID int `json:"id" gorm:"primaryKey;autoIncrement"`
Name string `json:"name" gorm:"column:name" binding:"required"`
Category string `json:"category" gorm:"column:category" binding:"required"`
Description string `json:"description" gorm:"column:description"`
Stock float64 `json:"stock" gorm:"column:stock"`
Unit string `json:"unit" gorm:"column:unit"`
Prices []ProductPrice `json:"prices" gorm:"foreignKey:ProductID"`
ID int `json:"id" gorm:"primaryKey;autoIncrement"`
Name string `json:"name" gorm:"column:name" binding:"required"`
Category string `json:"category" gorm:"column:category" binding:"required"`
Description string `json:"description" gorm:"column:description"`
Stock float64 `json:"stock" gorm:"column:stock"`
Unit string `json:"unit" gorm:"column:unit"`
ComingSoon bool `json:"coming_soon" gorm:"column:coming_soon;default:false"`
Prices []ProductPrice `json:"prices" gorm:"foreignKey:ProductID"`
Media []Media `json:"media,omitempty" gorm:"foreignKey:ProductID"`
CreatedAt time.Time `json:"created_at" gorm:"autoCreateTime"`
UpdatedAt time.Time `json:"updated_at" gorm:"autoUpdateTime"`
CreatedAt time.Time `json:"created_at" gorm:"autoCreateTime"`
UpdatedAt time.Time `json:"updated_at" gorm:"autoUpdateTime"`
}
func (Product) TableName() string { return "products" }