adjustment detail installation,specialis, subspecialist
This commit is contained in:
@@ -2,6 +2,7 @@ package specialist
|
||||
|
||||
import (
|
||||
ecore "simrs-vx/internal/domain/base-entities/core"
|
||||
espb "simrs-vx/internal/domain/main-entities/specialist-position/base"
|
||||
)
|
||||
|
||||
type CreateDto struct {
|
||||
@@ -25,8 +26,9 @@ type FilterDto struct {
|
||||
}
|
||||
|
||||
type ReadDetailDto struct {
|
||||
Id uint16 `json:"id"`
|
||||
Code *string `json:"code"`
|
||||
Id uint16 `json:"id"`
|
||||
Code *string `json:"code"`
|
||||
Includes string `json:"includes"`
|
||||
}
|
||||
|
||||
type UpdateDto struct {
|
||||
@@ -46,16 +48,18 @@ type MetaDto struct {
|
||||
|
||||
type ResponseDto struct {
|
||||
ecore.SmallMain
|
||||
Code string `json:"code"`
|
||||
Name string `json:"name"`
|
||||
Unit_Id *uint16 `json:"unit_id"`
|
||||
Code string `json:"code"`
|
||||
Name string `json:"name"`
|
||||
Unit_Id *uint16 `json:"unit_id"`
|
||||
SpecialistPositions []espb.Basic `json:"specialistPositions,omitempty"`
|
||||
}
|
||||
|
||||
func (d Specialist) ToResponse() ResponseDto {
|
||||
resp := ResponseDto{
|
||||
Code: d.Code,
|
||||
Name: d.Name,
|
||||
Unit_Id: d.Unit_Id,
|
||||
Code: d.Code,
|
||||
Name: d.Name,
|
||||
Unit_Id: d.Unit_Id,
|
||||
SpecialistPositions: d.SpecialistPositions,
|
||||
}
|
||||
resp.SmallMain = d.SmallMain
|
||||
return resp
|
||||
|
||||
@@ -2,6 +2,7 @@ package subspecialist
|
||||
|
||||
import (
|
||||
ecore "simrs-vx/internal/domain/base-entities/core"
|
||||
espb "simrs-vx/internal/domain/main-entities/subspecialist-position/base"
|
||||
)
|
||||
|
||||
type CreateDto struct {
|
||||
@@ -25,8 +26,9 @@ type FilterDto struct {
|
||||
}
|
||||
|
||||
type ReadDetailDto struct {
|
||||
Id uint16 `json:"id"`
|
||||
Code *string `json:"code"`
|
||||
Id uint16 `json:"id"`
|
||||
Code *string `json:"code"`
|
||||
Includes string `json:"includes"`
|
||||
}
|
||||
|
||||
type UpdateDto struct {
|
||||
@@ -46,9 +48,10 @@ type MetaDto struct {
|
||||
|
||||
type ResponseDto struct {
|
||||
ecore.SmallMain
|
||||
Code string `json:"code"`
|
||||
Name string `json:"name"`
|
||||
Specialist_Id *uint16 `json:"specialist_id"`
|
||||
Code string `json:"code"`
|
||||
Name string `json:"name"`
|
||||
Specialist_Id *uint16 `json:"specialist_id"`
|
||||
Subspecialist []espb.Basic `json:"subspecialistPositions,omitempty"`
|
||||
}
|
||||
|
||||
func (d Subspecialist) ToResponse() ResponseDto {
|
||||
@@ -56,6 +59,7 @@ func (d Subspecialist) ToResponse() ResponseDto {
|
||||
Code: d.Code,
|
||||
Name: d.Name,
|
||||
Specialist_Id: d.Specialist_Id,
|
||||
Subspecialist: d.SubspecialistPositions,
|
||||
}
|
||||
resp.SmallMain = d.SmallMain
|
||||
return resp
|
||||
|
||||
Reference in New Issue
Block a user