Koha/C4
Jonathan Druart f1e248fad8 Bug 24159: Move useDaysMode pref to circulation rules
Moving the useDaysMode system preference to a circulation rule will add
much more flexibility in the calculation of the due date.

The initial request was to make hourly loan returned on closed when
(when checked out on the same close day).
To do so we do not want to take into account the calendar.
However the calendar need to be taken into account for other loan item types.

Other scenarios are possible, for instance depending on the branch.

This patchset will add a new "Days mode" column (next to "Loan period")
to the circulation rules page, with the different values of the
"useDaysMode" system preference + a "default" value, to default to the
system preference value.

Test plan:
- Define a long loan item type (like 10 days) that will use the calendar
(or default to the pref value, if the pref is not set to "ignore the
calendar")
- and a hourly loan (like 2 hours) that will ignore the calendar
- Create items with those item types
- Mark today as a closed day
- Check the items out
=> The hourly loan is due the same day
=> The other loan is due on an open day

QA note:
There is the need to force the "days_mode" option when Koha::Calendar is
initiated for the due date calculation. To make sure devs will not
forget it, the methods that need have it defined will throw an
exception.

Sponsored-by: Institute of Technology Carlow
Signed-off-by: Simon Perry <simon.perry@itcarlow.ie>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
2020-06-25 10:51:59 +02:00
..
AuthoritiesMarc Bug 24217: use Modern::Perl for modules when strict is missing 2020-01-03 10:45:46 +00:00
Barcodes Bug 21937: Syspref autoBarcode annual doesn't increment properly barcode 2019-04-19 14:32:36 +00:00
ClassSortRoutine Bug 16011: $VERSION - Remove use vars qw(); 2016-03-24 17:20:39 +00:00
ClassSplitRoutine
Creators Bug 24545: Fix license statements 2020-02-24 13:31:26 +00:00
External Bug 22010: Check preferences for ebook integration 2019-04-30 11:42:51 +00:00
Form Bug 16259: Replace CGI->param with CGI->multi_param in list context - part 2 2016-05-16 17:28:06 +00:00
Heading Bug 24269: Adjust C4::Heading to generate headings from auth tags 2020-02-19 13:33:32 +00:00
ILSDI Bug 24769: (bug 14711 follow-up) Fix typo in parameter name for AddReserve 2020-05-05 11:03:33 +01:00
Installer Bug 24545: Fix license statements 2020-02-24 13:31:26 +00:00
Labels Bug 23514: Split Call Numbers for all layout types 2020-04-14 07:59:11 +01:00
Linker Bug 25189: Don't create authority if results found 2020-06-24 14:31:37 +02:00
Members Bug 20443: Remove extended_attributes_code_value_arrayref AND C4::Members::Attributes 2020-03-23 13:49:22 +00:00
OAI Bug 23084: Replace grep {^$var$} with grep {$_ eq $var} 2020-02-17 10:44:45 +00:00
Output Bug 9978: Replace license header with the correct license (GPLv3+) 2015-04-20 09:59:38 -03:00
Patroncards Bug 23488: Line wrapping doesn't always respect word order in Patron card creator 2020-03-02 09:49:57 +00:00
Reports Bug 22001: execute reports in an eval 2020-03-31 17:48:14 +01:00
Search Bug 24217: use Modern::Perl for modules when strict is missing 2020-01-03 10:45:46 +00:00
Serials
SIP Bug 25805: Return empty strings instead of undef in C4::SIP::ILS::Item::hold_patron_name 2020-06-25 10:39:37 +02:00
Utils Bug 25142: Fix wrong grep logical test 2020-04-27 10:44:49 +01:00
Accounts.pm Bug 24217: use Modern::Perl for modules when strict is missing 2020-01-03 10:45:46 +00:00
Acquisition.pm Bug 24161: Remove GetLateOrders 2020-05-04 09:44:44 +01:00
Auth.pm Bug 23794: Convert OpacMainUserBlock system preference to news block 2020-05-01 08:17:23 +01:00
Auth_cas_servers.yaml.sample Bug 17065 - Rename C4/Auth_cas_servers.yaml.orig 2016-08-08 13:16:36 +00:00
Auth_with_cas.pm Bug 19160: Add POD 2018-03-23 11:45:38 -03:00
Auth_with_ldap.pm Bug 20443: Use search_with_library_limits for attribute types 2020-03-23 13:49:22 +00:00
Auth_with_shibboleth.pm Bug 24199: (bug 23042 follow-up) Prevent t/Auth_with_shibboleth.t to fail randomly 2019-12-10 10:43:20 +00:00
AuthoritiesMarc.pm Bug 22437: (follow-up) Move deletion of merge requests to DelAuthority 2020-05-12 11:02:05 +01:00
BackgroundJob.pm Bug 24217: use Modern::Perl for modules when strict is missing 2020-01-03 10:45:46 +00:00
Barcodes.pm
Biblio.pm Bug 25189: Don't create authority if results found 2020-06-24 14:31:37 +02:00
Boolean.pm Bug 16011: $VERSION - Remove the $VERSION init 2016-03-24 17:20:28 +00:00
Breeding.pm Bug 24052: Rename XSLT_Handler 2020-03-24 10:42:23 +00:00
Budgets.pm Bug 24361: (bug 24217 follow-up) Fix several warnings in C4 modules 2020-01-07 13:59:51 +00:00
Calendar.pm Bug 19475: Don't copy holiday if it already exists in target calendar 2020-04-03 14:26:33 +01:00
Charset.pm
Circulation.pm Bug 24159: Move useDaysMode pref to circulation rules 2020-06-25 10:51:59 +02:00
ClassSortRoutine.pm Bug 16011: $VERSION - Remove comments 2016-03-24 17:20:29 +00:00
ClassSource.pm Bug 15836: Remove deprecated subroutines 2018-11-13 18:56:18 +00:00
ClassSplitRoutine.pm Bug 15836: Add the ability to defined custom methods to split call number in labels 2018-11-13 15:18:22 +00:00
Context.pm Bug 25131: Add C4::Context->needs_install 2020-04-16 19:20:57 +01:00
Contract.pm Bug 24217: use Modern::Perl for modules when strict is missing 2020-01-03 10:45:46 +00:00
CourseReserves.pm Bug 25444: More minor improvements to simplified loop 2020-05-28 17:01:55 +02:00
Creators.pm
Debug.pm Bug 16011: $VERSION - Remove the $VERSION init 2016-03-24 17:20:28 +00:00
Heading.pm Bug 24269: Adjust C4::Heading to generate headings from auth tags 2020-02-19 13:33:32 +00:00
HoldsQueue.pm Bug 25786: Holds Queue building may target the wrong item for item level requests that match holds queue priority 2020-06-18 18:51:58 +02:00
HTML5Media.pm Bug 20783: Use iframe to embed Youtube videos 2020-06-15 10:32:43 +02:00
Images.pm Revert "Bug 21987: Do not generate true color thumbnails if not needed" 2019-11-04 13:21:53 +00:00
ImportBatch.pm Bug 25527: Initialize the logger when required 2020-05-18 15:24:47 +01:00
ImportExportFramework.pm
InstallAuth.pm Bug 4461: Adding user flags for managing OPAC problem reports 2020-04-06 11:18:13 +01:00
Installer.pm Bug 24883: Add POD entry and remove unused variable 2020-03-27 12:11:32 +00:00
ItemCirculationAlertPreference.pm
Items.pm Bug 23081: Revert "Bug 24443: Consider NULL as 0 for issues in items search" 2020-04-27 11:32:56 +01:00
Koha.pm Bug 17845: Remove unused code related to printers 2020-03-10 15:18:27 +00:00
Labels.pm
Languages.pm Bug 20116: Cache language list 2020-04-17 09:24:23 +01:00
Letters.pm Bug 24612: Use the reserve_id to identify a reserve when building a notice 2020-05-22 09:33:17 +01:00
Linker.pm Bug 9978: Replace license header with the correct license (GPLv3+) 2015-04-20 09:59:38 -03:00
Log.pm Bug 21190: Add interfaces parameter to POD in C4::Logs 2020-04-14 16:13:38 +01:00
MarcModificationTemplates.pm Bug 24840: Replace DateTime->now with dt_from_string 2020-04-08 11:54:23 +01:00
Matcher.pm Bug 24735: Remove QueryParser-related code 2020-03-02 11:13:03 +00:00
Members.pm Bug 20443: Remove SearchIdMatchingAttribute 2020-03-23 13:49:21 +00:00
Message.pm Bug 21206: Replace C4::Items::GetItem 2019-02-26 13:24:07 +00:00
NewsChannels.pm Bug 24002: Incorrect DATE value: '00-00-0000' in NewsChannels.pm 2019-11-12 13:49:58 +00:00
Output.pm Bug 11994: OpenSearch plugins needs to be delivered with Content-Type application/opensearchdescription+xml 2020-06-24 14:31:37 +02:00
Overdues.pm Bug 25127: Use Koha::Number::Price->round for comparison 2020-05-01 15:44:55 +01:00
Patroncards.pm Bug 16011: $VERSION - Remove the $VERSION init 2016-03-24 17:20:28 +00:00
Record.pm Bug 24052: Rename XSLT_Handler 2020-03-24 10:42:23 +00:00
Reports.pm Bug 24217: use Modern::Perl for modules when strict is missing 2020-01-03 10:45:46 +00:00
Reserves.pm Bug 25232: Add ability to specify multiple notforloan values to skip 2020-06-25 10:50:02 +02:00
Ris.pm Bug 10306: Core module changes for multiple mappings 2017-12-07 14:44:15 -03:00
RotatingCollections.pm Bug 24299: Record 'RotatingCollection' as a transfer trigger 2020-03-20 15:54:55 +00:00
Scheduler.pm Bug 24217: use Modern::Perl for modules when strict is missing 2020-01-03 10:45:46 +00:00
Scrubber.pm Bug 16011: $VERSION - Remove the $VERSION init 2016-03-24 17:20:28 +00:00
Search.pm Bug 25701: Remove sort on removed field 2020-06-15 10:29:53 +02:00
Serials.pm Bug 21901: Add FK on subscription and serial tables 2020-04-17 09:39:00 +01:00
Service.pm Bug 7550: [QA Follow-up] Resolve param warning from sco-patron-image 2017-05-08 09:00:26 -04:00
ShelfBrowser.pm Bug 22445: Custom cover images - opac shelfbrowser 2019-10-22 15:02:48 +01:00
SMS.pm
SocialData.pm Bug 9978: (followup) Replace license header with the correct license (GPLv3+) 2015-04-20 09:59:43 -03:00
Stats.pm Bug 23084: Replace grep {^$var$} with grep {$_ eq $var} 2020-02-17 10:44:45 +00:00
Suggestions.pm Bug 22784: Add the ability to archive/unarchive a purchase suggestions 2020-04-14 16:19:02 +01:00
Tags.pm Bug 23084: Replace grep {^$var$} with grep {$_ eq $var} 2020-02-17 10:44:45 +00:00
Templates.pm Bug 20538: Remove the need of writing [% KOHA_VERSION %] everywhere 2018-04-13 11:49:44 -03:00
TmplToken.pm Bug 16011: $VERSION - Remove the $VERSION init 2016-03-24 17:20:28 +00:00
TmplTokenType.pm Bug 24217: use Modern::Perl for modules when strict is missing 2020-01-03 10:45:46 +00:00
TTParser.pm Bug 25305: Translation process - Open all files specifying the utf8 encoding 2020-05-04 08:50:07 +01:00
UsageStats.pm Bug 24159: Move useDaysMode pref to circulation rules 2020-06-25 10:51:59 +02:00
XISBN.pm Bug 24217: use Modern::Perl for modules when strict is missing 2020-01-03 10:45:46 +00:00
XSLT.pm Bug 24052: Rename XSLT_Handler 2020-03-24 10:42:23 +00:00