Add Gollum event option to web hook configuration page

This commit is contained in:
Naoki Takezoe
2017-06-02 18:46:15 +09:00
parent 2ec8189d47
commit a7a53610e6
2 changed files with 3 additions and 1 deletions

View File

@@ -42,7 +42,7 @@ trait WebHookService {
def getWebHooksByEvent(owner: String, repository: String, event: WebHook.Event)(implicit s: Session): List[WebHook] =
WebHooks.filter(_.byRepository(owner, repository))
.join(WebHookEvents).on { (wh, whe) => whe.byWebHook(wh) }
.filter { case (wh, whe) => whe.event === event.bind}
.filter { case (wh, whe) => whe.event === event.bind }
.map{ case (wh, whe) => wh }
.list.distinct

View File

@@ -55,7 +55,9 @@
<label class="checkbox"><input type="checkbox" @check("events",Deployment) />Deployment <small class="help-block">Repository deployed. </small> </label>
<label class="checkbox"><input type="checkbox" @check("events",DeploymentStatus) />Deployment status <small class="help-block">Deployment status updated from the API. </small> </label>
<label class="checkbox"><input type="checkbox" @check("events",Fork) />Fork <small class="help-block">Repository forked. </small> </label>
-->
<label class="checkbox"><input type="checkbox" @check("events",Gollum) />Gollum <small class="help-block">Wiki page updated. </small> </label>
<!--
<label class="checkbox"><input type="checkbox" @check("events",Member) />Member <small class="help-block">Collaborator added to a non-organization repository. </small> </label>
<label class="checkbox"><input type="checkbox" @check("events",PageBuild) />Page build <small class="help-block">Pages site built. </small> </label>
<label class="checkbox"><input type="checkbox" @check("events",Public) />Public <small class="help-block">Repository changes from private to public. </small> </label>