Skip to content

armgit / wger

Public Imported from GitHub
0

Self hosted FLOSS fitness/workout, nutrition and weight tracker

Move the German specific datepicker settings to the main template

Roland Geider2314da0e6efa
diff --git a/wger/manager/templates/day/log.html b/wger/manager/templates/day/log.html
index cf687c029..9b95c18b2 100644
--- a/wger/manager/templates/day/log.html
+++ b/wger/manager/templates/day/log.html
@@ -6,9 +6,6 @@
{% block title %}{% trans "New weight log" %} – {{day.description}}{% endblock %}
{% block header %}
-{% if language.short_name == 'de' %}
-<script src="{% static 'js/jquery.ui.datepicker-de.js' %}"></script>
-{% endif %}
<script type="text/javascript">
$(document).ready(function () {
$( "#id_date" ).datepicker();
diff --git a/wger/manager/templates/template.html b/wger/manager/templates/template.html
index 15a1173c4..6fe06486d 100644
--- a/wger/manager/templates/template.html
+++ b/wger/manager/templates/template.html
@@ -36,7 +36,9 @@
<script src="{% static 'js/jquery.js' %}" type="text/javascript"></script>
<script src="{% static 'js/jquery-ui.js' %}" type="text/javascript"></script>
<script src="{% static 'js/workout-manager.js' %}" type="text/javascript"></script>
-
+ {% if language.short_name == 'de' %}
+ <script src="{% static 'js/jquery.ui.datepicker-de.js' %}"></script>
+ {% endif %}
{% block header %}{% endblock %}
<script>
diff --git a/wger/manager/templates/workout/log.html b/wger/manager/templates/workout/log.html
index d4c6e18e6..34f1c1673 100644
--- a/wger/manager/templates/workout/log.html
+++ b/wger/manager/templates/workout/log.html
@@ -8,10 +8,6 @@
{% block header %}
<script src="{% static 'js/d3.js' %}"></script>
-{% if language.short_name == 'de' %}
-<script src="{% static 'js/jquery.ui.datepicker-de.js' %}"></script>
-{% endif %}
-
<script type="text/javascript">
// Initialise the datepicker for the modal dialog
function custom_modal_init()
diff --git a/wger/weight/templates/edit.html b/wger/weight/templates/edit.html
index 863383e41..cd419b632 100644
--- a/wger/weight/templates/edit.html
+++ b/wger/weight/templates/edit.html
@@ -8,10 +8,6 @@
{% block header %}
-{% if language.short_name == 'de' %}
-<script src="{% static 'js/jquery.ui.datepicker-de.js' %}"></script>
-{% endif %}
-
<script>
$(document).ready(function () {
init_weight_datepicker();
diff --git a/wger/weight/templates/weight_overview.html b/wger/weight/templates/weight_overview.html
index 430beee8d..b3ecb4c77 100644
--- a/wger/weight/templates/weight_overview.html
+++ b/wger/weight/templates/weight_overview.html
@@ -11,9 +11,6 @@
Header data
-->
{% block header %}
-{% if language.short_name == 'de' %}
-<script src="{% static 'js/jquery.ui.datepicker-de.js' %}"></script>
-{% endif %}
<script src="{% static 'js/d3.js' %}"></script>
<script src="{% static 'js/jquery-globalize/lib/globalize.js' %}"></script>