patient underdev

This commit is contained in:
Sas Andy
2024-05-10 09:23:40 +07:00
parent f673933c4c
commit f6d177f2f1
5 changed files with 214 additions and 0 deletions

View File

@@ -0,0 +1,26 @@
package corporate_handlers
import (
"cpone/utils"
corporate_patient "cpone/views/corporate/Patient"
"github.com/labstack/echo/v4"
)
type PatientService interface {
}
func NewPatientHandler(us PatientService) *PatientHandler {
return &PatientHandler{
PatientService: us,
}
}
type PatientHandler struct {
PatientService PatientService
}
func (uh *PatientHandler) ShowPatient(c echo.Context) error {
helo := corporate_patient.Show()
return utils.View(c, helo)
}

View File

@@ -75,6 +75,8 @@ func SetupRoutesCorporate(app *echo.Echo, appStore db.AppStore) {
l := corporate_services.NewServicesCompany(appStore)
lh := corporate_handlers.NewCompanyHandler(l)
public.GET("/company", lh.ShowCompany)
patientHandler := corporate_handlers.NewPatientHandler(l)
public.GET("/patient", patientHandler.ShowPatient)
}
func SetupRoutesClient(app *echo.Echo, appStore db.AppStore) {