mirror of
https://github.com/ae-utbm/sith.git
synced 2024-11-26 11:04:20 +00:00
core: move jquery to header section
This commit is contained in:
parent
4afd7a0023
commit
4d866843e1
@ -16,6 +16,9 @@
|
|||||||
{% else %}
|
{% else %}
|
||||||
<link rel="stylesheet" href="{{ static('core/font-awesome/css/font-awesome.min.css') }}">
|
<link rel="stylesheet" href="{{ static('core/font-awesome/css/font-awesome.min.css') }}">
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
|
||||||
|
<!-- Jquery declared here to be accessible in every django widgets -->
|
||||||
|
<script src="{{ static('core/js/jquery-3.1.0.min.js') }}"></script>
|
||||||
{% endblock %}
|
{% endblock %}
|
||||||
</head>
|
</head>
|
||||||
|
|
||||||
@ -248,7 +251,6 @@
|
|||||||
{% endblock %}
|
{% endblock %}
|
||||||
-->
|
-->
|
||||||
{% block script %}
|
{% block script %}
|
||||||
<script src="{{ static('core/js/jquery-3.1.0.min.js') }}"></script>
|
|
||||||
<script src="{{ static('core/js/ui/jquery-ui.min.js') }}"></script>
|
<script src="{{ static('core/js/ui/jquery-ui.min.js') }}"></script>
|
||||||
<script src="{{ static('core/js/ui/i18n/datepicker-fr.js') }}"></script>
|
<script src="{{ static('core/js/ui/i18n/datepicker-fr.js') }}"></script>
|
||||||
<script src="{{ static('core/js/jquery.datetimepicker.full.min.js') }}"></script>
|
<script src="{{ static('core/js/jquery.datetimepicker.full.min.js') }}"></script>
|
||||||
|
@ -33,10 +33,6 @@
|
|||||||
|
|
||||||
// Custom markdown parser
|
// Custom markdown parser
|
||||||
function customMarkdownParser(plainText, preview) {
|
function customMarkdownParser(plainText, preview) {
|
||||||
// Wait for jquery to load
|
|
||||||
var waitForJquery = setInterval(function () {
|
|
||||||
if (typeof $ != 'undefined'){
|
|
||||||
clearInterval(waitForJquery)
|
|
||||||
$.ajax({
|
$.ajax({
|
||||||
url: "{{ markdown_api_url }}",
|
url: "{{ markdown_api_url }}",
|
||||||
method: "POST",
|
method: "POST",
|
||||||
@ -45,8 +41,6 @@
|
|||||||
preview.innerHTML = msg;
|
preview.innerHTML = msg;
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
}, 10);
|
|
||||||
}
|
|
||||||
|
|
||||||
// Pretty markdown input
|
// Pretty markdown input
|
||||||
var simplemde = new SimpleMDE({
|
var simplemde = new SimpleMDE({
|
||||||
|
Loading…
Reference in New Issue
Block a user