Use configuration object for load builders

This commit is contained in:
2024-10-09 12:08:48 +02:00
committed by Bartuccio Antoine
parent 93eb09887e
commit 6f4e93bb76
4 changed files with 40 additions and 24 deletions

View File

@ -91,13 +91,13 @@
<script>
window.addEventListener("DOMContentLoaded", () => {
loadFamilyGraph(
"{{ api_url }}",
"{{ object.id }}",
{{ depth_min }},
{{ depth_max }},
);
})
loadFamilyGraph({
apiUrl: "{{ api_url }}",
activeUser: "{{ object.id }}",
depthMin: {{ depth_min }},
depthMax: {{ depth_max }},
});
});
</script>
{% endblock %}

View File

@ -62,7 +62,9 @@
{{ super() }}
<script>
window.addEventListener("DOMContentLoaded", () => {
loadPicturePage("{{ url("api:pictures") }}" + "?users_identified={{ object.id }}");
loadPicturePage({
apiUrl: "{{ url("api:pictures") }}?users_identified={{ object.id }}"
});
})
</script>
{% endblock script %}