1.4.5.2
This commit is contained in:
40
EdgeUser/internal/web/actions/default/anti-ddos/init.go
Normal file
40
EdgeUser/internal/web/actions/default/anti-ddos/init.go
Normal file
@@ -0,0 +1,40 @@
|
||||
// Copyright 2023 Liuxiangchao iwind.liu@gmail.com. All rights reserved. Official site: https://goedge.cn .
|
||||
|
||||
package antiddos
|
||||
|
||||
import (
|
||||
"github.com/TeaOSLab/EdgeUser/internal/web/actions/default/anti-ddos/instances"
|
||||
"github.com/TeaOSLab/EdgeUser/internal/web/actions/default/anti-ddos/packages"
|
||||
"github.com/TeaOSLab/EdgeUser/internal/web/helpers"
|
||||
"github.com/iwind/TeaGo"
|
||||
)
|
||||
|
||||
func init() {
|
||||
TeaGo.BeforeStart(func(server *TeaGo.Server) {
|
||||
server.
|
||||
Helper(helpers.NewUserMustAuth("")).
|
||||
Data("teaMenu", "anti-ddos").
|
||||
Prefix("/anti-ddos").
|
||||
Get("", new(IndexAction)).
|
||||
|
||||
// 实例
|
||||
Prefix("/anti-ddos/instances").
|
||||
Data("teaSubMenu", "instance").
|
||||
Get("", new(instances.IndexAction)).
|
||||
Post("/delete", new(instances.DeleteAction)).
|
||||
GetPost("/updateObjectsPopup", new(instances.UpdateObjectsPopupAction)).
|
||||
Post("/userServers", new(instances.UserServersAction)).
|
||||
GetPost("/renew", new(instances.RenewAction)).
|
||||
GetPost("/renewConfirm", new(instances.RenewConfirmAction)).
|
||||
|
||||
// 产品
|
||||
Prefix("/anti-ddos/packages").
|
||||
Data("teaSubMenu", "package").
|
||||
Get("", new(packages.IndexAction)).
|
||||
Post("/price", new(packages.PriceAction)).
|
||||
GetPost("/confirm", new(packages.ConfirmAction)).
|
||||
|
||||
//
|
||||
EndAll()
|
||||
})
|
||||
}
|
||||
Reference in New Issue
Block a user