fix(WFE): properly set inital status

The operationComponent.value is only possibly available with registered
operations that have the value prop. Ones that do not would not have the
value set properly initially. Going to inputValue, which is mapped to the
components model-value, solves this.

Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
pull/52525/head
Arthur Schiwon 5 months ago
parent f9b6b88d5c
commit 09bb0720d4
No known key found for this signature in database
GPG Key ID: 7424F1874854DF23
  1. 4
      apps/workflowengine/src/components/Rule.vue

@ -31,7 +31,6 @@
<Operation :operation="operation" :colored="false">
<component :is="operation.element"
v-if="operation.element"
ref="operationComponent"
:model-value="inputValue"
@update:model-value="updateOperationByEvent" />
<component :is="operation.options"
@ -133,9 +132,8 @@ export default {
},
mounted() {
this.originalRule = JSON.parse(JSON.stringify(this.rule))
if (this.operation?.element) {
this.$refs.operationComponent.value = this.rule.operation
this.inputValue = this.rule.operation
} else if (this.operation?.options) {
// keeping this in an else for apps that try to be backwards compatible and may ship both
// to be removed in 03/2028

Loading…
Cancel
Save