Xform not displaying persons attributes

Hi everyone, I am using openmrs 2.2.1 with xforms 4.3.14 and I am using xform as patient registration form. I have added an attribute which is also a concept and added it on the registration form. The form is submitting successful and when check the database I see the data is captured in person_attribute table.

The challenge I am having is that I want this attribute to be displayed on other forms when opened. I have looked at the wiki "How to include person properties or attributes"XForms Module User Guide - Documentation - OpenMRS Wiki and try it but it does not display the data.

I have use $!{patient.getAttribute(personAttributeId).getValue()} i.e $!{patient.getAttribute(61).getValue()}. By the way personAttributeId confuses because person_attribute_id from the table person_attribute is for every recorded attribute. I thought it was supposed to be $!{patient.getAttribute(personAttributeTypeId).getValue()} from person_atribute_type table.

The variable I want to display is just a text.

Can you share the form’s xml via pastebin.com?

Here is the form’s xml https://pastebin.com/2T8YDWN1

It looks like a private paste.

Apparently I am getting this message on the pastebin and I don’t what is offensive on the form.

  • Pastebin’s SMART filters have detected potentially offensive or questionable content in your Paste. The content you are trying to publish has been deemed potentially offensive or questionable by our filters, because of this you’re receiving this warning. This Paste can only be published with the visibility set to “Private”.

I have attach the file instead xform xml.txt (180.1 KB)

I mean what you get from the File Save As menu item. The full form including layout

Do you mean in xform design view? HIV-Exposed-Infant-Baseline-test.txt (1.1 MB)