- From: Roland Merrick <roland_merrick@uk.ibm.com>
- Date: Mon, 7 Mar 2005 13:50:37 +0000
- To: jeacott@hardlight.com.au
- Cc: chiba-users@lists.sourceforge.net, joern Turner <joern.turner@web.de>, Stefano Debenedetti <ste@demaledetti.net>, www-forms@w3.org, www-forms-request@w3.org
- Message-ID: <OFCF52994F.CEEB5352-ON80256FBD.004BC45D-80256FBD.004C0A8E@uk.ibm.com>
Greetings Jason, what you want to do is indeed "tricky" in XForms 1.0.
However, this scenario is being addressed in XForms 1.1. Take at look at
the new submission attributes [1] which look as if they would satisfy your
needs.
[1] http://www.w3.org/TR/2004/WD-xforms11-20041115/#attrib-submit-relevant
Regards, Roland
"Jason Eacott" <jeacott@hardlight.com.au>
Sent by: www-forms-request@w3.org
05/03/2005 23:18
Please respond to
jeacott
To
Stefano Debenedetti <ste@demaledetti.net>
cc
www-forms@w3.org, chiba-users@lists.sourceforge.net, joern Turner
<joern.turner@web.de>
Subject
Re: Xforms submissions can rarely be reloaded, can this be fixed?
thank you.
yes I do mean that parts definitely arent submitted
because relevant is false on them (I am using Chiba here).
this seems to be correct given this entry
http://www.w3.org/TR/2003/REC-xforms-20031014/slice6.html#model-prop-relevant
and means that you could be throwing away good data just because you dont
want to display it. just because its not relevant for a user to see
doesn't mean the data should be dumped, it may become relevant later (much
later, after multiple rounds of reloading!), and it may have been data
that they originally entered.
and because switch is not as dynamic as it should be there is often no
choice but to use relevant to control the ui.
but what I read into the references you mention is that I should be able
to reload this submission regardless of missing parts during the same form
session and the missing parts SHOULD be regenerated using any bind
elements as a reference.
in this case I think Chiba is broken here. (I have gotten around it given
a known schema by reprocessing the instance with xsl & replacing the
missing nodes & attributes manually on request - but this sux IMHO)
Its submission is correct but its reloading does not seem to try to
recreate missing nodes, but rather just throws xpath exceptions.
I like that I can control what is actually being submitted by using a
relevant property, but it means that using the UI has side effects in the
instance.
there should be another switch, or separate instance-relevant property to
indicate whether you intended the relevant to be ONLY for the ui or that
it
should result in culling data from the instance.
thanks for the response.
Jason.
Date sent: Sat, 05 Mar 2005 18:32:03 +0100
From: Stefano Debenedetti <ste@demaledetti.net>
To: www-forms@w3.org
Subject: Re: Xforms submissions can rarely be
reloaded, can this be fixed?
Forwarded by: www-forms@w3.org
Date forwarded: Sat, 05 Mar 2005 17:29:06 +0000
>
> Hello Jason,
>
> Jason Eacott ha scritto:
> > Hi All,
> > I just noticed this little caveat of the relevant
attribute:
> >
> >
> >>Instance data nodes with this property evaluating to false are not >
serialized for submission.
> >
> >
> > this means that If I ever use relevant (and its a dull form that
doesn't) then I can never reload that
> > same instance data if I have binds or refs to ANY of the parts that
relevant is set on.
>
> Not sure I understand what you mean (do you mean the parts that weren't
submitted because relevant was false on them?) but it doesn't seem to be
the case according to:
>
>
http://www.w3.org/TR/2003/REC-xforms-20031014/slice4.html#evt-modelConstructDone
>
> > surely this is ridiculous. isnt one of the primary outcomes of x-forms
supposed to be that you
> > can easilly manipulate xml, save it, and then read it back in top
modify it sometime later?
>
> The XForms design goals are stated here, it doesn't seem to me that they
cover exactly what you mentioned:
>
> http://www.w3.org/TR/2003/REC-xforms-20031014/slice2.html
>
> > This is just about the last straw for me and x-forms I think.
>
> Do you mean you like h^TML forms better? ;-) Sorry about this one..
>
> > UNLESS
> >
> > can anyone tell me whether if I load (ie via <submission
replace="instance" />) new instance
> > data that is missing elements and/or attributes that are bound in the
form, whether the x-forms
> > processor should ignore the missing parts, or whether it should throw
an error?
>
> See reference above for the exact rules and algorithm.
>
> I may be getting it wrong but it seems to me that XForms 1.1 will make
even easier to control this issue as it would allow to create arbitrary
instance nodes on the fly in response to events.
>
> > hoping someone can shed some light.
>
> HTH, ciao
> ste
>
> > thanks
> > Jason.
> >
> >
> >
>
Received on Monday, 7 March 2005 13:51:45 UTC