Login  Register

RE: Re: When I persist my instance the XML data is inverted

Posted by mar on Jan 11, 2010; 5:28pm
URL: https://discuss.orbeon.com/When-I-persist-my-instance-the-XML-data-is-inverted-tp1010066p1011409.html

Ethan,
 
I'm using the xxforms:instance because I've got multiple models and multiple instances in those models. xxforms:instance is supposed to find the instance regardless of the model. That said, in the example I've posted here instance('my-instance') works as well. I used the resource attribute because that is what's used in the tutorial example. I've tried using the action attribute instead but it persists the data inverted as well (no change). 

From: Ethan Gruber [mailto:[hidden email]]
Sent: Friday, January 08, 2010 5:16 PM
To: [hidden email]
Subject: [ops-users] Re: When I persist my instance the XML data is inverted

Not sure if/why it would make any difference, but is there a reason you're using ref="xxforms:instance('my-instance')" instead of ref="instance('my-instance')" and the resource attribute instead of action?

Ethan

On Fri, Jan 8, 2010 at 5:37 PM, Schwartzman, Martin <[hidden email]> wrote:
All,
 

For some reason when I persist my instance the XML data is inverted. If anyone can tell me why this is happening and how to correct it I would greatly appreciate it.

 

The model looks like:

 

<xforms:model id=”rootModel”>

 <xforms:instance id=”my-instance”>

  <my-instance-main>

    <books>

     <book>

      <title/>

      <author/>

     </book>

    </books>

    <houses>

     <house>

      <address/>

      <sqfeet/>

     </house>

    </houses>

  </my-instance-main>

 </xforms:instance>

</xforms:model>

 

The data is persisted via:

 

<xforms:submission id="save-submission-xml" ref="xxforms:instance('my-instance')" resource="/exist/rest/db/orbeon/xforms-sr/addServers-instance.xml" method="put" replace="none">

</xforms:submission>

 

I don’t understand why the <houses> element is coming before the <books> element.

 

<my-instance-main>

<houses>

  <house>

   <address/>

   <sqfeet/>

  </house>

 </houses>

 <books>

  <book>

   <title/>

   <author/>

  </book>

 </books>

</my-instance-main>

 



--
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




--
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