diff --git a/db/item.go b/db/item.go index 1d5da20..e2fff33 100644 --- a/db/item.go +++ b/db/item.go @@ -17,7 +17,7 @@ type Item struct { Carbs uint64 Fats uint64 // - Prices []ItemPrice + Prices []ItemPrice `gorm:"constraint:OnDelete:CASCADE;"` CurrentPriceID uint CurrentPrice *ItemPrice //