From c38c4bda17e3774ec0fd58f90ba5e59e1f0639a2 Mon Sep 17 00:00:00 2001 From: liuxiaolong <736321739@qq.com> Date: 星期三, 30 十月 2019 16:39:29 +0800 Subject: [PATCH] swagger add ApiKeyAuth --- router/router.go | 14 +++++++++++++- 1 files changed, 13 insertions(+), 1 deletions(-) diff --git a/router/router.go b/router/router.go index 76c7ec2..2d1530d 100644 --- a/router/router.go +++ b/router/router.go @@ -42,6 +42,7 @@ sysMenuController := new(controllers.SysMenuController) clusterController := new(controllers.ClusterController) sysRoleController := new(controllers.RoleController) + ptController := new(controllers.PanTiltController) sysApi := r.Group("/data/api-u/sys") { @@ -62,7 +63,8 @@ { userApi.GET("/current", userController.Current) userApi.GET("/findAllUser", userController.FindAllUser) - userApi.POST("/edit", userController.Edit) + userApi.POST("/findById", userController.FindById) + userApi.POST("/saveAuth", userController.SaveAuth) } urlPrefix := "/data/api-v" // wp 娣诲姞 璺緞 鍓嶇紑 @@ -98,6 +100,9 @@ camera.POST("/updateRunEnable", cameraController.UpdateRunEnable) camera.POST("/changeRunType", cameraController.ChangeRunType) camera.GET("/getAllCamerasByServer", cameraController.GetAllCamerasByServer) + + camera.POST("/ptControl", ptController.Controlling) + camera.GET("/statisticRunInfo", cameraController.StatisticRunInfo) } cameraTaskArgsApi := r.Group(urlPrefix + "/cameraTaskArgs") @@ -129,6 +134,7 @@ task := r.Group(urlPrefix + "/task") { task.GET("/findAll", taskController.FindAll) + task.GET("/aggregateTaskList", taskController.AggregateTaskList) task.POST("/addTask", taskController.AddTask) task.POST("/updateTaskStatus", taskController.UpdateTaskStatus) task.GET("/delete", taskController.DeleteTask) @@ -182,6 +188,8 @@ vdbperson.POST("/faceExtract", fileController.FaceExtract) vdbperson.POST("/searchByPhoto", fileController.SearchByPhoto) vdbperson.POST("/updateFace", dbPersonCont.UpdateFace) + + vdbperson.POST("/joinDbTable", dbPersonCont.JoinDbTable) } // 绯荤粺璁剧疆 鎿嶄綔 @@ -198,6 +206,10 @@ vsset.GET("/clockInfo", ssController.GetClockinfo) vsset.POST("/updateClock", ssController.SetSysClock) vsset.GET("/ntpTest", ssController.TestNTPServer) + vsset.GET("/sysinfo", ssController.GetSysInfo) + vsset.GET("/sysThresholds", ssController.GetSysThresholds) + + vsset.GET("/reboot", ssController.RebootOS) } //绠楁硶搴撴搷浣� -- Gitblit v1.8.0