package router import ( "fmt" "github.com/gin-gonic/gin" "gitlab.wodcloud.com/smart-operation/so-operation-api/src/common/conf" "gitlab.wodcloud.com/smart-operation/so-operation-api/src/controller" "gitlab.wodcloud.com/smart-operation/so-operation-api/src/router/middleware/header" ) // InitSystemLoginRouter 初始化登录相关路由 func initDictRoute(e *gin.Engine) { base := e.Group(fmt.Sprintf("%s/dict", conf.Options.Prefix), header.SetContext) //系统字典 componentDictController := new(controller.ComponentDict) base.POST("", componentDictController.Add) //新增字典 base.PUT("", componentDictController.Update) //修改字典 base.DELETE("", componentDictController.Del) //删除字典 base.GET("", componentDictController.List) //字典列表 base.GET("/dict_tree", componentDictController.DictTree) //字典列表-树结构 base.GET("/class_list", componentDictController.ClassList) //字典分类列表 base.GET("/manage_list", componentDictController.ManageList) //字典管理列表 }