Add more webhooks support and refactor webhook templates directory (#3929)

* add more webhook support

* move hooks templates to standalone dir and add more webhooks ui

* fix tests

* update vendor checksum

* add more webhook support

* move hooks templates to standalone dir and add more webhooks ui

* fix tests

* update vendor checksum

* update vendor

Signed-off-by: Bo-Yi Wu <appleboy.tw@gmail.com>

* load attributes when created release

* update comparsion doc
This commit is contained in:
Lunny Xiao 2018-05-16 22:01:55 +08:00 committed by GitHub
parent 188fe6c301
commit 24941a1046
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
33 changed files with 1010 additions and 118 deletions

View file

@ -23,9 +23,9 @@ import (
)
const (
tplHooks base.TplName = "repo/settings/hooks"
tplHookNew base.TplName = "repo/settings/hook_new"
tplOrgHookNew base.TplName = "org/settings/hook_new"
tplHooks base.TplName = "repo/settings/webhook/base"
tplHookNew base.TplName = "repo/settings/webhook/new"
tplOrgHookNew base.TplName = "org/settings/webhook/new"
)
// Webhooks render web hooks list page
@ -118,10 +118,15 @@ func ParseHookEvent(form auth.WebhookForm) *models.HookEvent {
SendEverything: form.SendEverything(),
ChooseEvents: form.ChooseEvents(),
HookEvents: models.HookEvents{
Create: form.Create,
Push: form.Push,
PullRequest: form.PullRequest,
Repository: form.Repository,
Create: form.Create,
Delete: form.Delete,
Fork: form.Fork,
Issues: form.Issues,
IssueComment: form.IssueComment,
Release: form.Release,
Push: form.Push,
PullRequest: form.PullRequest,
Repository: form.Repository,
},
}
}