Skip to content

Commit

Permalink
Adjusted date picker localization file url (#1557)
Browse files Browse the repository at this point in the history
Simplified code
  • Loading branch information
Chandra Lash authored and amplifi committed Jun 6, 2017
1 parent 3dcb807 commit 27ee39e
Show file tree
Hide file tree
Showing 6 changed files with 6 additions and 24 deletions.
5 changes: 1 addition & 4 deletions cadasta/templates/party/party_add.html
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,7 @@
{{ form.media }}
<script src="{% static 'js/jquery-ui.min.js' %}"></script>
<script src="{% static 'js/form_submit.js' %}"></script>
{% if get_current_language != "en-us" %}
{% get_current_language as LANGUAGE_CODE %}
<script src="https://cdn.rawgit.com/jquery/jquery-ui/1.12.1/ui/i18n/datepicker-{{ LANGUAGE_CODE }}.js"></script>
{% endif %}
<script src="https://cdn.rawgit.com/jquery/jquery-ui/1.12.1/ui/i18n/datepicker-{{ LANGUAGE_CODE }}{% if LANGUAGE_CODE == 'en' %}-GB{% endif %}.js"></script>
<script>
$(document).ready(function () {
$('.datepicker').datepicker({
Expand Down
5 changes: 1 addition & 4 deletions cadasta/templates/party/party_edit.html
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,7 @@
{{ form.media }}
<script src="{% static 'js/jquery-ui.min.js' %}"></script>
<script src="{% static 'js/form_submit.js' %}"></script>
{% if get_current_language != "en-us" %}
{% get_current_language as LANGUAGE_CODE %}
<script src="https://cdn.rawgit.com/jquery/jquery-ui/1.12.1/ui/i18n/datepicker-{{ LANGUAGE_CODE }}.js"></script>
{% endif %}
<script src="https://cdn.rawgit.com/jquery/jquery-ui/1.12.1/ui/i18n/datepicker-{{ LANGUAGE_CODE }}{% if LANGUAGE_CODE == 'en' %}-GB{% endif %}.js"></script>
<script>
$(document).ready(function () {
$('.datepicker').datepicker({
Expand Down
5 changes: 1 addition & 4 deletions cadasta/templates/party/relationship_edit.html
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,7 @@
{{ block.super }}
{{ form.media }}
<script src="{% static 'js/jquery-ui.min.js' %}"></script>
{% if get_current_language != "en-us" %}
{% get_current_language as LANGUAGE_CODE %}
<script src="https://cdn.rawgit.com/jquery/jquery-ui/1.12.1/ui/i18n/datepicker-{{ LANGUAGE_CODE }}.js"></script>
{% endif %}
<script src="https://cdn.rawgit.com/jquery/jquery-ui/1.12.1/ui/i18n/datepicker-{{ LANGUAGE_CODE }}{% if LANGUAGE_CODE == 'en' %}-GB{% endif %}.js"></script>
<script>
$(document).ready(function () {
$('.datepicker').datepicker({
Expand Down
5 changes: 1 addition & 4 deletions cadasta/templates/spatial/location_add.html
Original file line number Diff line number Diff line change
Expand Up @@ -28,10 +28,7 @@
<script src="{% static 'js/leaflet.markercluster.js' %}"></script>
<script src="{% static 'js/L.Map.Deflate.js' %}"></script>
<script src="{% static 'js/jquery-ui.min.js' %}"></script>
{% if get_current_language != "en-us" %}
{% get_current_language as LANGUAGE_CODE %}
<script src="https://cdn.rawgit.com/jquery/jquery-ui/1.12.1/ui/i18n/datepicker-{{ LANGUAGE_CODE }}.js"></script>
{% endif %}
<script src="https://cdn.rawgit.com/jquery/jquery-ui/1.12.1/ui/i18n/datepicker-{{ LANGUAGE_CODE }}{% if LANGUAGE_CODE == 'en' %}-GB{% endif %}.js"></script>
<script src="{% static 'js/map_utils.js' %}"></script>
<script src="{% static 'js/form_submit.js' %}"></script>
<script>
Expand Down
5 changes: 1 addition & 4 deletions cadasta/templates/spatial/location_edit.html
Original file line number Diff line number Diff line change
Expand Up @@ -25,10 +25,7 @@
<script src="{% static 'js/leaflet.markercluster.js' %}"></script>
<script src="{% static 'js/L.Map.Deflate.js' %}"></script>
<script src="{% static 'js/jquery-ui.min.js' %}"></script>
{% if get_current_language != "en-us" %}
{% get_current_language as LANGUAGE_CODE %}
<script src="https://cdn.rawgit.com/jquery/jquery-ui/1.12.1/ui/i18n/datepicker-{{ LANGUAGE_CODE }}.js"></script>
{% endif %}
<script src="https://cdn.rawgit.com/jquery/jquery-ui/1.12.1/ui/i18n/datepicker-{{ LANGUAGE_CODE }}{% if LANGUAGE_CODE == 'en' %}-GB{% endif %}.js"></script>
<script src="{% static 'js/map_utils.js' %}"></script>
<script src="{% static 'js/form_submit.js' %}"></script>
<script>
Expand Down
5 changes: 1 addition & 4 deletions cadasta/templates/spatial/relationship_add.html
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,7 @@
<script src="https://cdnjs.cloudflare.com/ajax/libs/select2/4.0.3/js/select2.min.js"></script>
<script src="{% static 'js/form_submit.js' %}"></script>
<script src="{% static 'js/jquery-ui.min.js' %}"></script>
{% if get_current_language != "en-us" %}
{% get_current_language as LANGUAGE_CODE %}
<script src="https://cdn.rawgit.com/jquery/jquery-ui/1.12.1/ui/i18n/datepicker-{{ LANGUAGE_CODE }}.js"></script>
{% endif %}
<script src="https://cdn.rawgit.com/jquery/jquery-ui/1.12.1/ui/i18n/datepicker-{{ LANGUAGE_CODE }}{% if LANGUAGE_CODE == 'en' %}-GB{% endif %}.js"></script>
<script>
$(document).ready(function() {
var template = function(party) {
Expand Down

0 comments on commit 27ee39e

Please sign in to comment.