1 Star 0 Fork 75

qmhl开到荼蘼/go-ldap-admin

forked from opsre/go-ldap-admin 
加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
克隆/下载
group_routes.go 1.25 KB
一键复制 编辑 原始数据 按行查看 历史
package routes
import (
"github.com/eryajf/go-ldap-admin/controller"
"github.com/eryajf/go-ldap-admin/middleware"
jwt "github.com/appleboy/gin-jwt/v2"
"github.com/gin-gonic/gin"
)
func InitGroupRoutes(r *gin.RouterGroup, authMiddleware *jwt.GinJWTMiddleware) gin.IRoutes {
group := r.Group("/group")
// 开启jwt认证中间件
group.Use(authMiddleware.MiddlewareFunc())
// 开启casbin鉴权中间件
group.Use(middleware.CasbinMiddleware())
{
group.GET("/list", controller.Group.List)
group.GET("/tree", controller.Group.GetTree)
group.POST("/add", controller.Group.Add)
group.POST("/update", controller.Group.Update)
group.POST("/delete", controller.Group.Delete)
group.POST("/adduser", controller.Group.AddUser)
group.POST("/removeuser", controller.Group.RemoveUser)
group.GET("/useringroup", controller.Group.UserInGroup)
group.GET("/usernoingroup", controller.Group.UserNoInGroup)
group.POST("/syncDingTalkDepts", controller.Group.SyncDingTalkDepts) // 同步部门
group.POST("/syncWeComDepts", controller.Group.SyncWeComDepts) // 同步部门
group.POST("/syncFeiShuDepts", controller.Group.SyncFeiShuDepts) // 同步部门
group.POST("/syncOpenLdapDepts", controller.Group.SyncOpenLdapDepts) // 同步部门
}
return r
}
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
Go
1
https://gitee.com/zhangqiqmhl/go-ldap-admin.git
git@gitee.com:zhangqiqmhl/go-ldap-admin.git
zhangqiqmhl
go-ldap-admin
go-ldap-admin
main

搜索帮助

371d5123 14472233 46e8bd33 14472233