mirror of
https://github.com/wahyd4/go-shopping.git
synced 2026-08-09 04:35:51 +10:00
27 lines
392 B
Go
27 lines
392 B
Go
package models
|
|
|
|
import (
|
|
"time"
|
|
|
|
"github.com/jinzhu/gorm"
|
|
)
|
|
|
|
// Product the model for product item
|
|
type Product struct {
|
|
gorm.Model
|
|
ULID string
|
|
Name string
|
|
CurrentPrice float64
|
|
URL string
|
|
Brand string
|
|
Nation string
|
|
}
|
|
|
|
// Price the price for a single day
|
|
type Price struct {
|
|
gorm.Model
|
|
ProductID string
|
|
Price string
|
|
DateTime time.Time
|
|
}
|