33 lines
1.2 KiB
Go
33 lines
1.2 KiB
Go
package apps
|
|
|
|
import (
|
|
"github.com/TeaOSLab/EdgeAdmin/internal/configloaders"
|
|
"github.com/TeaOSLab/EdgeAdmin/internal/web/helpers"
|
|
"github.com/iwind/TeaGo"
|
|
)
|
|
|
|
func init() {
|
|
TeaGo.BeforeStart(func(server *TeaGo.Server) {
|
|
server.
|
|
Helper(helpers.NewUserMustAuth(configloaders.AdminModuleCodeHttpDNS)).
|
|
Data("teaMenu", "httpdns").
|
|
Data("teaSubMenu", "app").
|
|
Prefix("/httpdns/apps").
|
|
Get("", new(IndexAction)).
|
|
Get("/app", new(AppAction)).
|
|
GetPost("/app/settings", new(AppSettingsAction)).
|
|
Post("/app/settings/toggleSignEnabled", new(AppSettingsToggleSignEnabledAction)).
|
|
Post("/app/settings/resetSignSecret", new(AppSettingsResetSignSecretAction)).
|
|
Post("/app/settings/resetAESSecret", new(AppSettingsResetAESSecretAction)).
|
|
Get("/domains", new(DomainsAction)).
|
|
Get("/customRecords", new(CustomRecordsAction)).
|
|
GetPost("/createPopup", new(CreatePopupAction)).
|
|
GetPost("/domains/createPopup", new(DomainsCreatePopupAction)).
|
|
Post("/domains/delete", new(DomainsDeleteAction)).
|
|
GetPost("/customRecords/createPopup", new(CustomRecordsCreatePopupAction)).
|
|
Post("/customRecords/delete", new(CustomRecordsDeleteAction)).
|
|
Post("/customRecords/toggle", new(CustomRecordsToggleAction)).
|
|
EndAll()
|
|
})
|
|
}
|