package base

import (
	ecore "simrs-vx/internal/domain/base-entities/core"
	es "simrs-vx/internal/domain/main-entities/specialist"
	ess "simrs-vx/internal/domain/main-entities/subspecialist"
	eu "simrs-vx/internal/domain/main-entities/unit"
)

type Basic struct {
	ecore.SmallMain                       // adjust this according to the needs
	Infra_Code         *string            `json:"infra_code" gorm:"size:10"`
	Unit_Code          *string            `json:"unit_code" gorm:"size:10"`
	Unit               *eu.Unit           `json:"unit,omitempty" gorm:"foreignKey:Unit_Code;references:Code"`
	Specialist_Code    *string            `json:"specialist_code" gorm:"size:10"`
	Specialist         *es.Specialist     `json:"specialist,omitempty" gorm:"foreignKey:Specialist_Code;references:Code"`
	Subspecialist_Code *string            `json:"subspecialist_code" gorm:"size:10"`
	Subspecialist      *ess.Subspecialist `json:"subspecialist,omitempty" gorm:"foreignKey:Subspecialist_Code;references:Code"`
}

func (Basic) TableName() string {
	return "Room"
}
