You've already forked VptPassiveAdapter
feat:添加区域入侵上报
This commit is contained in:
@@ -60,6 +60,10 @@ func RegisterVIIDRoutes(r *gin.Engine) {
|
|||||||
sys.POST("/UnRegister", HandleUnRegister)
|
sys.POST("/UnRegister", HandleUnRegister)
|
||||||
sys.GET("/Time", HandleSystemTime)
|
sys.GET("/Time", HandleSystemTime)
|
||||||
}
|
}
|
||||||
|
extend := viid.Group("/Extend")
|
||||||
|
{
|
||||||
|
extend.POST("/SceneCapture", HandleSceneCapture)
|
||||||
|
}
|
||||||
viid.POST("/Faces", HandleUploadFaces)
|
viid.POST("/Faces", HandleUploadFaces)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -78,6 +82,10 @@ func HandleUnRegister(c *gin.Context) {
|
|||||||
proxyHelper(c, "/VIID/System/UnRegister")
|
proxyHelper(c, "/VIID/System/UnRegister")
|
||||||
}
|
}
|
||||||
|
|
||||||
|
func HandleSceneCapture(c *gin.Context) {
|
||||||
|
proxyHelper(c, "/VIID/Extend/SceneCapture")
|
||||||
|
}
|
||||||
|
|
||||||
func proxyHelper(c *gin.Context, path string) {
|
func proxyHelper(c *gin.Context, path string) {
|
||||||
resp, err := ProxyRequest(c.Request.Context(), c.Request.Method, path, c.Request.Body, c.Request.Header)
|
resp, err := ProxyRequest(c.Request.Context(), c.Request.Method, path, c.Request.Body, c.Request.Header)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
|
|||||||
Reference in New Issue
Block a user