Skip to content

Instantly share code, notes, and snippets.

@MartijnR
Created June 10, 2020 22:29
Show Gist options
  • Save MartijnR/741109b1db4ae5b370384b00f76adf69 to your computer and use it in GitHub Desktop.
Save MartijnR/741109b1db4ae5b370384b00f76adf69 to your computer and use it in GitHub Desktop.
<?xml version="1.0" ?>
<h:html xmlns="http://www.w3.org/2002/xforms" xmlns:ev="http://www.w3.org/2001/xml-events" xmlns:h="http://www.w3.org/1999/xhtml" xmlns:jr="http://openrosa.org/javarosa" xmlns:odk="http://www.opendatakit.org/xforms" xmlns:orx="http://openrosa.org/xforms" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<h:head>
<h:title>pyxform-output-repeat-bug-3</h:title>
<model odk:xforms-version="1.0.0">
<itext>
<translation lang="English">
<text id="/data/member/member_name:label">
<value>
Name of
<output value=" ../pos " />
</value>
</text>
<text id="/data/txt:label">
<value>Enter text</value>
</text>
<text id="/data/txt_label:label">
<value>
Text entered:
<output value=" /data/txt " />
</value>
</text>
</translation>
</itext>
<instance>
<data id="pyxform-output-repeat-bug-3">
<member jr:template="">
<pos />
<member_name />
</member>
<member>
<pos />
<member_name />
</member>
<txt />
<txt_label />
<meta>
<instanceID />
</meta>
</data>
</instance>
<bind calculate="position(..)" nodeset="/data/member/pos" type="string" />
<bind nodeset="/data/member/member_name" type="string" />
<bind nodeset="/data/txt" type="string" />
<bind nodeset="/data/txt_label" type="string" />
<bind jr:preload="uid" nodeset="/data/meta/instanceID" readonly="true()" type="string" />
</model>
</h:head>
<h:body>
<group ref="/data/member">
<label></label>
<repeat nodeset="/data/member">
<input ref="/data/member/member_name">
<label ref="jr:itext('/data/member/member_name:label')" />
</input>
</repeat>
</group>
<input ref="/data/txt">
<label ref="jr:itext('/data/txt:label')" />
</input>
<input ref="/data/txt_label">
<label ref="jr:itext('/data/txt_label:label')" />
</input>
</h:body>
</h:html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment