|
- package model
-
- type Tracker struct {
- ID string `json:"id" gorm:"primaryKey" validate:"required"`
- Name string `json:"name" validate:"required"`
- MAC string `json:"mac" validate:"required"`
- Status string `json:"status"`
- Model string `json:"model"`
- IP string `json:"ip"`
- Position string `json:"position"`
- X float32 `json:"x"`
- Y float32 `json:"y"`
- Notes string `json:"notes"`
- Floor string `json:"floor"`
- Building string `json:"building"`
- // MODIFICATO: Cambiato in string e rimosso ,string per accettare il testo nativo dell'API
- Battery string `json:"battery" gorm:"type:text"`
- BatteryThreshold uint32 `json:"batteryThreshold"`
- // MODIFICATO: Cambiato in string e rimosso ,string
- Temperature string `json:"temperature" gorm:"type:text"`
- // NUOVI CAMPI: Aggiunti per mappare completamente il payload dell'API cloud
- Acceleration string `json:"acceleration" gorm:"type:text"`
- HeartRate string `json:"heartRate" gorm:"type:text"`
- ButtonPress bool `json:"buttonPress" gorm:"type:boolean"`
- }
|