Datepicker replace (#1059)

* replaced jquery-ui-datepicker with bootstrap-datepicker

* removed obsolete static files
This commit is contained in:
ManosKoukoularis
2021-12-02 12:59:36 +02:00
committed by GitHub
parent 701a442d12
commit 6c1dfd2408
26 changed files with 20 additions and 17238 deletions

View File

@ -217,9 +217,11 @@
$( ".datepicker" ).datepicker({
changeMonth: true,
changeYear: true,
maxDate: '+0'
format: "yyyy-mm-dd",
endDate: '+0'
});
$(".datepicker").datepicker("option", "dateFormat", "yy-mm-dd")
// $(".datepicker").datepicker("option", "format", "yy-mm-dd")
});
});
@ -436,7 +438,7 @@
// then initialize it
$('#search-submit').on('click', function() {
if ($('#max').val() === "" || $('#max').val() === undefined)
$('#max').datepicker('setDate', new Date());
$('#max').datepicker('setDate', 'now');
});
$("#history-search-form").submit(function(e){ // ajax call to load results on submition

View File

@ -693,12 +693,12 @@
<script>
$(function() {
// $('#tabs').tabs({
// // add url anchor tags
// activate: function(event, ui) {
// window.location.hash = ui.newPanel.attr('id');
// }
// });
$('#tabs').tabs({
// add url anchor tags
activate: function(event, ui) {
window.location.hash = ui.newPanel.attr('id');
}
});
// re-set active tab (ui)
var activeTabIdx = $('#tabs').tabs('option','active');
$('#tabs li:eq('+activeTabIdx+')').tab('show')

View File

@ -7,15 +7,6 @@
<link rel="icon" href="{{ url_for('static', filename='img/favicon.png') }}">
{% block title %}<title>{{ SITE_NAME }}</title>{% endblock %}
<link rel="stylesheet" href="{{ url_for('static', filename='assets/css/style.css') }}">
<!-- Get jquery UI -->
{% if OFFLINE_MODE %}
<link rel="stylesheet" href="{{ url_for('static', filename='assets/jquery-ui-smooth-datepicker/jquery-ui.js') }}">
<link rel="stylesheet" href="{{ url_for('static', filename='assets/jquery-ui-smooth-datepicker/jquery-ui.css') }}">
<link rel="stylesheet" href="{{ url_for('static', filename='assets/jquery-ui-smooth-datepicker/jquery-ui.structure.css') }}">
<link rel="stylesheet" href="{{ url_for('static', filename='assets/jquery-ui-smooth-datepicker/jquery-ui.theme.css') }}">
{% else %}
<link rel="stylesheet" href="http://ajax.googleapis.com/ajax/libs/jqueryui/1.11.4/themes/smoothness/jquery-ui.css" type="text/css"/>
{% endif %}
<!-- Get Google Fonts we like -->
{% if OFFLINE_MODE %}
<link rel="stylesheet" href="{{ url_for('static', filename='assets/css/source_sans_pro.css') }}">

View File

@ -123,12 +123,12 @@
<!-- TODO: add password and password confirmation comparison check -->
<script>
$(function () {
// $('#tabs').tabs({
// // add url anchor tags
// activate: function (event, ui) {
// window.location.hash = ui.newPanel.attr('id');
// }
// });
$('#tabs').tabs({
// add url anchor tags
activate: function (event, ui) {
window.location.hash = ui.newPanel.attr('id');
}
});
// re-set active tab (ui)
var activeTabIdx = $('#tabs').tabs('option', 'active');
$('#tabs li:eq(' + activeTabIdx + ')').tab('show')