完成xray启动

This commit is contained in:
sprov
2021-05-27 23:04:39 +08:00
parent 56ed8f355c
commit 3cd25ce5ea
42 changed files with 3627 additions and 229 deletions

18
web/controller/base.go Normal file
View File

@@ -0,0 +1,18 @@
package controller
import (
"github.com/gin-gonic/gin"
"x-ui/web/session"
)
type BaseController struct {
}
func (a *BaseController) before(c *gin.Context) {
if !session.IsLogin(c) {
pureJsonMsg(c, false, "登录时效已过,请重新登录")
c.Abort()
} else {
c.Next()
}
}