package chemo

import (
	ere "simrs-vx/internal/domain/references/encounter"
	"time"

	ecore "simrs-vx/internal/domain/base-entities/core"
	erc "simrs-vx/internal/domain/references/common"

	ed "simrs-vx/internal/domain/main-entities/doctor"
	ee "simrs-vx/internal/domain/main-entities/encounter"
	eun "simrs-vx/internal/domain/main-entities/unit"
	eus "simrs-vx/internal/domain/main-entities/user"
)

type Chemo struct {
	ecore.Main                              // adjust this according to the needs
	Encounter_Id       *uint                `json:"encounter_id"`
	Encounter          *ee.Encounter        `json:"encounter,omitempty" gorm:"foreignKey:Encounter_Id;references:Id"`
	Status_Code        erc.DataVerifiedCode `json:"status_code"`
	VerifiedAt         *time.Time           `json:"verifiedAt"`
	VerifiedBy_User_Id *uint                `json:"verifiedBy_user_id"`
	VerifiedBy         *eus.User            `json:"verifiedBy,omitempty" gorm:"foreignKey:VerifiedBy_User_Id;references:Id"`
	SrcUnit_Code       *string              `json:"src_unit_code"` // klinik asal
	SrcUnit            *eun.Unit            `json:"src_unit,omitempty" gorm:"foreignKey:SrcUnit_Code;references:Code"`
	Bed                *string              `json:"bed" gorm:"size:1024"`
	Needs              *string              `json:"needs" gorm:"size:2048"`
	Doctor_Code        *string              `json:"doctor_code"`
	Doctor             *ed.Doctor           `json:"doctor" gorm:"foreignKey:Doctor_Code;references:Code"`
	NextChemoDate      *time.Time           `json:"nextChemoDate"`
	Class_Code         ere.ChemoClassCode   `json:"class_code"`
}
