Match Modification Of Pipeline API

This commit is contained in:
Aaron 2018-03-21 15:54:40 +08:00
parent 6c977bd82a
commit 1caa1a6f3d
4 changed files with 11 additions and 7 deletions

View File

@ -52,10 +52,13 @@
{{date-from-now inst.nextStart}}
{{/tooltip-element}}
{{/if}}
{{#if inst.triggerWebhook}}
<p class="mt-5 mb-0">{{t 'pipelinesPage.awaitingWebhook'}}</p>
{{#if inst.triggerWebhookPush}}
<p class="mt-5 mb-0">{{t 'pipelinesPage.awaitingWebhookPush'}}</p>
{{/if}}
{{#unless (or inst.triggerWebhook inst.nextStart)}}
{{#if inst.triggerWebhookPr}}
<p class="mt-5 mb-0">{{t 'pipelinesPage.awaitingWebhookPR'}}</p>
{{/if}}
{{#unless (or inst.triggerWebhookPush inst.triggerWebhookPr inst.nextStart)}}
{{t 'pipelinesPage.triggerManually'}}
{{/unless}}
</td>

View File

@ -76,11 +76,11 @@ export default Component.extend({
}.observes('state.setCustomCron'),
observeOptionsChange: function(){
let trigger={
webhook: this.get('pipeline.triggerWebhook'),
webhook: this.get('pipeline.triggerWebhookPush'),
cron: !!this.get('state.setCustomCron')
}
this.sendAction('triggerOptionsChange', trigger);
}.observes('pipeline.triggerWebhook', 'state.setCustomCron'),
}.observes('pipeline.triggerWebhookPush', 'state.setCustomCron'),
didInsertElement(){
this.initTimeZone();
this.cronObserve();

View File

@ -3,7 +3,7 @@
<label>{{t 'newPipelineStep.stepType.scm.trigger'}}</label>
<div class="pt-10"></div>
<div class="inline-form">
{{input disabled=(or disabled webhookDisabled) type="checkbox" id="webhook" checked=pipeline.triggerWebhook}}
{{input disabled=(or disabled webhookDisabled) type="checkbox" id="webhook" checked=pipeline.triggerWebhookPush}}
<label class="acc-label" for="webhook">
{{t 'newPipelineStage.trigger.webhook'}}
</label>

View File

@ -39,7 +39,8 @@ pipelinesPage:
inactive: Inactive
lastActivity: LastActivity
nextRun: NextRun
awaitingWebhook: Awaiting Webhook
awaitingWebhookPush: Awaiting Push
awaitingWebhookPR: Awaiting PR
triggerManually: Trigger Manually
notDeployed: Pipeline is not enabled, click <a href="{route}">here</a> to enable Pipline
pipelinesSetting: