Use current language when creating an election

This commit is contained in:
Tom Hubrecht 2021-06-09 21:57:19 +02:00
parent ceba6f4269
commit 2240938b14

View file

@ -8,9 +8,14 @@
<link rel="stylesheet" href="{% static 'vendor/datetimepicker/picker.css' %}">
<script>
{% get_current_language as LANGUAGE_CODE %}
document.addEventListener('DOMContentLoaded', () => {
new DateTimePicker('input[name=start_date]', {});
new DateTimePicker('input[name=end_date]', {});
new DateTimePicker('input[name=start_date]', {
lang: '{{ LANGUAGE_CODE }}',
});
new DateTimePicker('input[name=end_date]', {
lang: '{{ LANGUAGE_CODE }}',
});
});
</script>