package procedurereport

import (
	ecore "simrs-vx/internal/domain/base-entities/core"
	ed "simrs-vx/internal/domain/main-entities/doctor"
	eem "simrs-vx/internal/domain/main-entities/employee"
	ee "simrs-vx/internal/domain/main-entities/encounter"
	"time"
)

type ProcedureReport struct {
	ecore.Main                           // adjust this according to the needs
	Encounter_Id           uint64        `json:"encounter_id"  gorm:"foreignKey"`
	Encounter              *ee.Encounter `json:"encounter,omitempty" gorm:"foreignKey:Encounter_Id;references:Id"`
	Date                   *time.Time    `json:"date" gorm:"not null;size:20"`
	Doctor_Code            string        `json:"doctor_code" gorm:"size:10"`
	Doctor                 *ed.Doctor    `json:"doctor,omitempty" gorm:"foreignKey:Doctor_Code;references:Code"`
	Operator_Name          string        `json:"operator_name"`
	Assistant_Name         string        `json:"assistant_name"`
	Instrumentor_Name      string        `json:"instrumentor_name"`
	Diagnose               *string       `json:"diagnose" gorm:"size:1024"`
	Nurse_Name             string        `json:"nurse_code" gorm:"size:10"`
	Anesthesia_Doctor_Code *string       `json:"anesthesia_doctor_code" gorm:"size:10"`
	Anesthesia             *eem.Employee `json:"anesthesia,omitempty" gorm:"foreignKey:Anesthesia_Doctor_Code;references:Code"`
	Anesthesia_Nurse_Name  *string       `json:"anesthesia_nurse_name"`
	ProcedureValue         string        `json:"procedure_value"`
	ExecutionValue         string        `json:"execution_value"`
	Type                   string        `json:"type"`

	// SurgerySize_Code      *string `json:"surgerySize_code" gorm:"size:10"`
	// Billing_Code          *string `json:"billing_code" gorm:"size:10"`
	// SurgerySystem_Code    *string `json:"surgerySystem_code" gorm:"size:10"`
	// StartAt               *string `json:"startAt" gorm:"size:20"`
	// EndAt                 *string `json:"endAt" gorm:"size:20"`
	// AnesthesiaStartAt     *string `json:"anesthesiaStartAt" gorm:"size:20"`
	// AnesthesiaEndAt       *string `json:"anesthesiaEndAt" gorm:"size:20"`
	// SurgeryType_Code      *string `json:"surgeryType_code" gorm:"size:10"`
	// SurgeryStage_Code     *string `json:"surgeryStage_code" gorm:"size:10"`
	// BornMortality_Code    *string `json:"bornMortality_code" gorm:"size:10"`
	// BornLocation_Code     *string `json:"bornLocation_code" gorm:"size:10"`
	// Weight                *string `json:"weight" gorm:"size:10"`
	// BornNotes             *string `json:"bornNotes" gorm:"size:1024"`
	// Description           *string `json:"notes" gorm:"size:1024"`
	// BleedingAmount        *uint16 `json:"bleedingAmount" gorm:"size:10"`
	// BloodInType_Code      *string `json:"bloodInType_code" gorm:"size:10"`
	// BloodInAmount         *uint16 `json:"bloodInAmount" gorm:"size:10"`
	// Brand                 *string `json:"brand" gorm:"size:100"`
	// ImplantName           *string `json:"implantName" gorm:"size:100"`
	// ImplantRegisterNumber *string `json:"implantRegisterNumber" gorm:"size:100"`
	// ImplantCompanionName  *string `json:"implantCompanionName" gorm:"size:100"`
	// SpecimentDest_Code    *string `json:"specimentDest" gorm:"size:100"`
	// TissueInfo            *string `json:"tissueInfo" gorm:"size:100"`

	//PROPER
	// Doctor_Code                 string        `json:"doctor_code" gorm:"size:10"`
	// Doctor                      *ed.Doctor    `json:"doctor,omitempty" gorm:"foreignKey:Doctor_Code;references:Code"`
	// Operator_Employe_Id         uint          `json:"operator_employe_id"`
	// Operator_Employe            *eem.Employee `json:"operator_employe,omitempty" gorm:"foreignKey:Operator_Employe_Id;references:Id"`
	// Assistant_Employe_Id        uint          `json:"assistant_employe_id"`
	// Instrumentor_Employe_Id     uint          `json:"instrumentor_employe_id"`
	// Instrumentor_Employe        *eem.Employee `json:"instrumentor_employe,omitempty" gorm:"foreignKey:Instrumentor_Employe_Id;references:Id"`
	// Nurse_Code                  string        `json:"nurse_code" gorm:"size:10"`
	// Nurse                       *en.Nurse     `json:"nurse,omitempty" gorm:"foreignKey:Nurse_Code;references:Code"`
	// Anesthesia_Doctor_Code      string        `json:"anesthesia_doctor_code" gorm:"size:10"`
	// Anesthesia                  *eem.Employee `json:"anesthesia,omitempty" gorm:"foreignKey:Anesthesia_Doctor_Code;references:Code"`
	// Anesthesia_Nurse_Employe_Id uint          `json:"anesthesia_nurse_employe_id"`
	// Anesthesia_Nurse            *eem.Employee `json:"anesthesia_nurse,omitempty" gorm:"foreignKey:Anesthesia_Nurse_Employe_Id;references:Id"`
}
