mirror of
https://gitee.com/dromara/mayfly-go
synced 2025-11-04 00:10:25 +08:00
refactor: 后端包结构重构、去除无用的文件
This commit is contained in:
26
server/internal/common/router/index.go
Normal file
26
server/internal/common/router/index.go
Normal file
@@ -0,0 +1,26 @@
|
||||
package router
|
||||
|
||||
import (
|
||||
"mayfly-go/internal/common/api"
|
||||
devops_app "mayfly-go/internal/devops/application"
|
||||
"mayfly-go/pkg/ctx"
|
||||
|
||||
"github.com/gin-gonic/gin"
|
||||
)
|
||||
|
||||
func InitIndexRouter(router *gin.RouterGroup) {
|
||||
index := router.Group("common/index")
|
||||
i := &api.Index{
|
||||
ProjectApp: devops_app.ProjectApp,
|
||||
MachineApp: devops_app.MachineApp,
|
||||
DbApp: devops_app.DbApp,
|
||||
RedisApp: devops_app.RedisApp,
|
||||
}
|
||||
{
|
||||
// 首页基本信息统计
|
||||
index.GET("count", func(g *gin.Context) {
|
||||
ctx.NewReqCtxWithGin(g).
|
||||
Handle(i.Count)
|
||||
})
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user