+
+ {{ first_name }}
+ {{ last_name }}
+ {% if maiden_name.is_some() %}
+ ({{ maiden_name.as_ref().unwrap() }})
+ {% endif %}
+
+
+
Sex:
+ {% match sex %}
+ {% when Sex::Male %}Male
+ {% when Sex::Female %}Female
+ {% when Sex::Other(desc) %}{{ desc }}
+ {% endmatch %}
+
+
Birthday: {{ date_of_birth.format("%Y-%m-%d") }}
+
ID: {{ id }}
+
+ Parents:
+ {% if parents.is_empty() %}
+
+ {% else %}
+
+ {% endif %}
+
+
+ {%- endblock -%}
diff --git a/test.json b/test.json
new file mode 100644
index 0000000..e9321df
--- /dev/null
+++ b/test.json
@@ -0,0 +1,49 @@
+{
+ "members": [
+ {
+ "id": "c7699942-7afa-47f1-b155-7357825a8aae",
+ "first_name": "John",
+ "last_name": "Doe",
+ "sex": "Male",
+ "date_of_birth": "1991-02-03T04:05:06Z",
+ "parents": [],
+ "marriages": [
+ {
+ "wife": "41fb59f9-c572-4785-b0cc-90dfba3aef10",
+ "husband": "c7699942-7afa-47f1-b155-7357825a8aae",
+ "date": "2020-03-04T05:06:07Z",
+ "divorce_date": null
+ }
+ ]
+ },
+ {
+ "id": "41fb59f9-c572-4785-b0cc-90dfba3aef10",
+ "first_name": "Jane",
+ "last_name": "Doe",
+ "maiden_name": "Musterfrau",
+ "sex": "Female",
+ "date_of_birth": "1990-01-02T03:04:05Z",
+ "parents": [],
+ "marriages": [
+ {
+ "wife": "41fb59f9-c572-4785-b0cc-90dfba3aef10",
+ "husband": "c7699942-7afa-47f1-b155-7357825a8aae",
+ "date": "2020-03-04T05:06:07Z",
+ "divorce_date": null
+ }
+ ]
+ },
+ {
+ "id": "1456bd02-c7d9-480d-922f-a2658bc4760c",
+ "first_name": "Johnny",
+ "last_name": "Doe",
+ "sex": "Male",
+ "date_of_birth": "2021-04-05T06:07:08Z",
+ "parents": [
+ "41fb59f9-c572-4785-b0cc-90dfba3aef10",
+ "c7699942-7afa-47f1-b155-7357825a8aae"
+ ],
+ "marriages": []
+ }
+ ]
+}
\ No newline at end of file