forked from ebhomengo/niki
22 lines
543 B
Go
22 lines
543 B
Go
package analytic
|
|
|
|
import (
|
|
"git.gocasts.ir/ebhomengo/niki/patientapp/repository/mysql"
|
|
analytic2 "git.gocasts.ir/ebhomengo/niki/patientapp/service/analytic"
|
|
"github.com/labstack/echo/v4"
|
|
)
|
|
|
|
func NewPatientAnalyticRouter(s *echo.Group) {
|
|
|
|
repo := mysql.NewPatientRepo()
|
|
validator := analytic2.NewValidator()
|
|
analyticService := analytic2.NewPatientAnalyticService(repo, *validator)
|
|
|
|
h := NewHandler(analyticService)
|
|
|
|
s.GET("/patients", h.PatientsAnalytic)
|
|
s.GET("/patients-summary", h.PatientsMapSummary)
|
|
s.GET("/health", h.Health)
|
|
|
|
}
|