add perm control busi-group adding
This commit is contained in:
parent
32fea64f3e
commit
cab6089a37
|
@ -134,7 +134,7 @@ func configRoute(r *gin.Engine, version string) {
|
||||||
pages.PUT("/user/:id/password", jwtAuth(), admin(), userPasswordPut)
|
pages.PUT("/user/:id/password", jwtAuth(), admin(), userPasswordPut)
|
||||||
pages.DELETE("/user/:id", jwtAuth(), admin(), userDel)
|
pages.DELETE("/user/:id", jwtAuth(), admin(), userDel)
|
||||||
|
|
||||||
pages.GET("/user-groups", jwtAuth(), user(), userGroupGets)
|
pages.GET("/user-groups", jwtAuth(), user(), perm("/user-groups"), userGroupGets)
|
||||||
pages.POST("/user-groups", jwtAuth(), user(), userGroupAdd)
|
pages.POST("/user-groups", jwtAuth(), user(), userGroupAdd)
|
||||||
pages.GET("/user-group/:id", jwtAuth(), user(), userGroupGet)
|
pages.GET("/user-group/:id", jwtAuth(), user(), userGroupGet)
|
||||||
pages.PUT("/user-group/:id", jwtAuth(), user(), userGroupWrite(), userGroupPut)
|
pages.PUT("/user-group/:id", jwtAuth(), user(), userGroupWrite(), userGroupPut)
|
||||||
|
@ -143,7 +143,7 @@ func configRoute(r *gin.Engine, version string) {
|
||||||
pages.DELETE("/user-group/:id/members", jwtAuth(), user(), userGroupWrite(), userGroupMemberDel)
|
pages.DELETE("/user-group/:id/members", jwtAuth(), user(), userGroupWrite(), userGroupMemberDel)
|
||||||
pages.GET("/user-group/:id/perm/:perm", jwtAuth(), user(), checkBusiGroupPerm)
|
pages.GET("/user-group/:id/perm/:perm", jwtAuth(), user(), checkBusiGroupPerm)
|
||||||
|
|
||||||
pages.POST("/busi-groups", jwtAuth(), user(), busiGroupAdd)
|
pages.POST("/busi-groups", jwtAuth(), user(), perm("/busi-groups"), busiGroupAdd)
|
||||||
pages.GET("/busi-groups", jwtAuth(), user(), busiGroupGets)
|
pages.GET("/busi-groups", jwtAuth(), user(), busiGroupGets)
|
||||||
pages.GET("/busi-groups/alertings", jwtAuth(), busiGroupAlertingsGets)
|
pages.GET("/busi-groups/alertings", jwtAuth(), busiGroupAlertingsGets)
|
||||||
pages.GET("/busi-group/:id", jwtAuth(), user(), bgro(), busiGroupGet)
|
pages.GET("/busi-group/:id", jwtAuth(), user(), bgro(), busiGroupGet)
|
||||||
|
|
Loading…
Reference in New Issue