Revert "feat(controller): 完善基础控制器及默认页面渲染"

This reverts commit 37c78d9a4e.
This commit is contained in:
2026-02-21 12:46:38 +08:00
parent 37c78d9a4e
commit 1a3bd1a6b3
4 changed files with 32 additions and 34 deletions

View File

@@ -1,13 +0,0 @@
package admin
import "github.com/gin-gonic/gin"
type BaseController struct {
}
func (con BaseController) Success(c *gin.Context) {
c.String(200, "成功")
}
func (con BaseController) Error(c *gin.Context) {
c.String(200, "失败")
}

View File

@@ -3,11 +3,10 @@ package admin
import "github.com/gin-gonic/gin"
type UserController struct {
BaseController
}
func (con UserController) Index(c *gin.Context) {
con.Success(c)
c.String(200, "管理员用户列表")
}
func (con UserController) Show(c *gin.Context) {