调整前端样式,调整日志记录路由组,调整对应自动化模板
This commit is contained in:
@@ -11,12 +11,15 @@ type AutoCodeExampleRouter struct {
|
||||
|
||||
func (s *AutoCodeExampleRouter) InitSysAutoCodeExampleRouter(Router *gin.RouterGroup) {
|
||||
autoCodeExampleRouter := Router.Group("autoCodeExample").Use(middleware.OperationRecord())
|
||||
autoCodeExampleRouterWithoutRecord := Router.Group("autoCodeExample")
|
||||
var autoCodeExampleApi = v1.ApiGroupApp.AutoCodeApiGroup.AutoCodeExampleApi
|
||||
{
|
||||
autoCodeExampleRouter.POST("createSysAutoCodeExample", autoCodeExampleApi.CreateAutoCodeExample) // 新建AutoCodeExample
|
||||
autoCodeExampleRouter.DELETE("deleteSysAutoCodeExample", autoCodeExampleApi.DeleteAutoCodeExample) // 删除AutoCodeExample
|
||||
autoCodeExampleRouter.PUT("updateSysAutoCodeExample", autoCodeExampleApi.UpdateAutoCodeExample) // 更新AutoCodeExample
|
||||
autoCodeExampleRouter.GET("findSysAutoCodeExample", autoCodeExampleApi.FindAutoCodeExample) // 根据ID获取AutoCodeExample
|
||||
autoCodeExampleRouter.GET("getSysAutoCodeExampleList", autoCodeExampleApi.GetAutoCodeExampleList) // 获取AutoCodeExample列表
|
||||
}
|
||||
{
|
||||
autoCodeExampleRouterWithoutRecord.GET("findSysAutoCodeExample", autoCodeExampleApi.FindAutoCodeExample) // 根据ID获取AutoCodeExample
|
||||
autoCodeExampleRouterWithoutRecord.GET("getSysAutoCodeExampleList", autoCodeExampleApi.GetAutoCodeExampleList) // 获取AutoCodeExample列表
|
||||
}
|
||||
}
|
||||
|
@@ -11,12 +11,15 @@ type CustomerRouter struct {
|
||||
|
||||
func (e *CustomerRouter) InitCustomerRouter(Router *gin.RouterGroup) {
|
||||
customerRouter := Router.Group("customer").Use(middleware.OperationRecord())
|
||||
customerRouterWithoutRecord := Router.Group("customer")
|
||||
var exaCustomerApi = v1.ApiGroupApp.ExampleApiGroup.CustomerApi
|
||||
{
|
||||
customerRouter.POST("customer", exaCustomerApi.CreateExaCustomer) // 创建客户
|
||||
customerRouter.PUT("customer", exaCustomerApi.UpdateExaCustomer) // 更新客户
|
||||
customerRouter.DELETE("customer", exaCustomerApi.DeleteExaCustomer) // 删除客户
|
||||
customerRouter.GET("customer", exaCustomerApi.GetExaCustomer) // 获取单一客户信息
|
||||
customerRouter.GET("customerList", exaCustomerApi.GetExaCustomerList) // 获取客户列表
|
||||
customerRouter.POST("customer", exaCustomerApi.CreateExaCustomer) // 创建客户
|
||||
customerRouter.PUT("customer", exaCustomerApi.UpdateExaCustomer) // 更新客户
|
||||
customerRouter.DELETE("customer", exaCustomerApi.DeleteExaCustomer) // 删除客户
|
||||
}
|
||||
{
|
||||
customerRouterWithoutRecord.GET("customer", exaCustomerApi.GetExaCustomer) // 获取单一客户信息
|
||||
customerRouterWithoutRecord.GET("customerList", exaCustomerApi.GetExaCustomerList) // 获取客户列表
|
||||
}
|
||||
}
|
||||
|
@@ -12,9 +12,9 @@ func (e *ExcelRouter) InitExcelRouter(Router *gin.RouterGroup) {
|
||||
excelRouter := Router.Group("excel")
|
||||
var exaExcelApi = v1.ApiGroupApp.ExampleApiGroup.ExcelApi
|
||||
{
|
||||
excelRouter.POST("/importExcel", exaExcelApi.ImportExcel) // 导入Excel
|
||||
excelRouter.GET("/loadExcel", exaExcelApi.LoadExcel) // 加载Excel数据
|
||||
excelRouter.POST("/exportExcel", exaExcelApi.ExportExcel) // 导出Excel
|
||||
excelRouter.GET("/downloadTemplate", exaExcelApi.DownloadTemplate) // 下载模板文件
|
||||
excelRouter.POST("importExcel", exaExcelApi.ImportExcel) // 导入Excel
|
||||
excelRouter.GET("loadExcel", exaExcelApi.LoadExcel) // 加载Excel数据
|
||||
excelRouter.POST("exportExcel", exaExcelApi.ExportExcel) // 导出Excel
|
||||
excelRouter.GET("downloadTemplate", exaExcelApi.DownloadTemplate) // 下载模板文件
|
||||
}
|
||||
}
|
||||
|
@@ -12,12 +12,12 @@ func (e *FileUploadAndDownloadRouter) InitFileUploadAndDownloadRouter(Router *gi
|
||||
fileUploadAndDownloadRouter := Router.Group("fileUploadAndDownload")
|
||||
var exaFileUploadAndDownloadApi = v1.ApiGroupApp.ExampleApiGroup.FileUploadAndDownloadApi
|
||||
{
|
||||
fileUploadAndDownloadRouter.POST("/upload", exaFileUploadAndDownloadApi.UploadFile) // 上传文件
|
||||
fileUploadAndDownloadRouter.POST("/getFileList", exaFileUploadAndDownloadApi.GetFileList) // 获取上传文件列表
|
||||
fileUploadAndDownloadRouter.POST("/deleteFile", exaFileUploadAndDownloadApi.DeleteFile) // 删除指定文件
|
||||
fileUploadAndDownloadRouter.POST("/breakpointContinue", exaFileUploadAndDownloadApi.BreakpointContinue) // 断点续传
|
||||
fileUploadAndDownloadRouter.GET("/findFile", exaFileUploadAndDownloadApi.FindFile) // 查询当前文件成功的切片
|
||||
fileUploadAndDownloadRouter.POST("/breakpointContinueFinish", exaFileUploadAndDownloadApi.BreakpointContinueFinish) // 查询当前文件成功的切片
|
||||
fileUploadAndDownloadRouter.POST("/removeChunk", exaFileUploadAndDownloadApi.RemoveChunk) // 查询当前文件成功的切片
|
||||
fileUploadAndDownloadRouter.POST("upload", exaFileUploadAndDownloadApi.UploadFile) // 上传文件
|
||||
fileUploadAndDownloadRouter.POST("getFileList", exaFileUploadAndDownloadApi.GetFileList) // 获取上传文件列表
|
||||
fileUploadAndDownloadRouter.POST("deleteFile", exaFileUploadAndDownloadApi.DeleteFile) // 删除指定文件
|
||||
fileUploadAndDownloadRouter.POST("breakpointContinue", exaFileUploadAndDownloadApi.BreakpointContinue) // 断点续传
|
||||
fileUploadAndDownloadRouter.GET("findFile", exaFileUploadAndDownloadApi.FindFile) // 查询当前文件成功的切片
|
||||
fileUploadAndDownloadRouter.POST("breakpointContinueFinish", exaFileUploadAndDownloadApi.BreakpointContinueFinish) // 查询当前文件成功的切片
|
||||
fileUploadAndDownloadRouter.POST("removeChunk", exaFileUploadAndDownloadApi.RemoveChunk) // 查询当前文件成功的切片
|
||||
}
|
||||
}
|
||||
|
@@ -11,14 +11,17 @@ type ApiRouter struct {
|
||||
|
||||
func (s *ApiRouter) InitApiRouter(Router *gin.RouterGroup) {
|
||||
apiRouter := Router.Group("api").Use(middleware.OperationRecord())
|
||||
apiRouterWithoutRecord := Router.Group("api")
|
||||
var apiRouterApi = v1.ApiGroupApp.SystemApiGroup.SystemApiApi
|
||||
{
|
||||
apiRouter.POST("createApi", apiRouterApi.CreateApi) // 创建Api
|
||||
apiRouter.POST("deleteApi", apiRouterApi.DeleteApi) // 删除Api
|
||||
apiRouter.POST("getApiList", apiRouterApi.GetApiList) // 获取Api列表
|
||||
apiRouter.POST("getApiById", apiRouterApi.GetApiById) // 获取单条Api消息
|
||||
apiRouter.POST("updateApi", apiRouterApi.UpdateApi) // 更新api
|
||||
apiRouter.POST("getAllApis", apiRouterApi.GetAllApis) // 获取所有api
|
||||
apiRouter.DELETE("deleteApisByIds", apiRouterApi.DeleteApisByIds) // 删除选中api
|
||||
}
|
||||
{
|
||||
apiRouterWithoutRecord.POST("getAllApis", apiRouterApi.GetAllApis) // 获取所有api
|
||||
apiRouterWithoutRecord.POST("getApiList", apiRouterApi.GetApiList) // 获取Api列表
|
||||
}
|
||||
}
|
||||
|
@@ -11,13 +11,16 @@ type AuthorityRouter struct {
|
||||
|
||||
func (s *AuthorityRouter) InitAuthorityRouter(Router *gin.RouterGroup) {
|
||||
authorityRouter := Router.Group("authority").Use(middleware.OperationRecord())
|
||||
authorityRouterWithoutRecord := Router.Group("authority")
|
||||
var authorityApi = v1.ApiGroupApp.SystemApiGroup.AuthorityApi
|
||||
{
|
||||
authorityRouter.POST("createAuthority", authorityApi.CreateAuthority) // 创建角色
|
||||
authorityRouter.POST("deleteAuthority", authorityApi.DeleteAuthority) // 删除角色
|
||||
authorityRouter.PUT("updateAuthority", authorityApi.UpdateAuthority) // 更新角色
|
||||
authorityRouter.POST("copyAuthority", authorityApi.CopyAuthority) // 更新角色
|
||||
authorityRouter.POST("getAuthorityList", authorityApi.GetAuthorityList) // 获取角色列表
|
||||
authorityRouter.POST("copyAuthority", authorityApi.CopyAuthority) // 拷贝角色
|
||||
authorityRouter.POST("setDataAuthority", authorityApi.SetDataAuthority) // 设置角色资源权限
|
||||
}
|
||||
{
|
||||
authorityRouterWithoutRecord.POST("getAuthorityList", authorityApi.GetAuthorityList) // 获取角色列表
|
||||
}
|
||||
}
|
||||
|
@@ -11,9 +11,12 @@ type CasbinRouter struct {
|
||||
|
||||
func (s *CasbinRouter) InitCasbinRouter(Router *gin.RouterGroup) {
|
||||
casbinRouter := Router.Group("casbin").Use(middleware.OperationRecord())
|
||||
casbinRouterWithoutRecord := Router.Group("casbin")
|
||||
var casbinApi = v1.ApiGroupApp.SystemApiGroup.CasbinApi
|
||||
{
|
||||
casbinRouter.POST("updateCasbin", casbinApi.UpdateCasbin)
|
||||
casbinRouter.POST("getPolicyPathByAuthorityId", casbinApi.GetPolicyPathByAuthorityId)
|
||||
}
|
||||
{
|
||||
casbinRouterWithoutRecord.POST("getPolicyPathByAuthorityId", casbinApi.GetPolicyPathByAuthorityId)
|
||||
}
|
||||
}
|
||||
|
@@ -11,12 +11,15 @@ type DictionaryRouter struct {
|
||||
|
||||
func (s *DictionaryRouter) InitSysDictionaryRouter(Router *gin.RouterGroup) {
|
||||
sysDictionaryRouter := Router.Group("sysDictionary").Use(middleware.OperationRecord())
|
||||
sysDictionaryRouterWithoutRecord := Router.Group("sysDictionary")
|
||||
var sysDictionaryApi = v1.ApiGroupApp.SystemApiGroup.DictionaryApi
|
||||
{
|
||||
sysDictionaryRouter.POST("createSysDictionary", sysDictionaryApi.CreateSysDictionary) // 新建SysDictionary
|
||||
sysDictionaryRouter.DELETE("deleteSysDictionary", sysDictionaryApi.DeleteSysDictionary) // 删除SysDictionary
|
||||
sysDictionaryRouter.PUT("updateSysDictionary", sysDictionaryApi.UpdateSysDictionary) // 更新SysDictionary
|
||||
sysDictionaryRouter.GET("findSysDictionary", sysDictionaryApi.FindSysDictionary) // 根据ID获取SysDictionary
|
||||
sysDictionaryRouter.GET("getSysDictionaryList", sysDictionaryApi.GetSysDictionaryList) // 获取SysDictionary列表
|
||||
}
|
||||
{
|
||||
sysDictionaryRouterWithoutRecord.GET("findSysDictionary", sysDictionaryApi.FindSysDictionary) // 根据ID获取SysDictionary
|
||||
sysDictionaryRouterWithoutRecord.GET("getSysDictionaryList", sysDictionaryApi.GetSysDictionaryList) // 获取SysDictionary列表
|
||||
}
|
||||
}
|
||||
|
@@ -11,12 +11,15 @@ type DictionaryDetailRouter struct {
|
||||
|
||||
func (s *DictionaryDetailRouter) InitSysDictionaryDetailRouter(Router *gin.RouterGroup) {
|
||||
dictionaryDetailRouter := Router.Group("sysDictionaryDetail").Use(middleware.OperationRecord())
|
||||
dictionaryDetailRouterWithoutRecord := Router.Group("sysDictionaryDetail")
|
||||
var sysDictionaryDetailApi = v1.ApiGroupApp.SystemApiGroup.DictionaryDetailApi
|
||||
{
|
||||
dictionaryDetailRouter.POST("createSysDictionaryDetail", sysDictionaryDetailApi.CreateSysDictionaryDetail) // 新建SysDictionaryDetail
|
||||
dictionaryDetailRouter.DELETE("deleteSysDictionaryDetail", sysDictionaryDetailApi.DeleteSysDictionaryDetail) // 删除SysDictionaryDetail
|
||||
dictionaryDetailRouter.PUT("updateSysDictionaryDetail", sysDictionaryDetailApi.UpdateSysDictionaryDetail) // 更新SysDictionaryDetail
|
||||
dictionaryDetailRouter.GET("findSysDictionaryDetail", sysDictionaryDetailApi.FindSysDictionaryDetail) // 根据ID获取SysDictionaryDetail
|
||||
dictionaryDetailRouter.GET("getSysDictionaryDetailList", sysDictionaryDetailApi.GetSysDictionaryDetailList) // 获取SysDictionaryDetail列表
|
||||
}
|
||||
{
|
||||
dictionaryDetailRouterWithoutRecord.GET("findSysDictionaryDetail", sysDictionaryDetailApi.FindSysDictionaryDetail) // 根据ID获取SysDictionaryDetail
|
||||
dictionaryDetailRouterWithoutRecord.GET("getSysDictionaryDetailList", sysDictionaryDetailApi.GetSysDictionaryDetailList) // 获取SysDictionaryDetail列表
|
||||
}
|
||||
}
|
||||
|
@@ -2,7 +2,6 @@ package system
|
||||
|
||||
import (
|
||||
v1 "github.com/flipped-aurora/gin-vue-admin/server/api/v1"
|
||||
"github.com/flipped-aurora/gin-vue-admin/server/middleware"
|
||||
"github.com/gin-gonic/gin"
|
||||
)
|
||||
|
||||
@@ -10,7 +9,7 @@ type JwtRouter struct {
|
||||
}
|
||||
|
||||
func (s *JwtRouter) InitJwtRouter(Router *gin.RouterGroup) {
|
||||
jwtRouter := Router.Group("jwt").Use(middleware.OperationRecord())
|
||||
jwtRouter := Router.Group("jwt")
|
||||
var jwtApi = v1.ApiGroupApp.SystemApiGroup.JwtApi
|
||||
{
|
||||
jwtRouter.POST("jsonInBlacklist", jwtApi.JsonInBlacklist) // jwt加入黑名单
|
||||
|
@@ -11,17 +11,20 @@ type MenuRouter struct {
|
||||
|
||||
func (s *MenuRouter) InitMenuRouter(Router *gin.RouterGroup) (R gin.IRoutes) {
|
||||
menuRouter := Router.Group("menu").Use(middleware.OperationRecord())
|
||||
menuRouterWithoutRecord := Router.Group("menu")
|
||||
var authorityMenuApi = v1.ApiGroupApp.SystemApiGroup.AuthorityMenuApi
|
||||
{
|
||||
menuRouter.POST("getMenu", authorityMenuApi.GetMenu) // 获取菜单树
|
||||
menuRouter.POST("getMenuList", authorityMenuApi.GetMenuList) // 分页获取基础menu列表
|
||||
menuRouter.POST("addBaseMenu", authorityMenuApi.AddBaseMenu) // 新增菜单
|
||||
menuRouter.POST("getBaseMenuTree", authorityMenuApi.GetBaseMenuTree) // 获取用户动态路由
|
||||
menuRouter.POST("addMenuAuthority", authorityMenuApi.AddMenuAuthority) // 增加menu和角色关联关系
|
||||
menuRouter.POST("getMenuAuthority", authorityMenuApi.GetMenuAuthority) // 获取指定角色menu
|
||||
menuRouter.POST("deleteBaseMenu", authorityMenuApi.DeleteBaseMenu) // 删除菜单
|
||||
menuRouter.POST("updateBaseMenu", authorityMenuApi.UpdateBaseMenu) // 更新菜单
|
||||
menuRouter.POST("getBaseMenuById", authorityMenuApi.GetBaseMenuById) // 根据id获取菜单
|
||||
}
|
||||
{
|
||||
menuRouterWithoutRecord.POST("getMenu", authorityMenuApi.GetMenu) // 获取菜单树
|
||||
menuRouterWithoutRecord.POST("getMenuList", authorityMenuApi.GetMenuList) // 分页获取基础menu列表
|
||||
menuRouterWithoutRecord.POST("getBaseMenuTree", authorityMenuApi.GetBaseMenuTree) // 获取用户动态路由
|
||||
menuRouterWithoutRecord.POST("getMenuAuthority", authorityMenuApi.GetMenuAuthority) // 获取指定角色menu
|
||||
menuRouterWithoutRecord.POST("getBaseMenuById", authorityMenuApi.GetBaseMenuById) // 根据id获取菜单
|
||||
}
|
||||
return menuRouter
|
||||
}
|
||||
|
@@ -11,15 +11,18 @@ type UserRouter struct {
|
||||
|
||||
func (s *UserRouter) InitUserRouter(Router *gin.RouterGroup) {
|
||||
userRouter := Router.Group("user").Use(middleware.OperationRecord())
|
||||
userRouterWithoutRecord := Router.Group("user")
|
||||
var baseApi = v1.ApiGroupApp.SystemApiGroup.BaseApi
|
||||
{
|
||||
userRouter.POST("register", baseApi.Register) // 用户注册账号
|
||||
userRouter.POST("changePassword", baseApi.ChangePassword) // 用户修改密码
|
||||
userRouter.POST("getUserList", baseApi.GetUserList) // 分页获取用户列表
|
||||
userRouter.POST("setUserAuthority", baseApi.SetUserAuthority) // 设置用户权限
|
||||
userRouter.DELETE("deleteUser", baseApi.DeleteUser) // 删除用户
|
||||
userRouter.PUT("setUserInfo", baseApi.SetUserInfo) // 设置用户信息
|
||||
userRouter.POST("setUserAuthorities", baseApi.SetUserAuthorities) // 设置用户权限组
|
||||
userRouter.GET("getUserInfo", baseApi.GetUserInfo) // 获取自身信息
|
||||
}
|
||||
{
|
||||
userRouterWithoutRecord.POST("getUserList", baseApi.GetUserList) // 分页获取用户列表
|
||||
userRouterWithoutRecord.GET("getUserInfo", baseApi.GetUserInfo) // 获取自身信息
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user