aboutsummaryrefslogtreecommitdiffstats
path: root/apps/workflowengine/src/components/Rule.vue
diff options
context:
space:
mode:
Diffstat (limited to 'apps/workflowengine/src/components/Rule.vue')
-rw-r--r--apps/workflowengine/src/components/Rule.vue8
1 files changed, 7 insertions, 1 deletions
diff --git a/apps/workflowengine/src/components/Rule.vue b/apps/workflowengine/src/components/Rule.vue
index c59c4568f19..6240b304968 100644
--- a/apps/workflowengine/src/components/Rule.vue
+++ b/apps/workflowengine/src/components/Rule.vue
@@ -19,7 +19,7 @@
type="button"
class="check--add"
value="Add a new filter"
- @click="rule.checks.push({class: null, operator: null, value: ''})">
+ @click="onAddFilter">
</p>
</div>
<div class="flow-icon icon-confirm" />
@@ -152,6 +152,7 @@ export default {
this.dirty = false
}
},
+
async removeCheck(check) {
const index = this.rule.checks.findIndex(item => item === check)
if (index > -1) {
@@ -159,6 +160,11 @@ export default {
}
this.$store.dispatch('updateRule', this.rule)
},
+
+ onAddFilter() {
+ // eslint-disable-next-line vue/no-mutating-props
+ this.rule.checks.push({ class: null, operator: null, value: '' })
+ },
},
}
</script>