fix(internal): 删除cateage部分,修复repo和service部分

This commit is contained in:
2025-11-17 18:08:42 +08:00
parent 5bb025c1aa
commit 907befeb55
11 changed files with 57 additions and 95 deletions

View File

@@ -18,7 +18,6 @@ func RegisterRouter(r *gin.Engine) {
{
handler.RegisterRouterAuth(v1.Group("/auth"))
handler.RegisterRouterUser(v1.Group("/user"))
handler.RegisterRouterCateage(v1.Group("/cateage"))
v1.GET("/proxy", handler.Proxy)
}

View File

@@ -2,6 +2,7 @@ package handler
import (
"errors"
"github.com/gin-gonic/gin"
"github.com/zhilv666/navsite/internal/model"
"github.com/zhilv666/navsite/internal/service"

View File

@@ -1,20 +0,0 @@
package handler
import (
"github.com/gin-gonic/gin"
"github.com/zhilv666/navsite/internal/service"
"github.com/zhilv666/navsite/pkg/common"
)
func GetAllCateageWithSites(c *gin.Context) {
cateagies, err := service.GetAllCateageWithSites()
if err != nil {
common.Fail(c, err.Error())
return
}
common.Succ(c, cateagies)
}
func RegisterRouterCateage(g *gin.RouterGroup) {
g.GET("/", GetAllCateageWithSites)
}