final project structure

This commit is contained in:
2025-04-15 22:36:22 +02:00
parent d6b3e88b5f
commit 284a40fac2
65 changed files with 668 additions and 447 deletions

View File

@@ -0,0 +1,12 @@
package cropprotection
import "wagfarm-api/log/base"
type CropProtectionLog struct {
base.FieldWorkLog
PesticideID uint `gorm:"not null"`
Pesticide taxonomy.Pesticide `gorm:"constraint:OnUpdate:CASCADE,OnDelete:CASCADE;not null"`
Amount float64 `gorm:"not null"` // in units of the pesticide
PerformedByID uint `gorm:"not null"`
PerformedBy taxonomy.Worker `gorm:"constraint:OnUpdate:CASCADE,OnDelete:CASCADE;not null"`
}