package dto

type BeforeFlightInspectionAttributes struct {
	ID                        string                    `json:"id,omitempty" example:"019d6772-471c-7b70-b42a-d94020ef61e4"`
	FlightInspectionID        string                    `json:"flight_inspection_id,omitempty" example:"019d6772-471c-7b70-b42a-d94020ef61e4"`
	FlightInspection          *FlightInspectionResource `json:"flight_inspection,omitempty"`
	OilEngineNR1Checked       *bool                     `json:"oil_engine_nr1_checked,omitempty"`
	OilEngineNR2Checked       *bool                     `json:"oil_engine_nr2_checked,omitempty"`
	HydraulicLHChecked        *bool                     `json:"hydraulic_lh_checked,omitempty"`
	HydraulicRHChecked        *bool                     `json:"hydraulic_rh_checked,omitempty"`
	OilTransmissionMGBChecked *bool                     `json:"oil_transmission_mgb_checked,omitempty"`
	OilTransmissionIGBChecked *bool                     `json:"oil_transmission_igb_checked,omitempty"`
	OilTransmissionTGBChecked *bool                     `json:"oil_transmission_tgb_checked,omitempty"`
	FuelAmount                *float64                  `json:"fuel_amount,omitempty" example:"500.5"`
	FuelUnit                  string                    `json:"fuel_unit,omitempty" example:"LT"`
	FuelAddedAmount           *float64                  `json:"fuel_added_amount,omitempty" example:"100.0"`
	Note                      *string                   `json:"note,omitempty" example:"All checks completed"`
	CreatedAt                 string                    `json:"created_at,omitempty" example:"2026-04-09T05:00:00Z"`
	UpdatedAt                 string                    `json:"updated_at,omitempty" example:"2026-04-09T05:00:00Z"`
}

type BeforeFlightInspectionResource struct {
	Type       string                           `json:"type" example:"before_flight_inspection"`
	ID         string                           `json:"id,omitempty" example:"019d6772-471c-7b70-b42a-d94020ef61e4"`
	Attributes BeforeFlightInspectionAttributes `json:"attributes"`
}

type BeforeFlightInspectionResponse struct {
	Data BeforeFlightInspectionResource `json:"data"`
}

type BeforeFlightInspectionUpsertAttributes struct {
	OilEngineNR1Checked       *bool    `json:"oil_engine_nr1_checked,omitempty"`
	OilEngineNR2Checked       *bool    `json:"oil_engine_nr2_checked,omitempty"`
	HydraulicLHChecked        *bool    `json:"hydraulic_lh_checked,omitempty"`
	HydraulicRHChecked        *bool    `json:"hydraulic_rh_checked,omitempty"`
	OilTransmissionMGBChecked *bool    `json:"oil_transmission_mgb_checked,omitempty"`
	OilTransmissionIGBChecked *bool    `json:"oil_transmission_igb_checked,omitempty"`
	OilTransmissionTGBChecked *bool    `json:"oil_transmission_tgb_checked,omitempty"`
	FuelAmount                *float64 `json:"fuel_amount,omitempty" validate:"omitempty,gte=0"`
	FuelUnit                  *string  `json:"fuel_unit,omitempty" validate:"omitempty,oneof=LT KG POUND"`
	FuelAddedAmount           *float64 `json:"fuel_added_amount,omitempty" validate:"omitempty,gte=0"`
	Note                      *string  `json:"note,omitempty"`
}

type BeforeFlightInspectionUpsertData struct {
	Type       string                                 `json:"type" validate:"required,oneof=before_flight_inspection_upsert before_flight_inspection"`
	Attributes BeforeFlightInspectionUpsertAttributes `json:"attributes" validate:"required"`
}

type BeforeFlightInspectionUpsertRequest struct {
	Data BeforeFlightInspectionUpsertData `json:"data" validate:"required"`
}
