Closed rasmusfaber closed 1 month ago
@rasmusfaber thanks for the PR can you looked into org.flowable.engine.impl.Condition
, org.flowable.engine.impl.scripting.ScriptCondition
and org.flowable.engine.impl.el.UelExpressionCondition
? I think that what you are looking for fits more into using ScriptCondition
instead of the UelExpressionCondition
.
With that approach we won't need the ScriptEngineExpression
and we won't need to get the process engine configuration in the way we are doing it now.
@rasmusfaber thanks for the PR can you looked into
org.flowable.engine.impl.Condition
,org.flowable.engine.impl.scripting.ScriptCondition
andorg.flowable.engine.impl.el.UelExpressionCondition
?
@filiphr Oh, yes. That was much cleaner. Thank you. I have updated the PR.
Thanks @rasmusfaber.
I see now that you did some changes in the ScriptCondition
. I would instead prefer to have a new method in the ConditionUtil
and create a Condition
from there. If the language is null
or empty then we create the UelExpressionCondition
otherwise we create a ScriptCondition
. The ScriptCondition
should not behave like a UelExpressionCondition
if there is no language
I would instead prefer to have a new method in the
ConditionUtil
and create aCondition
from there.
@filiphr Sure. How is this? I also renamed the sequenceFlowId
parameter to elementId
, since it could now also be the id of an event.
Looks good, thanks @rasmusfaber
This fixes #3884 by adding support for other expression languages as specified by the
language
tag in theFormalExpression
, i.e.Check List: