updates
This commit is contained in:
13
server/internal/models/nutrient.go
Normal file
13
server/internal/models/nutrient.go
Normal file
@@ -0,0 +1,13 @@
|
||||
package models
|
||||
|
||||
func (Nutrient) TableName() string {
|
||||
return "nutrients"
|
||||
}
|
||||
|
||||
type Nutrient struct {
|
||||
BaseModel
|
||||
Name string `json:"name" db:"name"`
|
||||
Description string `json:"description" db:"description"`
|
||||
Supplements []Supplement `json:"supplements" db:"supplements" gorm:"many2many:supplement_nutrients;"`
|
||||
Categories []Category `json:"categories" db:"categories" gorm:"many2many:nutrient_categories;"`
|
||||
}
|
||||
Reference in New Issue
Block a user