resolve conflict
This commit is contained in:
@@ -24,9 +24,11 @@ type FilterDto struct {
|
||||
AntibioticSrc_Id *uint `json:"mcu-src-id"`
|
||||
Result *string `json:"result"`
|
||||
Status_Code erc.DataStatusCode `json:"status-code"`
|
||||
Includes string `json:"includes"`
|
||||
}
|
||||
type ReadDetailDto struct {
|
||||
Id uint `json:"id"`
|
||||
Id uint `json:"id"`
|
||||
Includes string `json:"includes"`
|
||||
}
|
||||
|
||||
type UpdateDto struct {
|
||||
|
||||
@@ -15,6 +15,7 @@ type CreateDto struct {
|
||||
type ReadListDto struct {
|
||||
FilterDto
|
||||
Includes string `json:"includes"`
|
||||
Sort string `json:"sort"`
|
||||
Pagination ecore.Pagination
|
||||
}
|
||||
|
||||
|
||||
@@ -4,6 +4,7 @@ import (
|
||||
ecore "simrs-vx/internal/domain/base-entities/core"
|
||||
ep "simrs-vx/internal/domain/main-entities/person"
|
||||
eu "simrs-vx/internal/domain/main-entities/user"
|
||||
"time"
|
||||
|
||||
erc "simrs-vx/internal/domain/references/common"
|
||||
erg "simrs-vx/internal/domain/references/organization"
|
||||
@@ -55,22 +56,26 @@ type MetaDto struct {
|
||||
|
||||
type ResponseDto struct {
|
||||
ecore.Main
|
||||
User_Id *uint `json:"user_id"`
|
||||
User *eu.User `json:"user,omitempty"`
|
||||
Person_Id *uint `json:"person_id"`
|
||||
Person *ep.Person `json:"person,omitempty"`
|
||||
Number *string `json:"number"`
|
||||
Status_Code erc.ActiveStatusCode `json:"status_code"`
|
||||
User_Id *uint `json:"user_id"`
|
||||
User *eu.User `json:"user,omitempty"`
|
||||
Person_Id *uint `json:"person_id"`
|
||||
Person *ep.Person `json:"person,omitempty"`
|
||||
Number *string `json:"number"`
|
||||
Position_Code *erg.EmployeePositionCode `json:"position_code"`
|
||||
Contract_ExpiredDate *time.Time `json:"contract_expiredDate"`
|
||||
Status_Code erc.ActiveStatusCode `json:"status_code"`
|
||||
}
|
||||
|
||||
func (d Employee) ToResponse() ResponseDto {
|
||||
resp := ResponseDto{
|
||||
User_Id: d.User_Id,
|
||||
User: d.User,
|
||||
Person_Id: d.Person_Id,
|
||||
Person: d.Person,
|
||||
Number: d.Number,
|
||||
Status_Code: d.Status_Code,
|
||||
User_Id: d.User_Id,
|
||||
User: d.User,
|
||||
Person_Id: d.Person_Id,
|
||||
Person: d.Person,
|
||||
Number: d.Number,
|
||||
Position_Code: d.Position_Code,
|
||||
Contract_ExpiredDate: d.Contract_ExpiredDate,
|
||||
Status_Code: d.Status_Code,
|
||||
}
|
||||
resp.Main = d.Main
|
||||
return resp
|
||||
|
||||
@@ -17,6 +17,7 @@ import (
|
||||
// internal - domain - main-entities
|
||||
ed "simrs-vx/internal/domain/main-entities/doctor"
|
||||
ee "simrs-vx/internal/domain/main-entities/encounter"
|
||||
emoib "simrs-vx/internal/domain/main-entities/mcu-order-item/base"
|
||||
)
|
||||
|
||||
type CreateDto struct {
|
||||
@@ -85,7 +86,8 @@ type ResponseDto struct {
|
||||
ExaminationDate *time.Time `json:"examinationDate"`
|
||||
Number uint8 `json:"number"`
|
||||
Temperature float64 `json:"temperature"`
|
||||
UrgencyLevel_Code ercl.McuUrgencyLevelCode `json:"urgencyLevel_code""`
|
||||
UrgencyLevel_Code ercl.McuUrgencyLevelCode `json:"urgencyLevel_code"`
|
||||
Items []*emoib.McuOrderItem `json:"items"`
|
||||
}
|
||||
|
||||
func (d McuOrder) ToResponse() ResponseDto {
|
||||
@@ -100,6 +102,7 @@ func (d McuOrder) ToResponse() ResponseDto {
|
||||
Number: d.Number,
|
||||
Temperature: d.Temperature,
|
||||
UrgencyLevel_Code: d.UrgencyLevel_Code,
|
||||
Items: d.Items,
|
||||
}
|
||||
resp.Main = d.Main
|
||||
return resp
|
||||
|
||||
@@ -4,6 +4,7 @@ import (
|
||||
ecore "simrs-vx/internal/domain/base-entities/core"
|
||||
ed "simrs-vx/internal/domain/main-entities/doctor"
|
||||
ee "simrs-vx/internal/domain/main-entities/encounter"
|
||||
emoib "simrs-vx/internal/domain/main-entities/mcu-order-item/base"
|
||||
"time"
|
||||
|
||||
ercl "simrs-vx/internal/domain/references/clinical"
|
||||
@@ -23,6 +24,11 @@ type McuOrder struct {
|
||||
Temperature float64 `json:"temperature"`
|
||||
UrgencyLevel_Code ercl.McuUrgencyLevelCode `json:"urgencyLevel_code" gorm:"not null;size:15"`
|
||||
Scope_Code ercl.McuScopeCode `json:"scope_code" gorm:"index;size:10"`
|
||||
Items []*emoib.McuOrderItem `json:"items" gorm:"foreignKey:McuOrder_Id;references:Id"`
|
||||
}
|
||||
|
||||
func (d McuOrder) IsNotNew() bool {
|
||||
return d.Status_Code != erc.DSCNew
|
||||
}
|
||||
|
||||
func (d McuOrder) IsCompleted() bool {
|
||||
|
||||
@@ -0,0 +1,22 @@
|
||||
package personaddress
|
||||
|
||||
import (
|
||||
ecore "simrs-vx/internal/domain/base-entities/core"
|
||||
epr "simrs-vx/internal/domain/main-entities/postal-region"
|
||||
ev "simrs-vx/internal/domain/main-entities/village"
|
||||
|
||||
erp "simrs-vx/internal/domain/references/person"
|
||||
)
|
||||
|
||||
type PersonAddress struct {
|
||||
ecore.Main // adjust this according to the needs
|
||||
Person_Id uint `json:"person_id"`
|
||||
Address string `json:"address" gorm:"size:150"`
|
||||
LocationType_Code erp.AddressLocationTypeCode `json:"locationType_code" gorm:"size:10"`
|
||||
Rt string `json:"rt" gorm:"size:2"`
|
||||
Rw string `json:"rw" gorm:"size:2"`
|
||||
PostalRegion_Code *string `json:"postalRegion_code" gorm:"size:6"`
|
||||
PostalRegion *epr.PostalRegion `json:"postalRegion,omitempty" gorm:"foreignKey:PostalRegion_Code;references:Code"`
|
||||
Village_Code *string `json:"village_code" gorm:"size:10"`
|
||||
Village *ev.Village `json:"village,omitempty" gorm:"foreignKey:Village_Code;references:Code"`
|
||||
}
|
||||
@@ -1,22 +1,9 @@
|
||||
package personaddress
|
||||
|
||||
import (
|
||||
ecore "simrs-vx/internal/domain/base-entities/core"
|
||||
epr "simrs-vx/internal/domain/main-entities/postal-region"
|
||||
ev "simrs-vx/internal/domain/main-entities/village"
|
||||
|
||||
erp "simrs-vx/internal/domain/references/person"
|
||||
eb "simrs-vx/internal/domain/main-entities/person-address/base"
|
||||
)
|
||||
|
||||
type PersonAddress struct {
|
||||
ecore.Main // adjust this according to the needs
|
||||
Person_Id uint `json:"person_id"`
|
||||
Address string `json:"address" gorm:"size:150"`
|
||||
LocationType_Code erp.AddressLocationTypeCode `json:"locationType_code" gorm:"size:10"`
|
||||
Rt string `json:"rt" gorm:"size:2"`
|
||||
Rw string `json:"rw" gorm:"size:2"`
|
||||
PostalRegion_Code *string `json:"postalRegion_code" gorm:"size:6"`
|
||||
PostalRegion *epr.PostalRegion `json:"postalRegion,omitempty" gorm:"foreignKey:PostalRegion_Code;references:Code"`
|
||||
Village_Code *string `json:"village_code" gorm:"size:10"`
|
||||
Village *ev.Village `json:"village,omitempty" gorm:"foreignKey:Village_Code;references:Code"`
|
||||
eb.PersonAddress
|
||||
}
|
||||
|
||||
@@ -0,0 +1,13 @@
|
||||
package personcontact
|
||||
|
||||
import (
|
||||
ecore "simrs-vx/internal/domain/base-entities/core"
|
||||
erp "simrs-vx/internal/domain/references/person"
|
||||
)
|
||||
|
||||
type PersonContact struct {
|
||||
ecore.Main // adjust this according to the needs
|
||||
Person_Id uint `json:"person_id"`
|
||||
Type_Code erp.ContactTypeCode `json:"type_code" gorm:"size:15"`
|
||||
Value string `json:"value" gorm:"size:100"`
|
||||
}
|
||||
@@ -1,13 +1,9 @@
|
||||
package personcontact
|
||||
|
||||
import (
|
||||
ecore "simrs-vx/internal/domain/base-entities/core"
|
||||
erp "simrs-vx/internal/domain/references/person"
|
||||
eb "simrs-vx/internal/domain/main-entities/person-contact/base"
|
||||
)
|
||||
|
||||
type PersonContact struct {
|
||||
ecore.Main // adjust this according to the needs
|
||||
Person_Id uint `json:"person_id"`
|
||||
Type_Code erp.ContactTypeCode `json:"type_code" gorm:"size:15"`
|
||||
Value string `json:"value" gorm:"size:100"`
|
||||
eb.PersonContact
|
||||
}
|
||||
|
||||
@@ -32,7 +32,7 @@ type FilterDto struct {
|
||||
Encounter_Id *uint `json:"encounter-id"`
|
||||
Employee_Id *uint `json:"employee-id"`
|
||||
Time *time.Time `json:"time"`
|
||||
TypeCode erc.SoapiTypeCode `json:"typeCode"`
|
||||
TypeCode erc.SoapiTypeCode `json:"type-code"`
|
||||
Value *string `json:"value"`
|
||||
}
|
||||
|
||||
|
||||
@@ -18,14 +18,16 @@ const (
|
||||
EPCReg EmployeePositionCode = "reg" // Admisi/Pendaftaran
|
||||
EPCNur EmployeePositionCode = "nur" // Perawat
|
||||
EPCDoc EmployeePositionCode = "doc" // Dokter
|
||||
EPCNut EmployeePositionCode = "nut" // Ahli gizi
|
||||
EPCMwi EmployeePositionCode = "miw" // Bidan
|
||||
EPCThr EmployeePositionCode = "thr" // Terapis
|
||||
EPCNut EmployeePositionCode = "nut" // Ahli gizi
|
||||
EPCLab EmployeePositionCode = "lab" // Laboran
|
||||
EPCPha EmployeePositionCode = "pha" // Farmasi
|
||||
EPCPay EmployeePositionCode = "pay" // Pembayaran
|
||||
EPCHur EmployeePositionCode = "hue" // Sumber Daya Manusia
|
||||
EPCGea EmployeePositionCode = "gea" // Bagian Umum
|
||||
EPCMan EmployeePositionCode = "man" // Manajemen
|
||||
EPCNom EmployeePositionCode = "nom" // Non Medic
|
||||
// EPCPay EmployeePositionCode = "pay" // Pembayaran
|
||||
// EPCHur EmployeePositionCode = "hue" // Sumber Daya Manusia
|
||||
// EPCGea EmployeePositionCode = "gea" // Bagian Umum
|
||||
// EPCMan EmployeePositionCode = "man" // Manajemen
|
||||
|
||||
IPCSpecialist = "specialist-intern"
|
||||
IPCNurse = "nurse-intern"
|
||||
|
||||
Reference in New Issue
Block a user