xforms-value-changed bug

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

xforms-value-changed bug

Park, Michael

Hello,

 

I’ve run into a situation where an ‘xforms:delete’ is being recognized as a ‘xforms-value-changed’ event.  This is then causing an ‘xforms:setvalue’ action to occur.  I believe this is a bug.

 

I’ve attached the code and here is the link to the code (for the sandbox): http://dl.lib.brown.edu/mwp/xforms/genre.xhtml.  You will see I’ve placed a message in the xforms-value-changed to show that the delete is causing a change.

 

*NOTE: the delete must be at an inner position().  So add 3 or more and delete position 2.  In other words, it never happens for the last or first node.

 

Thanks,

Mike



--
You receive this message as a subscriber of the [hidden email] mailing list.
To unsubscribe: mailto:[hidden email]
For general help: mailto:[hidden email]?subject=help
OW2 mailing lists service home page: http://www.ow2.org/wws

genre.xhtml (8K) Download Attachment
Reply | Threaded
Open this post in threaded view
|

xforms-value-changed bug

Park, Michael

Hello,

 

I’ve run into a situation where an ‘xforms:delete’ is being recognized as a ‘xforms-value-changed’ event in a repeat.  This is then causing an ‘xforms:setvalue’ action to occur.  I believe this is a bug.

 

I’ve attached the code and here is the link to the code (for the sandbox): http://dl.lib.brown.edu/mwp/xforms/genre.xhtml.  You will see I’ve placed a message in the xforms-value-changed to show that the delete is causing a change.

 

*NOTE: the delete problem occurs at an inner position().  So add 3 or more and delete position 2.  In other words, it never happens for the last or first node.

 

Thanks,

Mike



--
You receive this message as a subscriber of the [hidden email] mailing list.
To unsubscribe: mailto:[hidden email]
For general help: mailto:[hidden email]?subject=help
OW2 mailing lists service home page: http://www.ow2.org/wws

genre.xhtml (8K) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: xforms-value-changed bug

Alessandro Vernet
Administrator
In reply to this post by Park, Michael
Michael,

On Dec 4, 2007 1:43 PM, Park, Michael <[hidden email]> wrote:
> I've run into a situation where an 'xforms:delete' is being recognized as a
> 'xforms-value-changed' event.  This is then causing an 'xforms:setvalue'
> action to occur.  I believe this is a bug.

This is not a bug. Here is how it works: if you have a list: 1, 2, 3,
4 and delete 2, from the "xforms-value-changed" events perspective, it
is as if:

* 1 didn't change
* 2 became 3
* 3 became 4

So most of the time you will receive xforms-value-changed events when
you are doing a delete.

Alex
--
Orbeon Forms - Web 2.0 Forms, open-source, for the Enterprise
http://www.orbeon.com/


--
You receive this message as a subscriber of the [hidden email] mailing list.
To unsubscribe: mailto:[hidden email]
For general help: mailto:[hidden email]?subject=help
OW2 mailing lists service home page: http://www.ow2.org/wws
Reply | Threaded
Open this post in threaded view
|

xforms-value-changed in a repeat

Park, Michael
Regarding an old post...  I was wondering if there is a workaround.

I have a 2 tier select1 inside a repeat.  When the first select1 is
changed I'd like to set the other to an empty string on
xforms-value-changed.  This works fine until the scenario below (I
delete an element).  The delete causes an xforms-value-changed.

(I've attached the code - running on a recent nightly build)

----------On Jan 16, 2008 1:43 PM, Alessandro Vernet wrote ----------
This is not a bug. Here is how it works: if you have a list: 1, 2, 3,
4 and delete 2, from the "xforms-value-changed" events perspective, it
is as if:

* 1 didn't change
* 2 became 3
* 3 became 4

So most of the time you will receive xforms-value-changed events when
you are doing a delete.


--
You receive this message as a subscriber of the [hidden email] mailing list.
To unsubscribe: mailto:[hidden email]
For general help: mailto:[hidden email]?subject=help
OW2 mailing lists service home page: http://www.ow2.org/wws

genres.xhtml (6K) Download Attachment