Files
terminalShop/pkg/models/coffee.go
marcusDenslow c78f5eb12b refactor: remove putting ssh key in memory at all, just use it for auth
changed the ssh key to just do fingerprinting and not store it at all, and not be able to edit it either in the account page
2026-04-25 10:50:19 +02:00

37 lines
999 B
Go

package models
import (
"time"
"gorm.io/gorm"
)
// Coffee represents a coffee product
type Coffee struct {
ID uint `gorm:"primaryKey" json:"id"`
Name string `gorm:"size:255;not null" json:"name"`
RoastType string `gorm:"size:100" json:"roast_type"`
Ounces int `json:"ounces"`
BeanType string `gorm:"size:100" json:"bean_type"`
Price int `gorm:"not null" json:"price"`
Color string `gorm:"size:7" json:"color"` // Hex color for background
Description string `gorm:"type:text" json:"description"`
CreatedAt time.Time `json:"created_at"`
UpdatedAt time.Time `json:"updated_at"`
DeletedAt gorm.DeletedAt `gorm:"index" json:"-"`
}
// TableName specifies the table name for the Coffee model
func (Coffee) TableName() string {
return "coffees"
}
// AccountMenuItems
var AccountMenuItems = []string{
"order history",
"addresses",
"cards",
"faq",
"about",
}