Event mode deferred: Adding class xxforms-events-mode-default doesn't trigger ajax request on value change

classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|

Event mode deferred: Adding class xxforms-events-mode-default doesn't trigger ajax request on value change

mabu
Hi Guys,

I want to reduce the number of ajax requests send to the server. Therefore I set the property <property as="xs:string" name="oxf.xforms.client.events.mode" value="deferred" />. This works fine!
But if I add the class xxforms-events-mode-default to a control where a value change affects the rest of the form nothing happens. No ajax request is send to the server on value change.
What am I doing wrong?

Simple Example: Depending on the value of the dropdown the second section should be displayed
...
<xf:bind id="fr-form-binds" ref="instance('fr-form-instance')">
    <xf:bind id="section-1-bind" name="section-1" ref="section-1">
        <xf:bind id="dropdown-bind" ref="dropdown" name="dropdown"/>
    </xf:bind>
    <xf:bind id="section-2-bind" ref="section-2" name="section-2" relevant="boolean(normalize-space($dropdown) = '1')"/>
</xf:bind>
...
<fr:section id="section-1-control" bind="section-1-bind">
    ...
    <fr:dropdown-select1 xmlns:xxbl="http://orbeon.org/oxf/xml/xbl" id="dropdown-control" bind="dropdown-bind" class="xxforms-events-mode-default">
         ...
    </fr:dropdown-select1>
    ...          
</fr:section>
<fr:section id="section-2-control" bind="section-2-bind">
    ...
</fr:section>
...

 
Reply | Threaded
Open this post in threaded view
|

Re: Event mode deferred: Adding class xxforms-events-mode-default doesn't trigger ajax request on value change

Erik Bruchez
Administrator
Sorry but at this time we don't recommend using this and we consider this feature deprecated:

    http://wiki.orbeon.com/forms/doc/developer-guide/admin/performance-tuning#TOC-Filtering-out-specific-events

-Erik
Reply | Threaded
Open this post in threaded view
|

Re: Event mode deferred: Adding class xxforms-events-mode-default doesn't trigger ajax request on value change

mabu
Hi Eric,

I thought only using the filter property is deprecated. So I tried it with setting the event mode deferred.
In general, I think this would be a very nice feature. I hope you can think of it again for a future release!

Martin
Reply | Threaded
Open this post in threaded view
|

unsubscribe@googlegroups.com.

candy86
In reply to this post by Erik Bruchez
 

--
You received this message because you are subscribed to the Google Groups "Orbeon Forms" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
Reply | Threaded
Open this post in threaded view
|

Re: Event mode deferred: Adding class xxforms-events-mode-default doesn't trigger ajax request on value change

Erik Bruchez
Administrator
In reply to this post by mabu
Martin,

Yes that's understood. But if we are to reduce the chatter between client and server, we need a better way than just filtering completely some events. At least, that's the current thinking!

-Erik