mirror of
https://github.com/woodpecker-ci/woodpecker.git
synced 2025-10-21 17:25:52 +00:00
Remove push, tag and deployment webhook filters (#281)
- remove `AllowPush`, `AllowTag`, `AllowDeploy` options. - keep `AllowPullRequest` option and disable it by default --- close #265 close #243
This commit is contained in:
@@ -32,10 +32,7 @@ export default class Settings extends Component {
|
||||
constructor(props, context) {
|
||||
super(props, context);
|
||||
|
||||
this.handlePushChange = this.handlePushChange.bind(this);
|
||||
this.handlePullChange = this.handlePullChange.bind(this);
|
||||
this.handleTagChange = this.handleTagChange.bind(this);
|
||||
this.handleDeployChange = this.handleDeployChange.bind(this);
|
||||
this.handleTrustedChange = this.handleTrustedChange.bind(this);
|
||||
this.handleProtectedChange = this.handleProtectedChange.bind(this);
|
||||
this.handleVisibilityChange = this.handleVisibilityChange.bind(this);
|
||||
@@ -78,37 +75,13 @@ export default class Settings extends Component {
|
||||
<section>
|
||||
<h2>Repository Hooks</h2>
|
||||
<div>
|
||||
<label>
|
||||
<input
|
||||
type="checkbox"
|
||||
checked={repo.allow_push}
|
||||
onChange={this.handlePushChange}
|
||||
/>
|
||||
<span>push</span>
|
||||
</label>
|
||||
<label>
|
||||
<input
|
||||
type="checkbox"
|
||||
checked={repo.allow_pr}
|
||||
onChange={this.handlePullChange}
|
||||
/>
|
||||
<span>pull request</span>
|
||||
</label>
|
||||
<label>
|
||||
<input
|
||||
type="checkbox"
|
||||
checked={repo.allow_tags}
|
||||
onChange={this.handleTagChange}
|
||||
/>
|
||||
<span>tag</span>
|
||||
</label>
|
||||
<label>
|
||||
<input
|
||||
type="checkbox"
|
||||
checked={repo.allow_deploys}
|
||||
onChange={this.handleDeployChange}
|
||||
/>
|
||||
<span>deployment</span>
|
||||
<span>Allow to execute pipelines on Pull-Requests</span>
|
||||
</label>
|
||||
</div>
|
||||
</section>
|
||||
@@ -186,22 +159,10 @@ export default class Settings extends Component {
|
||||
);
|
||||
}
|
||||
|
||||
handlePushChange(e) {
|
||||
this.handleChange("allow_push", e.target.checked);
|
||||
}
|
||||
|
||||
handlePullChange(e) {
|
||||
this.handleChange("allow_pr", e.target.checked);
|
||||
}
|
||||
|
||||
handleTagChange(e) {
|
||||
this.handleChange("allow_tag", e.target.checked);
|
||||
}
|
||||
|
||||
handleDeployChange(e) {
|
||||
this.handleChange("allow_deploy", e.target.checked);
|
||||
}
|
||||
|
||||
handleTrustedChange(e) {
|
||||
this.handleChange("trusted", e.target.checked);
|
||||
}
|
||||
|
Reference in New Issue
Block a user