xref: /webtrees/resources/xml/reports/bdm_report.xml (revision 8121b9bec19818120092699199161a1357bb8f3f)
1<?xml version="1.0" encoding="UTF-8" ?>
2<Report>
3	<Title><var var="I18N::translate('Vital records')" /></Title>
4	<Description><var var="I18N::translate('A report of vital records for a given date or place.')" /></Description>
5	<Input name="name" lookup="NAME" type="text"><var var="I18N::translate('Name')" /></Input>
6	<Input name="bdmplace" lookup="PLAC" type="text"><var var="I18N::translate('Place')" /></Input>
7	<Input name="birthdate1" lookup="DATE" type="text"><var var="I18N::translate('Birth date range start')" /></Input>
8	<Input name="birthdate2" lookup="DATE" type="text"><var var="I18N::translate('Birth date range end')" /></Input>
9	<Input name="deathdate1" lookup="DATE" type="text"><var var="I18N::translate('Death date range start')" /></Input>
10	<Input name="deathdate2" lookup="DATE" type="text"><var var="I18N::translate('Death date range end')" /></Input>
11	<Input name="sortby" type="select" default="BIRT:DATE" options="NAME=>I18N::translate('sort by name')|BIRT:DATE=>I18N::translate('sort by date of birth')|DEAT:DATE=>I18N::translate('sort by date of death')"><var var="I18N::translate('Sort order')" /></Input>
12	<Input name="pageSize" type="select" default="A4" options="letter=>I18N::translateContext('paper size','Letter')|A3=>I18N::translateContext('paper size', 'A3')|A4=>I18N::translateContext('paper size','A4')|legal=>I18N::translateContext('paper size','Legal')"><var var="I18N::translate('Page size')" /></Input>
13	<!--
14	<Input name="fonts" type="select" default="dejavusans" options="arialunicid0=>I18N::translateContext('font name', 'Arial')|dejavusans=>I18N::translateContext('font name', 'DejaVu')|helvetica=>I18N::translateContext('font name', 'Helvetica')"><var var="I18N::translate('Font')"/></Input>
15	-->
16	<SetVar name="fonts" value="dejavusans" />
17
18	<!-- Header -->
19	<Style name="header" font="$fonts" size="15" style="b" />
20	<!-- Page numbers text -->
21	<Style name="pagenum" font="$fonts" size="8"/>
22	<!-- Standard text -->
23	<Style name="text" font="$fonts" size="9"/>
24	<!-- Generated by style - required style name by the generator -->
25	<Style name="genby" font="$fonts" size="8" />
26	<!-- Date text -->
27	<Style name="date" font="$fonts" size="8"/>
28	<Style name="small" font="$fonts" size="7"/>
29	<Style name="label" font="$fonts" size="10" style="b" />
30
31	<Doc pageSize="$pageSize" orientation="landscape">
32		<Header>
33			<Cell align="center" newline="1" style="header">
34				<var var="I18N::translate('Vital records')" />
35				<if condition="$name!=''">
36				    : <var var="name" />
37				</if>
38				<if condition="$bdmplace!=''">
39					: <var var="bdmplace" />
40				</if>
41			</Cell>
42			<Cell align="rightrtl" height="10" newline="1" style="pagenum"><var var="I18N::translate('Page')" /> <PageNum /> <var var="I18N::translate('of')" /> <TotalPages /></Cell>
43			<!-- Name -->
44			<SetVar name="fill" value="" />
45			<if condition="$sortby=='NAME'">
46				<SetVar name="fill" value="#AAAAAA" />
47			</if>
48			<TextBox bgcolor="$fill" border="1" height="12" width="205">
49				<Text style="label"><var var="I18N::translate('Name')" /></Text>
50			</TextBox>
51			<!-- Birth -->
52			<SetVar name="fill" value="" />
53			<if condition="$sortby=='BIRT:DATE'">
54				<SetVar name="fill" value="#AAAAAA" />
55			</if>
56			<TextBox bgcolor="$fill" border="1" height="12" width="165">
57				<Text style="label">
58					<var var="I18N::translate('Birth')" />
59					<if condition="$birthdate1!='' or $birthdate2!=''">
60						[
61						<if condition="$birthdate1!=''">
62							<var var="birthdate1" />
63						</if>
64						-
65						<if condition="$birthdate2!=''">
66							<var var="birthdate2" />
67						</if>
68						]
69					</if>
70				</Text>
71			</TextBox>
72			<!-- Marrige -->
73			<SetVar name="fill" value="" />
74			<if condition="$sortby=='MARR:DATE'">
75				<SetVar name="fill" value="#AAAAAA" />
76			</if>
77			<TextBox bgcolor="$fill" border="1" height="12" width="165">
78				<Text style="label"><var var="I18N::translate('Marriage')" /></Text>
79			</TextBox>
80			<!-- Death -->
81			<SetVar name="fill" value="" />
82			<if condition="$sortby=='DEAT:DATE'">
83				<SetVar name="fill" value="#AAAAAA" />
84			</if>
85			<TextBox bgcolor="$fill" border="1" height="12" newline="1">
86				<Text style="label">
87					<var var="I18N::translate('Death')" />
88					<if condition="$deathdate1!='' or $deathdate2!=''">
89						[
90						<if condition="$deathdate1!=''">
91							<var var="deathdate1" />
92						</if>
93						-
94						<if condition="$deathdate2!=''">
95							<var var="deathdate2" />
96						</if>
97						]
98					</if>
99				</Text>
100			</TextBox>
101		</Header>
102
103		<Body>
104			<SetVar name="filter1" value="" />
105			<if condition="$bdmplace!=''">
106				<SetVar name="filter1" value=":PLAC CONTAINS $bdmplace" />
107				<!-- todo: print only if BDM place is the searched place - use OR - search also on marriage place and date -->
108			</if>
109
110			<List list="individual" filter1="$filter1" filter2="BIRT:DATE GTE $birthdate1" filter3="BIRT:DATE LTE $birthdate2" filter4="DEAT:DATE GTE $deathdate1" filter5="DEAT:DATE LTE $deathdate2" filter6="NAME CONTAINS $name" sortby="$sortby">
111				<SetVar name="spid" value="@ID" />
112
113				<TextBox width="205" height="46">
114					<Text style="text">
115						<GetPersonName id="" /><br />
116					</Text>
117					<Text style="small">
118						   <var var="I18N::translate('Father')" />
119						: <Gedcom id="@FAMC"><GetPersonName id="@HUSB" /></Gedcom>
120						<br />   <var var="I18N::translate('Mother')" />
121						: <Gedcom id="@FAMC"><GetPersonName id="@WIFE" /></Gedcom>
122					</Text>
123				</TextBox>
124
125				<TextBox width="165" height="46" border="0">
126					<SetVar name="moreB" value="0" />
127					<Text style="small">
128						<RepeatTag tag="BIRT">
129							<if condition="$moreB==1">
130								<br />
131							</if>
132							<var var="I18N::translate('Date')" />
133							: <GedcomValue tag="BIRT:DATE" />
134							<br />  <var var="I18N::translate('Place')" />
135							: <GedcomValue tag="BIRT:PLAC" />
136							<br />  <var var="I18N::translate('Source')" />
137							: <RepeatTag tag="BIRT:SOUR">
138								<Gedcom id="@SOUR">
139									<GedcomValue tag="TITL" />
140								</Gedcom>
141							</RepeatTag>
142							<SetVar name="moreB" value="1" />
143						</RepeatTag>
144					</Text>
145				</TextBox>
146
147				<TextBox width="165" height="46" border="0">
148					<SetVar name="more" value="0" />
149					<RepeatTag tag="FAMS">
150						<Text style="small">
151							<Gedcom id="@FAMS">
152								<if condition="$more==1">
153									<br />
154									________________________________
155									<br />
156								</if>
157								<!-- todo: print the dates, places and sources of all the FAM MARR records -->
158								<var var="I18N::translate('Date')" />
159								: <GedcomValue tag="MARR:DATE" />
160								<br />  <var var="I18N::translate('Place')" />
161								: <GedcomValue tag="MARR:PLAC" />
162								<br />  <var var="I18N::translate('Source')" />
163								: <RepeatTag tag="MARR:SOUR">
164									<Gedcom id="@SOUR">
165										<GedcomValue tag="TITL" />
166									</Gedcom>
167								</RepeatTag>
168								<br />
169								<var var="I18N::translate('Spouse')" />
170								:
171								<SetVar name="hpid" value="@HUSB"/>
172								<SetVar name="wpid" value="@WIFE"/>
173								<if condition="$spid==$wpid">
174									<GetPersonName id="@HUSB" />
175								</if>
176								<if condition="$spid==$hpid">
177									<GetPersonName id="@WIFE" />
178								</if>
179								<SetVar name="more" value="1" />
180							</Gedcom>
181						</Text>
182					</RepeatTag>
183				</TextBox>
184
185				<TextBox border="0" height="46" newline="1">
186					<SetVar name="moreD" value="0" />
187					<Text style="small">
188						<RepeatTag tag="DEAT">
189							<if condition="$moreD==1">
190								<br />
191							</if>
192							<var var="I18N::translate('Date')" />
193							: <GedcomValue tag="DEAT:DATE" />
194							<br />  <var var="I18N::translate('Place')" />
195							: <GedcomValue tag="DEAT:PLAC" />
196							<br />  <var var="I18N::translate('Source')" />
197							: <RepeatTag tag="DEAT:SOUR">
198								<Gedcom id="@SOUR">
199									<GedcomValue tag="TITL" />
200								</Gedcom>
201							</RepeatTag>
202							<SetVar name="moreD" value="1" />
203						</RepeatTag>
204					</Text>
205				</TextBox>
206				<Line />
207			</List>
208
209			<Cell align="rightrtl" height="24" newline="1" style="label"><br />
210				<var var="I18N::translate('Total individuals')" />
211				: <ListTotal />
212			</Cell>
213		</Body>
214		<Footer>
215			<Cell align="rightrtl" newline="1" style="date"><Now /></Cell>
216		</Footer>
217	</Doc>
218</Report>
219