mirror of
https://github.com/yangjian102621/geekai.git
synced 2025-11-12 12:13:46 +08:00
refactor: V3 版本重构已基本完成
This commit is contained in:
29
api/go/handler/admin_handler.go
Normal file
29
api/go/handler/admin_handler.go
Normal file
@@ -0,0 +1,29 @@
|
||||
package handler
|
||||
|
||||
import (
|
||||
"chatplus/core"
|
||||
"chatplus/core/types"
|
||||
"github.com/gin-gonic/gin"
|
||||
"gorm.io/gorm"
|
||||
)
|
||||
|
||||
type AdminHandler struct {
|
||||
BaseHandler
|
||||
db *gorm.DB
|
||||
}
|
||||
|
||||
func NewAdminHandler(config *types.AppConfig, app *core.AppServer, db *gorm.DB) *AdminHandler {
|
||||
handler := AdminHandler{db: db}
|
||||
handler.app = app
|
||||
handler.config = config
|
||||
return &handler
|
||||
}
|
||||
|
||||
// Login 登录
|
||||
func (h *AdminHandler) Login(c *gin.Context) {
|
||||
|
||||
}
|
||||
|
||||
// Logout 注销
|
||||
func (h *AdminHandler) Logout(c *gin.Context) {
|
||||
}
|
||||
Reference in New Issue
Block a user