orbeon / orbeon-forms

Orbeon Forms is an open source web forms solution. It includes an XForms engine, the Form Builder web-based form editor, and the Form Runner runtime.
http://www.orbeon.com/
GNU Lesser General Public License v2.1
512 stars 220 forks source link

Service should be usable from multiple actions with current actions UI #5024

Open ebruchez opened 2 years ago

ebruchez commented 2 years ago

I closed #397 for Orbeon Forms 2019.1 as the 2018 action syntax supports calling a given service from multiple actions. So in a sense the RFE was satisfied.

But we'd still like this in the UI. However, it might take a while until we can have a full-fledged UI (#1298).

So the question is: could we, in the meanwhile, relax the constraint in the current actions UI that service be used only by one action?

We cannot just relax the UI constraint, as the actions edited by the current actions UI are encoded as <xf:action> containers that listen to xforms-submit-done events. If two actions A1 and A2 call the same service S1 (via <xf:send>), then action A1 triggering service S1 will cause the action response for both A1 and A2 to run.

On the other hand, the 2018 action syntax properly encodes continuations for this to work properly.

Bottom line: we need to use the 2018 actions runtime in this case. This means we need to implement #3855.

Once this is done, we can just relax the condition in Form Builder and things should work.

avernet commented 1 year ago

+1 from user