diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/clubs/clubs-add-modify.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/clubs/clubs-add-modify.tt index 8d89d44b4d..6a2b51a184 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/clubs/clubs-add-modify.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/clubs/clubs-add-modify.tt @@ -73,12 +73,12 @@
  • - +
  • - +
  • diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/ill/ill-requests.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/ill/ill-requests.tt index 759c9b9605..fb5a645dc7 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/ill/ill-requests.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/ill/ill-requests.tt @@ -73,19 +73,19 @@
  • - +
  • - +
  • - +
  • - +
  • diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/labels/search.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/labels/search.tt index a6f905d2ec..aee3f2ffc7 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/labels/search.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/labels/search.tt @@ -88,16 +88,17 @@ to add to Batch [% batch_id | html %]
      -
    1. - - -
      [% INCLUDE 'date-format.inc' %]
      -
    2. -
    3. - - -
      [% INCLUDE 'date-format.inc' %]
      -
    +
  • + + +
    [% INCLUDE 'date-format.inc' %]
    +
  • +
  • + + +
    [% INCLUDE 'date-format.inc' %]
    +
  • +
    Cancel
    diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/pos/register.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/pos/register.tt index bdef70e02a..b3f4a43536 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/pos/register.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/pos/register.tt @@ -160,9 +160,9 @@
    1. - + - + [% INCLUDE 'date-format.inc' %]
    @@ -471,23 +471,6 @@ } ] }, [], 1); - - $(document).ready(function() { - // http://jqueryui.com/demos/datepicker/#date-range - var dates = $( "#from, #to" ).datepicker({ - changeMonth: true, - numberOfMonths: 1, - onSelect: function( selectedDate ) { - var option = this.id == "from" ? "minDate" : "maxDate", - instance = $( this ).data( "datepicker" ); - date = $.datepicker.parseDate( - instance.settings.dateFormat || - $.datepicker._defaults.dateFormat, - selectedDate, instance.settings ); - dates.not( this ).datepicker( "option", option, date ); - } - }); - }); [% END %] diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/suggestion/suggestion.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/suggestion/suggestion.tt index 416623a846..ad00aff2ae 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/suggestion/suggestion.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/suggestion/suggestion.tt @@ -500,7 +500,7 @@ - [% INCLUDE 'date-format.inc' %] + [% INCLUDE 'date-format.inc' %] @@ -517,7 +517,7 @@ - [% INCLUDE 'date-format.inc' %] + [% INCLUDE 'date-format.inc' %] @@ -547,7 +547,7 @@
  • - [% INCLUDE 'date-format.inc' %] + [% INCLUDE 'date-format.inc' %]
  • diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/tags/review.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/tags/review.tt index 40e53f4438..31bad4581e 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/tags/review.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/tags/review.tt @@ -230,11 +230,11 @@ tr > td input,td input[type="submit"] { font-size: 85%; padding: 1px; }
  • - +
    [% INCLUDE 'date-format.inc' %]
    - +
    [% INCLUDE 'date-format.inc' %]
  • diff --git a/koha-tmpl/intranet-tmpl/prog/js/ill-list-table.js b/koha-tmpl/intranet-tmpl/prog/js/ill-list-table.js index abd01861a7..2c39ad7aba 100644 --- a/koha-tmpl/intranet-tmpl/prog/js/ill-list-table.js +++ b/koha-tmpl/intranet-tmpl/prog/js/ill-list-table.js @@ -335,6 +335,32 @@ $(document).ready(function() { $('#addcomment').toggleClass('content_hidden'); }); + var illfilter_dateplaced_start = $("#illfilter_dateplaced_start").flatpickr({ + onClose: function( selectedDates, dateText, instance) { + validate_date( selectedDates, instance ); + illfilter_dateplaced_end.set('minDate', selectedDates[0]); + } + }); + + var illfilter_dateplaced_end = $("#illfilter_dateplaced_end").flatpickr({ + onClose: function( selectedDates, dateText, instance) { + validate_date( selectedDates, instance ); + }, + }); + + var illfilter_datemodified_start = $("#illfilter_datemodified_start").flatpickr({ + onClose: function( selectedDates, dateText, instance) { + validate_date( selectedDates, instance ); + illfilter_datemodified_end.set('minDate', selectedDates[0]); + } + }); + + var illfilter_datemodified_end = $("#illfilter_datemodified_end").flatpickr({ + onClose: function( selectedDates, dateText, instance) { + validate_date( selectedDates, instance ); + }, + }); + // Filter partner list // Record the list of all options var ill_partner_options = $('#partners > option'); @@ -498,10 +524,10 @@ $(document).ready(function() { // Custom date range filtering $.fn.dataTable.ext.search.push(function(settings, data, dataIndex) { - var placedStart = $('#illfilter_dateplaced_start').datepicker('getDate'); - var placedEnd = $('#illfilter_dateplaced_end').datepicker('getDate'); - var modifiedStart = $('#illfilter_datemodified_start').datepicker('getDate'); - var modifiedEnd = $('#illfilter_datemodified_end').datepicker('getDate'); + var placedStart = illfilter_dateplaced_start.selectedDates[0]; + var placedEnd = illfilter_dateplaced_end.selectedDates[0]; + var modifiedStart = illfilter_datemodified_start.selectedDates[0]; + var modifiedEnd = illfilter_datemodified_end.selectedDates[0]; var rowPlaced = data[14] ? new Date(data[14]) : null; var rowModified = data[16] ? new Date(data[16]) : null; var placedPassed = true;