2020-09-13 20:37:07 +08:00
|
|
|
package db
|
|
|
|
|
|
|
|
|
|
import (
|
2020-10-10 20:28:36 +08:00
|
|
|
"github.com/TeaOSLab/EdgeAdmin/internal/web/actions/default/settings/settingutils"
|
2020-09-13 20:37:07 +08:00
|
|
|
"github.com/TeaOSLab/EdgeAdmin/internal/web/helpers"
|
|
|
|
|
"github.com/iwind/TeaGo"
|
|
|
|
|
)
|
|
|
|
|
|
|
|
|
|
func init() {
|
|
|
|
|
TeaGo.BeforeStart(func(server *TeaGo.Server) {
|
|
|
|
|
server.
|
|
|
|
|
Helper(new(helpers.UserMustAuth)).
|
|
|
|
|
Helper(new(Helper)).
|
2020-10-10 20:28:36 +08:00
|
|
|
Helper(settingutils.NewHelper("db")).
|
2020-09-13 20:37:07 +08:00
|
|
|
Prefix("/db").
|
|
|
|
|
Get("", new(IndexAction)).
|
2020-10-08 17:54:57 +08:00
|
|
|
GetPost("/createPopup", new(CreatePopupAction)).
|
|
|
|
|
GetPost("/updatePopup", new(UpdatePopupAction)).
|
|
|
|
|
Post("/delete", new(DeleteAction)).
|
2020-09-13 20:37:07 +08:00
|
|
|
|
|
|
|
|
EndAll()
|
|
|
|
|
})
|
|
|
|
|
}
|