1

I have 2 servers and 2 different interpretations of {{ form.media }}

<link href="/static/admin/css/vendor/select2/select2.min.css" type="text/css" media="screen" rel="stylesheet">
<link href="/static/admin/css/autocomplete.css" type="text/css" media="screen" rel="stylesheet">
<link href="/static/autocomplete_light/select2.css" type="text/css" media="screen" rel="stylesheet">
<script type="text/javascript" src="/static/admin/js/vendor/jquery/jquery.min.js"></script>
<script type="text/javascript" src="/static/autocomplete_light/jquery.init.js"></script>
<script type="text/javascript" src="/static/admin/js/vendor/select2/select2.full.min.js"></script>
<script type="text/javascript" src="/static/admin/js/vendor/select2/i18n/en.js"></script>
<script type="text/javascript" src="/static/autocomplete_light/autocomplete.init.js"></script>
<script type="text/javascript" src="/static/autocomplete_light/forward.js"></script>
<script type="text/javascript" src="/static/autocomplete_light/select2.js"></script>
<script type="text/javascript" src="/static/autocomplete_light/jquery.post-setup.js"></script>

The difference is just one line:

<script type="text/javascript" src="/static/admin/js/vendor/jquery/jquery.min.js"></script>

If this one is activated, the select / change of the select2 dropdown doesn't work anymore. If this is commented, it works again.

I checked the pip freeze and they have the same packages versions:

Django==2.2 django-autocomplete-light==3.3.4

How is that possible that this line get added?

Ruben
  • 1,065
  • 5
  • 18
  • 44

0 Answers0