updates
This commit is contained in:
13
server/internal/models/nutrient_category.go
Normal file
13
server/internal/models/nutrient_category.go
Normal file
@@ -0,0 +1,13 @@
|
||||
package models
|
||||
|
||||
func (NutrientCategory) TableName() string {
|
||||
return "nutrient_categories"
|
||||
}
|
||||
|
||||
type NutrientCategory struct {
|
||||
BaseModel
|
||||
CategoryID ULID `json:"categoryId" db:"category_id"`
|
||||
NutrientID ULID `json:"nutrientId" db:"nutrient_id"`
|
||||
Category Category `json:"category" db:"category" gorm:"foreignKey:CategoryID"`
|
||||
Nutrient Nutrient `json:"nutrient" db:"nutrient" gorm:"foreignKey:NutrientID"`
|
||||
}
|
||||
Reference in New Issue
Block a user