33 lines
637 B
Go
33 lines
637 B
Go
package apps
|
|
|
|
import (
|
|
"github.com/TeaOSLab/EdgeAdmin/internal/web/actions/actionutils"
|
|
"github.com/iwind/TeaGo/actions"
|
|
)
|
|
|
|
type DomainsCreatePopupAction struct {
|
|
actionutils.ParentAction
|
|
}
|
|
|
|
func (this *DomainsCreatePopupAction) Init() {
|
|
this.Nav("", "", "")
|
|
}
|
|
|
|
func (this *DomainsCreatePopupAction) RunGet(params struct {
|
|
AppId int64
|
|
}) {
|
|
this.Data["app"] = pickApp(params.AppId)
|
|
this.Show()
|
|
}
|
|
|
|
func (this *DomainsCreatePopupAction) RunPost(params struct {
|
|
AppId int64
|
|
Domain string
|
|
|
|
Must *actions.Must
|
|
CSRF *actionutils.CSRF
|
|
}) {
|
|
params.Must.Field("domain", params.Domain).Require("please input domain")
|
|
this.Success()
|
|
}
|