Merge branch 'dev' of github.com:dikstub-rssa/simrs-be into feat/data-vaksin-192

This commit is contained in:
dpurbosakti
2025-12-16 13:50:11 +07:00
399 changed files with 14747 additions and 3595 deletions
+76 -17
View File
@@ -4,13 +4,11 @@ import (
"net/http"
/******************** main / transaction ********************/
actionreport "simrs-vx/internal/interface/main-handler/action-report"
adime "simrs-vx/internal/interface/main-handler/adime"
admemployeehist "simrs-vx/internal/interface/main-handler/adm-employee-hist"
ambulancetransportrequest "simrs-vx/internal/interface/main-handler/ambulance-transport-req"
auth "simrs-vx/internal/interface/main-handler/authentication"
chemo "simrs-vx/internal/interface/main-handler/chemo"
chemoprotocol "simrs-vx/internal/interface/main-handler/chemo-protocol"
consultation "simrs-vx/internal/interface/main-handler/consultation"
controlletter "simrs-vx/internal/interface/main-handler/control-letter"
counter "simrs-vx/internal/interface/main-handler/counter"
@@ -34,9 +32,14 @@ import (
practiceschedule "simrs-vx/internal/interface/main-handler/practice-schedule"
prescription "simrs-vx/internal/interface/main-handler/prescription"
prescriptionitem "simrs-vx/internal/interface/main-handler/prescription-item"
procedurereport "simrs-vx/internal/interface/main-handler/procedure-report"
procedureroom "simrs-vx/internal/interface/main-handler/procedure-room"
procedureroomorder "simrs-vx/internal/interface/main-handler/procedure-room-order"
procedureroomorderitem "simrs-vx/internal/interface/main-handler/procedure-room-order-item"
responsibledoctorhist "simrs-vx/internal/interface/main-handler/responsible-doctor-hist"
resume "simrs-vx/internal/interface/main-handler/resume"
sbar "simrs-vx/internal/interface/main-handler/sbar"
screening "simrs-vx/internal/interface/main-handler/screening"
soapi "simrs-vx/internal/interface/main-handler/soapi"
uploadfile "simrs-vx/internal/interface/main-handler/upload-file"
vaccineData "simrs-vx/internal/interface/main-handler/vaccine-data"
@@ -66,7 +69,7 @@ import (
gs "simrs-vx/internal/infra/gorm-setting"
minio "simrs-vx/internal/infra/minio"
ssdb "simrs-vx/internal/infra/ss-db"
simgossync "simrs-vx/internal/infra/sync-cfg"
sync "simrs-vx/internal/infra/sync-consumer-cfg"
/******************** pkg ********************/
cmw "simrs-vx/pkg/cors-manager-mw"
@@ -79,6 +82,8 @@ import (
/******************** sources ********************/
antibioticsrc "simrs-vx/internal/interface/main-handler/antibiotic-src"
antibioticsrccat "simrs-vx/internal/interface/main-handler/antibiotic-src-category"
chemoplan "simrs-vx/internal/interface/main-handler/chemo-plan"
chemoprotocol "simrs-vx/internal/interface/main-handler/chemo-protocol"
device "simrs-vx/internal/interface/main-handler/device"
diagnosesrc "simrs-vx/internal/interface/main-handler/diagnose-src"
division "simrs-vx/internal/interface/main-handler/division"
@@ -94,6 +99,8 @@ import (
itemprice "simrs-vx/internal/interface/main-handler/item-price"
language "simrs-vx/internal/interface/main-handler/language"
material "simrs-vx/internal/interface/main-handler/material"
materialpackage "simrs-vx/internal/interface/main-handler/material-package"
materialpackageitem "simrs-vx/internal/interface/main-handler/material-package-item"
mcusrc "simrs-vx/internal/interface/main-handler/mcu-src"
mcusrccategory "simrs-vx/internal/interface/main-handler/mcu-src-category"
mcusubsrc "simrs-vx/internal/interface/main-handler/mcu-sub-src"
@@ -110,8 +117,6 @@ import (
subspecialist "simrs-vx/internal/interface/main-handler/subspecialist"
subspecialistposition "simrs-vx/internal/interface/main-handler/subspecialist-position"
therapyprotocol "simrs-vx/internal/interface/main-handler/therapy-protocol"
unit "simrs-vx/internal/interface/main-handler/unit"
unitposition "simrs-vx/internal/interface/main-handler/unit-position"
uom "simrs-vx/internal/interface/main-handler/uom"
vehicle "simrs-vx/internal/interface/main-handler/vehicle"
vehiclehist "simrs-vx/internal/interface/main-handler/vehicle-hist"
@@ -133,6 +138,7 @@ import (
reference "simrs-vx/internal/interface/main-handler/reference"
referral "simrs-vx/internal/interface/main-handler/referral"
vclaimsep "simrs-vx/internal/interface/main-handler/vclaim-sep"
vclaimsepcontrolletter "simrs-vx/internal/interface/main-handler/vclaim-sep-control-letter"
vclaimsephist "simrs-vx/internal/interface/main-handler/vclaim-sep-hist"
vclaimsepprint "simrs-vx/internal/interface/main-handler/vclaim-sep-print"
)
@@ -148,7 +154,7 @@ func SetRoutes() http.Handler {
a.RegisterExtCall(mh.I.SetClient)
a.RegisterExtCall(ibpjs.SetConfig)
a.RegisterExtCall(validation.RegisterValidation)
a.RegisterExtCall(simgossync.SetConfig)
a.RegisterExtCall(sync.SetConfig)
a.RegisterExtCall(docscfg.ParseCfg)
a.RegisterExtCall(ibpjs.SetConfig)
@@ -173,7 +179,7 @@ func SetRoutes() http.Handler {
hc.RegCrud(r, "/v1/sbar", auth.GuardMW, sbar.O)
hc.RegCrud(r, "/v1/prescription-item", prescriptionitem.O)
hc.RegCrud(r, "/v1/device-order-item", deviceorderitem.O)
hc.RegCrud(r, "/v1/action-report", auth.GuardMW, actionreport.O)
hc.RegCrud(r, "/v1/procedure-report", auth.GuardMW, procedurereport.O)
hc.RegCrud(r, "/v1/material-order-item", materialorderitem.O)
hk.GroupRoutes("/v1/encounter", r, auth.GuardMW, hk.MapHandlerFunc{
@@ -188,9 +194,10 @@ func SetRoutes() http.Handler {
"PATCH /{id}/cancel": encounter.O.Cancel,
"PATCH /{id}/reject": encounter.O.Reject,
"PATCH /{id}/skip": encounter.O.Skip,
"PATCH /{id}/req-switch-unit": encounter.O.RequestSwitchUnit,
"PATCH /{id}/approve-switch-unit": encounter.O.ApproveSwitchUnit,
"PATCH /{id}/cancel-switch-unit": encounter.O.CancelSwitchUnit,
"PATCH /{id}/req-switch-unit": encounter.O.RequestSwitchSpecialist,
"PATCH /{id}/approve-switch-unit": encounter.O.ApproveSwitchSpecialist,
"PATCH /{id}/cancel-switch-unit": encounter.O.CancelSwitchSpecialist,
"POST /create-with-patient": encounter.O.CreateWithPatient,
})
hk.GroupRoutes("/v1/mcu-order", r, auth.GuardMW, hk.MapHandlerFunc{
"GET /": mcuorder.O.GetList,
@@ -268,6 +275,16 @@ func SetRoutes() http.Handler {
"DELETE /{id}": materialorder.O.Delete,
"PATCH /{id}/complete": materialorder.O.Complete,
})
hc.RegCrud(r, "/v1/procedure-room", procedureroom.O)
hk.GroupRoutes("/v1/procedure-room-order", r, auth.GuardMW, hk.MapHandlerFunc{
"GET /": procedureroomorder.O.GetList,
"GET /{id}": procedureroomorder.O.GetDetail,
"POST /": procedureroomorder.O.Create,
"PATCH /{id}": procedureroomorder.O.Update,
"DELETE /{id}": procedureroomorder.O.Delete,
"PATCH /{id}/submit": procedureroomorder.O.Submit,
})
hc.RegCrud(r, "/v1/procedure-room-order-item", procedureroomorderitem.O)
hk.GroupRoutes("/v1/consultation", r, auth.GuardMW, hk.MapHandlerFunc{
"GET /": consultation.O.GetList,
"GET /{id}": consultation.O.GetDetail,
@@ -299,7 +316,18 @@ func SetRoutes() http.Handler {
"PATCH /{id}/verify": therapyprotocol.O.Verify,
"PATCH /{id}/reject": therapyprotocol.O.Reject,
})
hc.RegCrud(r, "/v1/chemo-protocol", chemoprotocol.O)
hk.GroupRoutes("/v1/chemo-protocol", r, auth.GuardMW, hk.MapHandlerFunc{
"GET /": chemoprotocol.O.GetList,
"GET /{id}": chemoprotocol.O.GetDetail,
"POST /": chemoprotocol.O.Create,
"PATCH /{id}": chemoprotocol.O.Update,
"DELETE /{id}": chemoprotocol.O.Delete,
"PATCH /{id}/verify": chemoprotocol.O.Verify,
"PATCH /{id}/reject": chemoprotocol.O.Reject,
})
hk.GroupRoutes("/v1/chemo-plan", r, auth.GuardMW, hk.MapHandlerFunc{
"PATCH /{id}/fail": chemoplan.O.Fail,
})
hc.RegCrud(r, "/v1/upload-file", uploadfile.O)
hc.RegCrud(r, "/v1/vaccine-data", vaccineData.O)
hc.RegCrud(r, "/v1/encounter-document", encounterdocument.O)
@@ -314,7 +342,11 @@ func SetRoutes() http.Handler {
"PATCH /{id}/verify": resume.Verify,
"PATCH /{id}/validate": resume.Validate,
})
hk.GroupRoutes("/v1/screening", r, auth.GuardMW, hk.MapHandlerFunc{
"POST /": screening.O.Create,
"GET /": screening.O.GetList,
"GET /{id}": screening.O.GetDetail,
})
/******************** actor ********************/
hc.RegCrud(r, "/v1/person", person.O)
hc.RegCrud(r, "/v1/person-address", personaddress.O)
@@ -348,12 +380,31 @@ func SetRoutes() http.Handler {
/******************** sources ********************/
hc.RegCrudByCode(r, "/v1/division", division.O)
hc.RegCrudByCode(r, "/v1/division-position", divisionposition.O)
hc.RegCrudByCode(r, "/v1/installation", installation.O)
hc.RegCrudByCode(r, "/v1/unit", unit.O)
hk.GroupRoutes("/v1/installation", r, hk.MapHandlerFunc{
"GET /": installation.O.GetList,
"GET /{id}": installation.O.GetDetail,
"POST /": installation.O.Create,
"PATCH /{id}": installation.O.Update,
"DELETE /{id}": installation.O.Delete,
"POST /bulk": installation.O.CreateBulk,
})
hc.RegCrudByCode(r, "/v1/installation-position", installationposition.O)
hc.RegCrudByCode(r, "/v1/unit-position", unitposition.O)
hc.RegCrudByCode(r, "/v1/specialist", specialist.O)
hc.RegCrudByCode(r, "/v1/subspecialist", subspecialist.O)
hk.GroupRoutes("/v1/specialist", r, hk.MapHandlerFunc{
"GET /": specialist.O.GetList,
"GET /{id}": specialist.O.GetDetail,
"POST /": specialist.O.Create,
"PATCH /{id}": specialist.O.Update,
"DELETE /{id}": specialist.O.Delete,
"POST /bulk": specialist.O.CreateBulk,
})
hk.GroupRoutes("/v1/subspecialist", r, hk.MapHandlerFunc{
"GET /": subspecialist.O.GetList,
"GET /{id}": subspecialist.O.GetDetail,
"POST /": subspecialist.O.Create,
"PATCH /{id}": subspecialist.O.Update,
"DELETE /{id}": subspecialist.O.Delete,
"POST /bulk": subspecialist.O.CreateBulk,
})
hc.RegCrudByCode(r, "/v1/specialist-position", specialistposition.O)
hc.RegCrudByCode(r, "/v1/subspecialist-position", subspecialistposition.O)
hc.RegCrudByCode(r, "/v1/infra", infra.O)
@@ -372,6 +423,8 @@ func SetRoutes() http.Handler {
hc.RegCrudByCode(r, "/v1/medicine", medicine.O)
hc.RegCrudByCode(r, "/v1/device", device.O)
hc.RegCrudByCode(r, "/v1/material", material.O)
hc.RegCrudByCode(r, "/v1/material-package", materialpackage.O)
hc.RegCrud(r, "/v1/material-package-item", materialpackageitem.O)
hc.RegCrud(r, "/v1/doctor-fee", doctorfee.O)
hc.RegCrudByCode(r, "/v1/medical-action-src", medicalactionsrc.O)
hc.RegCrud(r, "/v1/medical-action-src-item", medicalactionsrcitem.O)
@@ -394,6 +447,12 @@ func SetRoutes() http.Handler {
"DELETE /{number}": vclaimsep.O.Delete,
})
hk.GroupRoutes("/v1/vclaim-sep-control-letter", r, hk.MapHandlerFunc{
"POST /": vclaimsepcontrolletter.O.Create,
"GET /{number}": vclaimsepcontrolletter.O.GetDetail,
"DELETE /{number}": vclaimsepcontrolletter.O.Delete,
})
hk.GroupRoutes("/v1/vclaim-sep-hist", r, hk.MapHandlerFunc{
"GET /": vclaimsephist.O.GetList,
})