Documentation ¶
Index ¶
- Variables
- type Cultivation
- type Cultivations
- type Harvesting
- type Harvestings
- type Id
- type Plant
- type PlantTemperature
- type PlantTemperatures
- type PlantWater
- type PlantWaters
- type Plants
- type Season
- type Seasons
- type Temperature
- type Temperatures
- type User
- type Users
- type Water
- type Watering
- type Waterings
- type Waters
Constants ¶
This section is empty.
Variables ¶
View Source
var ( // ErrPlantNotFound は植物が存在しないエラーを表します。 ErrPlantNotFound = errors.New("plant not found") // ErrUserNotFound はユーザが存在しないエラーを表します。 ErrUserNotFound = errors.New("user not found") // ErrCultivationNotFound は栽培物が存在しないエラーを表します。 ErrCultivationNotFound = errors.New("cultivation not found") ErrInvalidIdToken = errors.New("Invalid ID token") )
Functions ¶
This section is empty.
Types ¶
type Cultivation ¶
type Cultivation struct { ID int `gorm:"primary_key"` CreatedAt time.Time UpdatedAt time.Time DeletedAt *time.Time `sql:"index"` UserID int User User `gorm:"constraint:OnUpdate:CASCADE,OnDelete:CASCADE;"` PlantID int Plant Plant `gorm:"constraint:OnUpdate:CASCADE,OnDelete:RESTRICT;"` StartCultivatingAt *time.Time FinishCultivatingAt *time.Time NickName string }
type Cultivations ¶
type Cultivations []Cultivation
type Harvesting ¶
type Harvestings ¶
type Harvestings []Harvesting
type Plant ¶
type Plant struct { ID int `gorm:"primary_key"` CreatedAt time.Time UpdatedAt time.Time DeletedAt *time.Time `sql:"index"` Name string NickName string Price int Period int Difficulty int Description string KitName string SeasonFrom int SeasonTo int PlantTemperatures []PlantTemperature PlantWaters []PlantWater }
type PlantTemperature ¶
type PlantTemperature struct { ID int `gorm:"primary_key"` CreatedAt time.Time UpdatedAt time.Time DeletedAt *time.Time `sql:"index"` PlantID int Plant Plant `gorm:"constraint:OnUpdate:CASCADE,OnDelete:CASCADE;"` WaterID int Water Water `gorm:"constraint:OnUpdate:CASCADE,OnDelete:CASCADE;"` Threshold int }
type PlantTemperatures ¶
type PlantTemperatures []Temperature
type PlantWater ¶
type PlantWater struct { ID int `gorm:"primary_key"` CreatedAt time.Time UpdatedAt time.Time DeletedAt *time.Time `sql:"index"` PlantID int Plant Plant `gorm:"constraint:OnUpdate:CASCADE,OnDelete:CASCADE;"` WaterID int Water Water `gorm:"constraint:OnUpdate:CASCADE,OnDelete:CASCADE;"` Threshold int }
type PlantWaters ¶
type PlantWaters []Water
type Temperature ¶
type Temperatures ¶
type Temperatures []Temperature
Click to show internal directories.
Click to hide internal directories.