Nicolas Malin created OFBIZ-13281:
-------------------------------------
Summary: Add in, not-in operator for seca condition
Key: OFBIZ-13281
URL: https://issues.apache.org/jira/browse/OFBIZ-13281
Project: OFBiz
Issue Type: Improvement
Components: framework/service
Reporter: Nicolas Malin
When you create a seca to follow a status evolution, and you need to run a
service on two status value, currently you define twice the seca :
{code:xml}
<eca service="setInvoiceStatus" event="return">
<condition field-name="statusId" operator="equals"
value="INVOICE_READY"/>
<action service="runSomething" mode="async" run-as-user="system"/>
</eca>
<eca service="setInvoiceStatus" event="return">
<condition field-name="statusId" operator="equals"
value="INVOICE_RECEIVED"/>
<action service="runSomething" mode="async" run-as-user="system"/>
</eca>
{code}
A simple improve will optimize this with an in (or not_in) operator already
present on the framework.
{code:xml}
<eca service="setInvoiceStatus" event="return">
<condition field-name="statusId" operator="in"
value="INVOICE_READY,INVOICE_RECEIVED"/>
<action service="runSomething" mode="async" run-as-user="system"/>
</eca>
{code}
--
This message was sent by Atlassian Jira
(v8.20.10#820010)