Closed
Bug 306447
Opened 20 years ago
Closed 19 years ago
strange behavior of xf:setvalue and xf:message within xf:repeat
Categories
(Core Graveyard :: XForms, defect)
Tracking
(Not tracked)
RESOLVED
INVALID
People
(Reporter: spsh, Assigned: aaronr)
Details
Attachments
(1 file, 1 obsolete file)
|
1.43 KB,
application/xhtml+xml
|
Details |
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.8b4) Gecko/20050810 Firefox/1.0+
Build Identifier: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.8b4) Gecko/20050810 Firefox/1.0+
it seems xf:setvalue don't update instance data while actions in xf:action
processed.
Second xf:message within xf:repeat aren't raised. And xf:setvalue within
xf:repeat not work properly (it set instance('edit')/@id with '')
Reproducible: Always
Steps to Reproduce:
1. Open attached testcase
2. Click on trigger "Go"
3. Click on first trigger "Inner go"
Actual Results:
After first click it displays two messages: both "Id: null".
After second click it displays ONE message: "Id: 1, row id: 2".
Expected Results:
After first click it displays two messages: "Id: null" and "Id: 1".
After second click it displays two messages: "Id: 1, row id: 2" and "Id: 2, row
id: 2".
Looks like there was a little problem with the testcase. Using
<xf:setvalue ref="instance('edit')/@id" value="@id"/> won't do what you intend.
Since you are providing a single node binding attribute on the setvalue
element, that means that when the expression for @value is evaluated, it will
use the bound node as the context of the expression. value will end up being
/root/@id/@id instead of instance('edit')/object/@id.
So I've attached a testcase that does what I think splash intended with the
original testcase.
This updated testcase shows that we still have two bugs:
1) only one message is being displayed when clicking on an 'Inner go' instead
of the expected two messages.
2) the message displayed by clicking on an 'Inner go' is a large sized window
and not the nice little compact message box that displays when clicking on the
first 'Go' trigger.
Attachment #194330 -
Attachment is obsolete: true
What can you say about:
>Actual Results:
>After first click it displays two messages: both "Id: null".
>Expected Results:
>After first click it displays two messages: "Id: null" and "Id: 1".
Is this a bug or feature?
(In reply to comment #3)
> What can you say about:
> >Actual Results:
> >After first click it displays two messages: both "Id: null".
> >Expected Results:
> >After first click it displays two messages: "Id: null" and "Id: 1".
> Is this a bug or feature?
If you look at the Deferred Updates section at
http://www.w3.org/TR/xforms/index-all.html#action-action you'll see that the
default recalculate, revalidate and refresh caused by setvalue inside an action
element are deferred until the end tag of the outermost action element. Unless
I am misreading this, I wouldn't expect the changes made by calling setvalue to
be reflected in the next message unless you explicitly have recalculate,
revalidate and refresh before message in that action.
Comment 5•19 years ago
|
||
(In reply to comment #2)
> This updated testcase shows that we still have two bugs:
> 1) only one message is being displayed when clicking on an 'Inner go' instead
> of the expected two messages.
bug 330671?
> 2) the message displayed by clicking on an 'Inner go' is a large sized window
> and not the nice little compact message box that displays when clicking on the
> first 'Go' trigger.
bug 328585?
But this bug itself is actually invalid, right?
Yep, I think that the original bug is invalid (as per my interpretation of the spec mentioned here) and the other bugs mentioned here have bugs open on them as Allan pointed out...the first bug is already fixed in current trunk. So closing this bug invalid.
Status: NEW → RESOLVED
Closed: 19 years ago
Resolution: --- → INVALID
Updated•9 years ago
|
Product: Core → Core Graveyard
You need to log in
before you can comment on or make changes to this bug.
Description
•