Get rid of the namespace prefix in templates and includes.
[working/NCIPServer.git] / templates / includes / UserOptionalFields.inc
1 [% IF data.UserOptionalFields -%]
2 <UserOptionalFields>
3 [% IF data.UserOptionalFields.NameInformation -%]
4 <NameInformation>
5 <PersonalNameInformation>
6 <StructuredPersonalUserName>
7 [% IF data.UserOptionalFields.NameInformation.GivenName -%]
8 <GivenName>[% data.UserOptionalFields.NameInformation.GivenName | xml %]</GivenName>
9 [% END -%]
10 <Surname>[% data.UserOptionalFields.NameInformation.Surname | xml %]</Surname>
11 [% IF data.UserOptionalFields.NameInformation.Prefix -%]
12 <Prefix>[% data.UserOptionalFields.NameInformation.Prefix %]</Prefix>
13 [% END -%]
14 [% IF data.UserOptionalFields.NameInformation.Suffix -%]
15 <Suffix>[% data.UserOptionalFields.NameInformation.Suffix %]</Suffix>
16 [% END -%]
17 [% IF data.UserOptionalFields.NameInformation.Initials -%]
18 <Initials>[% data.UserOptionalFields.NameInformation.Initials %]</Initials>
19 [% END -%]
20 </StructuredPersonalUserName>
21 </PersonalNameInformation>
22 </NameInformation>
23 [% END -%]
24 [% IF data.UserOptionalFields.UserAddressInformation -%]
25 [% FOREACH element IN data.UserOptionalFields.UserAddressInformation -%]
26 <UserAddressInformation>
27 <UserAddressRoleType>[% element.UserAddressRoleType | xml %]</UserAddressRoleType>
28 [% IF element.PhysicalAddress -%]
29 <PhysicalAddress>
30 <StructuredAddress>
31 <Line1>[% element.PhysicalAddress.Line1 | xml %]</Line1>
32 [% IF element.PhysicalAddress.Line2 -%]
33 <Line2>[% element.PhysicalAddress.Line2 | xml %]</Line2>
34 [% END -%]
35 [% IF element.PhysicalAddress.Locality -%]
36 <Locality>[% element.PhysicalAddress.Locality | xml %]</Locality>
37 [% END -%]
38 [% IF element.PhysicalAddress.Region -%]
39 <Region>[% element.PhysicalAddress.Region | xml %]</Region>
40 [% END -%]
41 [% IF element.PhysicalAddress.Country -%]
42 <Country>[% element.PhysicalAddress.Country | xml %]</Country>
43 [% END -%]
44 [% IF element.PhysicalAddress.PostalCode -%]
45 <PostalCode>[% element.PhysicalAddress.PostalCode | xml %]</PostalCode>
46 [% END -%]
47 </StructuredAddress>
48 <PhysicalAddressType>Postal Address</PhysicalAddressType>
49 </PhysicalAddress>
50 [% ELSIF element.ElectronicAddress -%]
51 <ElectronicAddress>
52 <ElectronicAddressType>[% element.ElectronicAddress.Type | xml %]</ElectronicAddressType>
53 <ElectronicAddressData>[% element.ElectronicAddress.Data | xml %]</ElectronicAddressData>
54 </ElectronicAddress>
55 [% END -%]
56 </UserAddressInformation>
57 [% END -%]
58 [% END -%]
59 [% IF data.UserOptionalFields.UserPrivilege -%]
60 [% FOREACH privilege IN data.UserOptionalFields.UserPrivilege -%]
61 <UserPrivilege>
62 <AgencyId>[% privilege.AgencyId | xml -%]</AgencyId>
63 <AgencyUserPrivilegeType>[% privilege.AgencyUserPrivilegeType | xml %]</AgencyUserPrivilegeType>
64 [% IF privilege.ValidFromDate -%]
65 <ValidFromDate>[% privilege.ValidFromDate | xml %]</ValidFromDate>
66 [% END -%]
67 [% IF privilege.ValidToDate -%]
68 <ValidToDate>[% privilege.ValidToDate | xml %]</ValidToDate>
69 [% END -%]
70 [% IF privilege.UserPrivilegeDescription -%]
71 <UserPrivilegeDescription>[% privilege.UserPrivilegeDescription | xml %]</UserPrivilegeDescription>
72 [% END -%]
73 [% IF privilege.UserPrivilegeStatus -%]
74 <UserPrivilegeStatus>
75 <UserPrivilegeStatusType>
76 [% privilege.UserPrivilegeStatus.UserPrivilegeStatusType | xml %]
77 </UserPrivilegeStatusType>
78 [% IF privilege.UserPrivilegeStatus.DateOfUserPrivilegeStatus -%]
79 <DateOfUserPrivilegeStatus>
80 [% privilege.UserPrivilegeStatus.DateOfUserPrivilegeStatus | xml %]
81 </DateOfUserPrivilegeStatus>
82 [% END -%]
83 </UserPrivilegeStatus>
84 [% END -%]
85 </UserPrivilege>
86 [% END -%]
87 [% END -%]
88 [% IF data.UserOptionalFields.UserLanguage -%]
89 [% FOREACH language IN data.UserOptionalFields.UserLanguage -%]
90 <UserLanguage>[% language | xml %]</UserLanguage>
91 [% END -%]
92 [% END -%]
93 [% IF data.UserOptionalFields.BlockOrTrap -%]
94 [% FOREACH block IN data.UserOptionalFields.BlockOrTrap -%]
95 <BlockOrTrap>
96 <AgencyId>[% block.AgencyId | xml %]</AgencyId>
97 <BlockOrTrapType>[% block.BlockOrTrapType | xml %]</BlockOrTrapType>
98 [% IF block.ValidFromDate -%]
99 <ValidFromDate>[% block.ValidFromDate %]</ValidFromDate>
100 [% END -%]
101 [% IF block.ValidToDate -%]
102 <ValidToDate>[% block.ValidToDate %]</ValidToDate>
103 [% END %]
104 </BlockOrTrap>
105 [% END -%]
106 [% END -%]
107 </UserOptionalFields>
108 [% END -%]