Hello,
An additional question: I have started using subforms and noticed that my
<xf:message> elements are now no longer being alerted. I can see that they
are output to the DOM (inspecting with Firebug), but the alert notification
does not appear. I've tried declaring the messages in the subform as well,
but that didn't work. I'm sure I'm missing something here, but don't know
what.
Thank you,
Tim
On Mon, Apr 13, 2015 at 1:59 AM, Tim Thompson <[email protected]> wrote:
> Hello,
>
> I am running into an issue with repeat indexes when instance data has been
> replaced by a submission (running XSLTForms 609 in eXist 2.2).
>
> I send a query to the database:
>
> <xf:input id="query" ref="instance('search')/query" incremental="true">
> <xf:label>Search</xf:label>
> <xf:action ev:event="xforms-value-changed">
> <xf:send submission="submit-search"/>
> </xf:action>
> </xf:input>
>
> The submission that handles this replaces the instance data:
>
> <xf:submission id="submit-search" resource="/exist/restxq/query" method=
> "get"
> serialization="application/x-www-form-urlencoded" ref=
> "instance('search')/query"
> targetref="instance('search-results')" replace="instance"/>
>
> I then output the results to a table:
>
> <table id="results-table">
> <thead>
> <th>Field</th>
> <th>Value</th>
> </thead>
> <tbody>
> <xf:repeat nodeset="instance('search-results')/*" id=
> "search-results-repeat">
> <tr>
> <td>
> <xf:output value="substring-after(name(.), ':')"
> ></xf:output>
> </td>
> <td>
> <xf:output ref="."/>
> </td>
> </tr>
> </xf:repeat>
> </tbody>
> </table>
>
> I want to be able to click on a table row and set a value, based on the
> current index, to send back to the server:
>
> <xf:trigger>
> <xf:label>Select</xf:label>
> <xf:action ev:event="DOMActivate">
> <xf:setvalue ref="instance('search')/selected"
> value="instance('search-results')/*[position()
> = index('search-results-repeat')]/@rdf:about"/>
> <xf:send submission="select"/>
> </xf:action>
> </xf:trigger>
>
> However, when I replace the instance data with my first submission, the
> repeat index does not reset. My question is, is it possible to rebind the
> data so that the repeat index becomes active again, without having to do a
> "@replace = 'all'" on submission?
>
> Thank you!
>
> Tim
>
------------------------------------------------------------------------------
BPM Camp - Free Virtual Workshop May 6th at 10am PDT/1PM EDT
Develop your own process in accordance with the BPMN 2 standard
Learn Process modeling best practices with Bonita BPM through live exercises
http://www.bonitasoft.com/be-part-of-it/events/bpm-camp-virtual- event?utm_
source=Sourceforge_BPM_Camp_5_6_15&utm_medium=email&utm_campaign=VA_SF
_______________________________________________
Xsltforms-support mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/xsltforms-support