Advertisement
Guest User

Untitled

a guest
Sep 24th, 2019
180
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
HTML 1.88 KB | None | 0 0
  1. <table style="border-spacing: 10px; border-collapse: separate;" xmlns="http://www.w3.org/1999/xhtml">
  2.     <tr>
  3.         <th>Domain</th>
  4.         <th>URNO</th>
  5.         <th>Full Name</th>
  6.         <th>Sex</th>
  7.         <th>Date Of Birth</th>
  8.         <th></th>
  9.     </tr>
  10.     <xf:repeat id="search-list" ref="instance('search-results')/results">
  11.         <tr>
  12.             <td>
  13.                 <xf:output ref="xxf:split(masterPatientIdentifier, ':')[1]" />
  14.             </td>
  15.             <td>
  16.                 <xf:output ref="xxf:split(masterPatientIdentifier, ':')[2]" />
  17.             </td>
  18.             <td>
  19.                 <xf:output ref="concat(firstName, ', ', lastName)" />
  20.             </td>
  21.             <td>
  22.                 <xf:output ref="sex" />
  23.             </td>
  24.             <td>
  25.                 <xf:output ref="dob" />
  26.             </td>
  27.             <td>
  28.                 <xf:trigger appearance="minimal">
  29.                     <xf:label ref="'Select'"/>
  30.                     <xf:action event="DOMActivate">
  31.                         <!-- Delete the value in the current patient binding -->
  32.                         <xf:delete ref="xxf:binding('workflow-rest-search')/*"/>
  33.                         <!-- Save the position we are in the list +1 as when finding the position it starts from 1 -->
  34.                         <xf:var name="index" value="count(preceding-sibling::*[name() = name(current())]) + 1"/>
  35.                         <!-- Insert the Context from the instance back into the binding of the form -->
  36.                         <xf:insert context="xxf:binding('workflow-rest-search')" origin="instance('search-results')/results[$index]/*"/>
  37.                         <!-- Hide the dialogue after selection -->
  38.                         <xxf:hide dialog="my-dialog-id"/>
  39.                     </xf:action>
  40.                 </xf:trigger>
  41.             </td>
  42.         </tr>
  43.     </xf:repeat>
  44. </table>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement