Text Template Renderer Groovy
Adding different types of data
In order to add | Define this data | Give it a column label (eg) | And add it to your template like this |
---|---|---|---|
Full Name | patientName | <b>Full Name:</b> $data.patientName | |
Full Name (Last, First) | patientName | <b>Name:</b> $data.patientName.familyName, $data.patientName.givenName | |
Age (years) | age | <b>Age:</b> $data.age years old | |
Age (years and months) | age | <b>Age:</b> $data.age.fullYears years $data.age.fullMonthsSinceLastBirthday months old | |
Birthdate | birthdate | <b>Birthdate:</b> <%= util.format(data.birthdate, "dd/MMM/yyyy") %> | |
Gender | gender | <b>Gender:</b> | |
Address | address | <b>Address:</b> $data.address.address1, $data.address.cityVillage | |
First Encounter of Type(s) | firstXyzEncounter | First XYZ Encounter occurred | |
Most Recent Weight | lastWeight | Most recent weight: | |
Obs Active List |
| obs | Active observations: |
Three Most Recent Weights | weights | <% |