For some reason we don't appear to limit the date selection yet available in the OPAC 'Hold starts on date'.. it should only allow future dates.
Created attachment 163309 [details] [review] Bug 36341: Add futureinclusive to future holds This patch adds the flatpickr-futureinclusive data to the input field for "Hold starts on date" in the OPAC. We also add 'flatpickr-future' data to the input field for expiration date as it also doesn't make sense to allow this to be a past data either. Test plan 1) Attempt to place a hold on an item from the OPAC 2) Expand the 'Show more options' dropdown 3) Note that without the patch 'Hold not needed after' allows setting to a date in the past. 4) Enable `AllowHoldDateInFuture` and `OPACAllowHoldDateInFuture` system preferences 5) The 'Hold starts on date' option should now appear if you refresh your hold placing page in the OPAC. 6) Note that the above input also allows setting a past date 7) Apply patch 8) Neith input should allow past dates now.
Created attachment 164218 [details] [review] Bug 36341: Add futureinclusive to future holds This patch adds the flatpickr-futureinclusive data to the input field for "Hold starts on date" in the OPAC. We also add 'flatpickr-future' data to the input field for expiration date as it also doesn't make sense to allow this to be a past data either. Test plan 1) Attempt to place a hold on an item from the OPAC 2) Expand the 'Show more options' dropdown 3) Note that without the patch 'Hold not needed after' allows setting to a date in the past. 4) Enable `AllowHoldDateInFuture` and `OPACAllowHoldDateInFuture` system preferences 5) The 'Hold starts on date' option should now appear if you refresh your hold placing page in the OPAC. 6) Note that the above input also allows setting a past date 7) Apply patch 8) Neith input should allow past dates now. Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Created attachment 164219 [details] [review] Bug 36341: (QA follow-up) Use future inclusive on staff side too
Trivial fix, PQA
Pushed for 24.05! Well done everyone, thank you!
Created attachment 165721 [details] [review] Bug 36341: (follow-up) Fix missing Date_from_syspref It appears this bug introduces the first actual use of this function in the OPAC and thus exposes that bug 31261 didn't fully port the Date_from_syspref from the intranet.
Follow-up will be pushed to main today.
Pushed to 23.11.x for 23.11.06
Backported to 23.05.x for upcoming 23.05.12
(In reply to Martin Renvoize (ashimema) from comment #0) > For some reason we don't appear to limit the date selection yet available in > the OPAC 'Hold starts on date'.. it should only allow future dates. I hope you mean: future plus today