mirror of
https://github.com/TeaOSLab/EdgeAdmin.git
synced 2025-12-08 14:10:30 +08:00
阶段性提交
This commit is contained in:
24
internal/web/actions/default/log/helper.go
Normal file
24
internal/web/actions/default/log/helper.go
Normal file
@@ -0,0 +1,24 @@
|
||||
package log
|
||||
|
||||
import (
|
||||
"github.com/TeaOSLab/EdgeAdmin/internal/web/actions/actionutils"
|
||||
"github.com/iwind/TeaGo/actions"
|
||||
"net/http"
|
||||
)
|
||||
|
||||
type Helper struct {
|
||||
}
|
||||
|
||||
func (this *Helper) BeforeAction(action *actions.ActionObject) {
|
||||
if action.Request.Method != http.MethodGet {
|
||||
return
|
||||
}
|
||||
|
||||
action.Data["teaMenu"] = "log"
|
||||
|
||||
selectedTabbar, _ := action.Data["mainTab"]
|
||||
|
||||
tabbar := actionutils.NewTabbar()
|
||||
tabbar.Add("日志节点", "", "/log", "", selectedTabbar == "log")
|
||||
actionutils.SetTabbar(action, tabbar)
|
||||
}
|
||||
Reference in New Issue
Block a user