penambahan template
This commit is contained in:
21
pkg/handlers/poliklinik/poliklinik.go
Normal file
21
pkg/handlers/poliklinik/poliklinik.go
Normal file
@@ -0,0 +1,21 @@
|
||||
package poliklinik
|
||||
|
||||
import (
|
||||
""
|
||||
"github.com/gin-gonic/gin"
|
||||
"log"
|
||||
"net/http"
|
||||
"template_blueprint/internal/database"
|
||||
connDatabase "template_blueprint/pkg/database/satu_data"
|
||||
)
|
||||
|
||||
func GetDataPoliklinik(c *gin.Context) {
|
||||
db := database.New().GetDB("satudata")
|
||||
satudata := connDatabase.NewDatabaseService(db)
|
||||
statuspelayanan := c.Param("statuspelayanan")
|
||||
|
||||
log.Println("REQUEST", statuspelayanan)
|
||||
dataPoliklinik := satudata.PoliklinikGetData(statuspelayanan)
|
||||
|
||||
c.JSON(http.StatusOK, dataPoliklinik)
|
||||
}
|
||||
Reference in New Issue
Block a user