Commit Graph

2506 Commits

Author SHA1 Message Date
Victor Grousset/tuxayo efaf05e194 Update release notes for 20.05.18 release
Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net>
2021-12-01 00:57:58 +01:00
Victor Grousset/tuxayo 2a43565529 Fix translations for Koha 20.05.18
Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net>
2021-12-01 00:27:07 +01:00
Koha translators aaa856c643 Translation updates for Koha 20.05.18
Since a bug delayed the release, I might as well update again the
translations

Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net>
2021-12-01 00:22:19 +01:00
Victor Grousset/tuxayo a2b196ba9e Fix translations for Koha 20.05.18
Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net>
2021-11-25 00:42:41 +01:00
Koha translators 9e538951eb Translation updates for Koha 20.05.18
Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net>
2021-11-25 00:16:06 +01:00
Victor Grousset/tuxayo 59385aa9a9 Update release notes for 20.05.17 release
Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net>
2021-10-27 21:18:28 +02:00
Victor Grousset/tuxayo a693f5c9fe Fix translations for Koha 20.05.17
Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net>
2021-10-27 20:50:31 +02:00
Koha translators bcf37dd66e Translation updates for Koha 20.05.17
Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net>
2021-10-27 20:23:40 +02:00
Victor Grousset/tuxayo ab9f129167 Update release notes for 20.05.16 release
Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net>
2021-09-24 00:54:41 +02:00
Victor Grousset/tuxayo 8a6c6ffde0 Fix translations for Koha 20.05.16
Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net>
2021-09-23 22:33:58 +02:00
Koha translators 68d2328695 Translation updates for Koha 20.05.16
Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net>
2021-09-23 21:13:11 +02:00
Victor Grousset/tuxayo 2da3ce99b1 Update release notes for 20.05.15 release
Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net>
2021-08-24 21:40:05 +02:00
Victor Grousset/tuxayo c48929d1b6 Fix translations for Koha 20.05.15
Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net>
2021-08-24 21:14:56 +02:00
Koha translators 17bbd20c4b Translation updates for Koha 20.05.15
Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net>
2021-08-24 20:58:57 +02:00
Victor Grousset/tuxayo a1c06af7ce Update release notes for 20.05.14 release
Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net>
2021-07-24 00:36:27 +02:00
Victor Grousset/tuxayo 3cefa506bd Fix translations for Koha 20.05.14
Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net>
2021-07-24 00:24:16 +02:00
Koha translators f939017d65 Translation updates for Koha 20.05.14
Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net>
2021-07-23 22:14:15 +02:00
Victor Grousset/tuxayo 4206cf976d Update release notes for 20.05.13 release
Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net>
2021-06-25 01:21:23 +02:00
Victor Grousset/tuxayo 80e66a2358 Fix translations for Koha 20.05.13
Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net>
2021-06-25 00:07:24 +02:00
Koha translators 43a64ae871 Translation updates for Koha 20.05.13
Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net>
2021-06-24 19:24:06 +02:00
Victor Grousset/tuxayo 3b609ef26f Bug 28503: REVERT ALL - see ticket
Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net>
2021-06-22 07:21:59 +02:00
Nick Clemens d538300cb6 Bug 28503: Unit tests
Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
(cherry picked from commit a4cdeaae3f)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
(cherry picked from commit 77515dbb4d)
Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net>
2021-06-22 04:37:05 +02:00
Jonathan Druart f67344e523 Bug 28487: Fallback to default template in overdue_notices
There is no fallback to the "default" language if there is no
language-specific template for the lang of the patron.

I am not really sure why we are not using GetPreparredLetter here (which
defaults), but this needs to be backported into all stable branches and
so as small as possible.

Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
(cherry picked from commit 09fcc66ab8)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
(cherry picked from commit 0f9066903e)
Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net>
2021-06-22 03:03:47 +02:00
Andrew Fuerste-Henry 167eb03a00 Update release notes for 20.05.12 release
Signed-off-by: Andrew Fuerste-Henry <andrew@bywatersolutions.com>
2021-05-25 15:15:57 +00:00
Andrew Fuerste-Henry 9ca21221b6 Translation fixes for 20.05.12
Signed-off-by: Andrew Fuerste-Henry <andrew@bywatersolutions.com>
2021-05-25 15:06:53 +00:00
Koha translators f98fcd896c Translation updates for Koha 20.05.12
Signed-off-by: Andrew Fuerste-Henry <andrew@bywatersolutions.com>
2021-05-25 11:44:06 -03:00
Nick Clemens cc05aaed8c Bug 15720: Add connexion user and password options to connexion daemon
Currently the connexion daemon does not utilize the user and password passed in the requests, it expects a
user and password to be defined in the config file and for that user to be a valid Koha user with
cataloging permissions.

With that user in place all requests to the daemon are authorized.

As the connections are over TCP we allow defining a new connexion user and password to protect Koha account information.

If not defined current behaviour is preserved. Connexion user and password must both be set it either is set.

Sample config file:
host:
port: 8888
koha:http://localhost:8081
log:/var/log/koha/kohadev/connexion.log
match:ISBN
user:kohauser
password:kohapass
overlay_action:replace
nomatch_action:create_new
item_action:always_add
import_mode:redirect
debug:1

To test:
 1 - Create connexion file and save on the Koha serve
 2 - perl misc/bin/connexion_import_daemon.pl -c /kohadevbox/koha/connexion.cnf
 3 - Ensure the user specified above (connexuser) exists and has edit catalogue permissions
 4 - In another terminal make a request to the server:
        echo -en 'U6turtleA9connexionP5shell00024    a62clear00024   4500' | nc -v localhost 8888
 5 - The request should succeed and record added to batch (probably the import fails, but not important)
 6 - Add to config file
        connexion_user:conuser
 7 - Stop and restart the daemon - it should fail on missing connexion_password
 8 - Comment out connexion_user and add
        connexion_password:conpass
 9 - Stop and restart daemon, it fails on missing connexion_user
10 - Uncomment the user and restart
11 - Make another request
        echo -en 'U6turtleA9connexionP5shell00024    a62clear00024   4500' | nc -v localhost 8888
12 - It fails 'Unauthorized request'
13 - Make another request
        echo -en 'U7conuserA9connexionP7conpass00024    a62clear00024   4500' | nc -v localhost 8888
14 - It succeeds!

Signed-off-by: Allison Blanning <ablanning@hotchkiss.org>

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>

Signed-off-by: Andrew Fuerste-Henry <andrew@bywatersolutions.com>
2021-05-25 14:36:11 +00:00
Nick Clemens cd66aa48de Bug 28255: Follow up to bug 23463 - use item_object in misc/cronjobs/delete_items.pl
This looks like just an assumption that the $item variable was an object

Correct the code to use $item_object

To test:
1 - perl misc/cronjobs/delete_items.pl -where="barcode LIKE '%8'" --commit --verbose
2 - Can't call method "safe_delete" on unblessed reference at /usr/share/koha/bin/cronjobs/delete_items.pl line 67.
3 - Apply patch
4 - Repeat
5 - Success! You deleted a bunch of items

Signed-off-by: David Nind <david@davidnind.com>

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit 423421eb64)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
(cherry picked from commit bac2651c60)

Signed-off-by: Andrew Fuerste-Henry <andrew@bywatersolutions.com>
2021-05-25 14:21:24 +00:00
Nick Clemens a4ae376b4e Bug 28320: Add DB connection check to the SIP SC status message
This patch adds a lookup of the sip user during an SC status, confirming that
our DB ocnnection is working, and that our user is still valid

Additionally, it adds support for SC status to the sip_cli_emulator and adds basic
test coverage for the SC status message

To test:
1 - Apply patch
2 - Restart SP server
3 - perl misc/sip_cli_emulator.pl -a localhost -p 6001 -l CPL -m sc_status_request -su term1 -sp term1
4 - prove -v t/db_dependent/SIP/Message.t

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit d85ae826c6)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
(cherry picked from commit 06a99ac9bb)

Signed-off-by: Andrew Fuerste-Henry <andrew@bywatersolutions.com>
2021-05-25 13:47:33 +00:00
Kyle M Hall 26bb5683bd Bug 27562: itiva notices break if record title contains quotes
itiva has reported to us that quotes in the title of a record cause the
call to not be made to the patron. The fix is to remove quotes from
the title, as quotes are not spoken anyway ( That is, "Queens" and
"Queen's" are pronounced the same ).

Test Plan:
1) Set up itiva to send phone notes
2) Find a record with quotes in the title
3) Trigger an itiva notice ( checkout, checkin, place hold, etc )
   using the itiva outbound cronjob
4) View the CSV, note the title has the quotes in it
5) Apply this patch
6) Repeat steps 2-3
7) View the CSV, note the title contains no quotes!

Signed-off-by: Owen Leonard <oleonard@myacpl.org>

Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit e7aac53e9a)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
(cherry picked from commit 0c1af44112)

Signed-off-by: Andrew Fuerste-Henry <andrew@bywatersolutions.com>
2021-05-25 13:22:46 +00:00
Julian Maurice 4477590792 Bug 24564: Use the same tab as the other subfields within a field
For each subfield added, we check if other subfields exists in the same
field. If that's the case we use the same tab as the first subfield
found.

Test plan:
1. Find a biblio subfield in
   misc/migration_tools/ifla/data/biblio/default.yml that doesn't exist
   in your default biblio MARC framework (or delete one). The field
   should exist and have other subfields with a tab set.
2. Change the tab of all subfields within that field it's different from
   what's in the .yml file
3. Run misc/migration_tools/ifla/update.pl
4. Verify that the subfield has been added and have the same tab as
   others subfields
5. Do the same for authorities (files are in
   misc/migration_tools/ifla/data/auth/)

Signed-off-by: Koha team <koha@univ-lyon.fr>

Signed-off-by: sonia <sonia.bouis@univ-lyon3.fr>
Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net>

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit c74f6848ed)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
(cherry picked from commit 25da495b2d)

Signed-off-by: Andrew Fuerste-Henry <andrew@bywatersolutions.com>
2021-05-25 12:17:41 +00:00
Julian Maurice 6a89c2dd82 Bug 24564: Do not modify the tab of existing subfield in ifla/update.pl
Test plan:
1. Find a biblio subfield in
   misc/migration_tools/ifla/data/biblio/default.yml that you have in
   your default biblio MARC framework (or create one).
2. Change the tab of this subfield so that it's different from what's in
   the .yml file
3. Run misc/migration_tools/ifla/update.pl --force
4. Verify that the tab of this subfield has not been changed.
5. Do the same for authorities (files are in
   misc/migration_tools/ifla/data/auth/)

Signed-off-by: sonia <sonia.bouis@univ-lyon3.fr>
Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net>

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit 2f522d8ad4)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
(cherry picked from commit 1440eb532d)

Signed-off-by: Andrew Fuerste-Henry <andrew@bywatersolutions.com>
2021-05-25 12:17:30 +00:00
Nick Clemens dfe6f4d1e8 Bug 27819: Spurious item deletion errors from delete_records_via_leader.pl
The job reports errors when deleting items.

The issue seems to be that Koha::Object->delete claims in the POD to
return -1, 0, or 1 as a result, but it in fact returns the Object
itself on a successful deletion

The errors are reported as:
ERROR DELETING ITEM 501740: Koha::Item=HASH(0x55ce407a1a78)

To recreate:
 1 - Find or create a record with some items
 2 - Ensure those  items can be deleted (not on loan, etc.)
 3 - Edit the record leader and set position 5 to 'd'
 4 - perl misc/cronjobs/delete_records_via_leader.pl -i -v --confirm
 5 - Deletion succeeds, but reports failure on items
 6 - Apply patch
 7 - Find or create a new record as above, but this time add an
     additional item and check it out to a patron
 8 - perl misc/cronjobs/delete_records_via_leader.pl -i -v
 9 - Test mode should report 1 item to be deleted, one with error
10 - perl misc/cronjobs/delete_records_via_leader.pl -i -v --confirm
11 - One item should be deleted, one item not, record not deleted
12 - check the item in
13 - perl misc/cronjobs/delete_records_via_leader.pl -i -v --confirm
14 - Successful deletion with no error reported

Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit 02a404ef42)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
(cherry picked from commit 92e69e25ee)

Signed-off-by: Andrew Fuerste-Henry <andrew@bywatersolutions.com>
2021-05-24 19:12:52 +00:00
Kyle M Hall b62b66bddc Bug 28221: Script process_message_queue.pl uses Try::Tiny but doesn't 'use' it
The message queue processor has a try/catch block, but does not have a 'use Try::Tiny' line. Because of this the following error ocurrs if an instance has any plugins installed that use the before_send_messages hook:

Can't locate object method "catch" via package "1" (perhaps you forgot to load "1"?) at /usr/share/koha/bin/cronjobs/process_message_queue.pl line 86.

Test Plan:
1) Install a plugin that uses the before_send_messages hook
2) Run the message queue processor
3) Note the error message
4) Apply this patch
5) Run the message queue processor again
6) No error!

Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit 808d9a9f81)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
(cherry picked from commit 5a6afac654)

Signed-off-by: Andrew Fuerste-Henry <andrew@bywatersolutions.com>
2021-05-24 18:32:47 +00:00
Jonathan Druart 4b759ae041 Bug 28028: Remove misc/migration_tools/fix_onloan.pl
There is an obvious error in the script since bug 23463 and it's known
to be broken for 10 years now (since bug 5579). As nobody complains we
can safely remove this script.

Signed-off-by: Joonas Kylmälä <joonas.kylmala@helsinki.fi>

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit c285de9802)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
(cherry picked from commit 689e3ac5fc)

Signed-off-by: Andrew Fuerste-Henry <andrew@bywatersolutions.com>
2021-05-24 15:41:10 +00:00
Andrew Fuerste-Henry 2c3f6584e7 Update release notes for 20.05.11 release
Signed-off-by: Andrew Fuerste-Henry <andrew@bywatersolutions.com>
2021-04-26 19:46:05 +00:00
Andrew Fuerste-Henry b63fd5eb52 Translation fix again for 20.05.11
Signed-off-by: Andrew Fuerste-Henry <andrew@bywatersolutions.com>
2021-04-26 19:36:41 +00:00
Andrew Fuerste-Henry d77db4732e Fix translations for 20.05.11 2021-04-26 19:32:24 +00:00
Koha translators 33b7355e54 Translation updates for Koha 20.05.11 2021-04-26 15:18:10 -03:00
Fridolin Somers 5b39a9ecdf Bug 27656: misc/cronjobs/longoverdue.pl better error message
There are two ways of configuring misc/cronjobs/longoverdue.pl :
use --lost arg or system preferencies DefaultLongOverdueLostValue and DefaultLongOverdueDays.

Actually if you don't use any of it, you get a message :
  "ERROR: No --lost (-l) option defined"
Should also say something about preferencies :
  "ERROR: No --lost (-l) option no system preferences DefaultLongOverdueLostValue/DefaultLongOverdueDays defined"

Test plan:
1) Set empty preferences DefaultLongOverdueLostValue and DefaultLongOverdueDays
2) Run : misc/cronjobs/longoverdue.pl --maxdays 365
3) You see error message
4) Set DefaultLongOverdueLostValue = 1 and DefaultLongOverdueDays = 90
5) Run : misc/cronjobs/longoverdue.pl --maxdays 365
6) You don't see error message

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit 891145130c)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
(cherry picked from commit e7c3e5f81b)

Signed-off-by: Andrew Fuerste-Henry <andrew@bywatersolutions.com>
2021-04-25 16:51:20 +00:00
Nick Clemens ee8177efc7 Bug 26312: (follow-up) Fix passing of exception messages
'error' has special meaning in exceptions so naming the fields:
type, details

Rather than only dealing with a single exception type, we generically
get the ES exception info and pass it up.

I could not recreate timeout still, however, I simply restarted the
ES docker during commit stage to cause NoNodes exceptions

Signed-off-by: Joonas Kylmälä <joonas.kylmala@helsinki.fi>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit cc8787bf87)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
(cherry picked from commit 74284f4ddb)

Signed-off-by: Andrew Fuerste-Henry <andrew@bywatersolutions.com>
2021-04-25 15:23:38 +00:00
Nick Clemens a60a3b26d7 Bug 26312: Catch ES Client errors, log, and continue indexing when error encountered
This catches a timeout response from the ES server, logs this, and continues the indexing

To test:
1 - perl misc/search_tools/rebuild_elasticsearch.pl
2 - Make the ES server timeout (I don't have good instruction yet)
3 - Watch the job crash
4 - Apply patches
5 - perl misc/search_tools/rebuild_elasticsearch.pl
6 - Make the server timeout
7 - Note the job reports failed commit, and continues

Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Joonas Kylmälä <joonas.kylmala@helsinki.fi>

Bug 26312: (follow-up) Reset buffers even if commit fails

Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Joonas Kylmälä <joonas.kylmala@helsinki.fi>

Bug 26312: (follow-up) Fix whitespace and missing semicolon

Signed-off-by: Joonas Kylmälä <joonas.kylmala@helsinki.fi>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit 72e6999db7)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
(cherry picked from commit d78690a0ab)

Signed-off-by: Andrew Fuerste-Henry <andrew@bywatersolutions.com>
2021-04-25 15:23:27 +00:00
Jonathan Druart d373a884bf Bug 27963: (bug 23463 follow-up) Fix touch_all_items.pl
This script is used to fix inconsistencies in the items table. Prior to
bug 23463, ModItem dealt with that.

We need to make some attributes as dirty to make sure the
Koha::Item->store method will fix them.

Test plan:
Be familiar with how touch_all_items is supposed to work and confirm
that the different inconsistencies are fixed.

Signed-off-by: Joonas Kylmälä <joonas.kylmala@helsinki.fi>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit 8f071b01f5)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
(cherry picked from commit 8244792f26)

Signed-off-by: Andrew Fuerste-Henry <andrew@bywatersolutions.com>
2021-04-24 12:32:31 +00:00
Andrew Fuerste-Henry 9bbd9bf28b Update release notes for 20.05.10 release
Signed-off-by: Andrew Fuerste-Henry <andrew@bywatersolutions.com>
2021-03-23 20:44:14 +00:00
Andrew Fuerste-Henry b78ebf3609 Translation fixes for 20.05.10
Signed-off-by: Andrew Fuerste-Henry <andrew@bywatersolutions.com>
2021-03-23 19:56:27 +00:00
Koha translators 5f7c46aade Translation updates for Koha 20.05.10
Signed-off-by: Andrew Fuerste-Henry <andrew@bywatersolutions.com>
2021-03-23 16:27:32 -03:00
Nick Clemens 104c886213 Bug 27835: (follow-up) Update language, remove warn, add feedback
This patch:
 - Updates lanugage to be clearer 'ChargeFinesOnClosedDays' vs 'ChargeFinesOnCloseDay'
 - Removes a stary warn
 - Add an 'updated' counter and provides feedback in fines.pl

Test plan:
 0 - Apply patches, updatedatabase
 1 - set finesCalendar to 'ignore', ChargeFinesOnClosedDays to "Don't charge"
 2 - Checkout an item due yesterday
 3 - Ensure circ rules have a fine amount and interval set
 4 - Make today a holiday
 5 - perl misc/cronjobs/fines.pl -v
 6 - 0 updated
 7 - ChargeFinesOnClosedDays to "Charge"
 8 - perl misc/cronjobs/fines.pl -v
 9 - 1 updated
10 - set fines calendar to 'use'
11 - perl misc/cronjobs/fines.pl -v
12 - 1 updated (NOTE: This is wrong maybe, but handle on another bug)
13 - set ChargeFinesOnClosedDays to "Don't charge"
14 - perl misc/cronjobs/fines.pl -v
12 - 0 updated

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit deb2f6317a)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
(cherry picked from commit 3c73048dbc)

Signed-off-by: Andrew Fuerste-Henry <andrew@bywatersolutions.com>
2021-03-23 19:03:14 +00:00
Jonathan Druart 54b35cab23 Bug 27835: Add a syspref to control fines calculation on closed days
Bug 27180 added a patch to not update fines on holidays if finesCalendar was set to ignore.
At least it's what it advertised, but not what it did.

It seems that we need to add a new pref to control the calculation of
fines on closed days to answer the different use cases.

Test plan:
With this patch applied you can run the fines.pl cronjob and play with
the new pref ChargeFinesOnCloseDay to generate fines on close days.

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 151966d096)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
(cherry picked from commit 513fb7fb68)

Signed-off-by: Andrew Fuerste-Henry <andrew@bywatersolutions.com>
2021-03-23 19:03:02 +00:00
Jonathan Druart 716e3f482d Bug 27835: Revert "Bug 27180: (follow-up) Remove unused %is_holiday"
This reverts commit a26d529a2b.

Revert "Bug 27180: Update fines on holidays"

This reverts commit 80e1b4e66f.

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 1c4b4cbd91)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
(cherry picked from commit 0cdd5ec6cd)

Signed-off-by: Andrew Fuerste-Henry <andrew@bywatersolutions.com>
2021-03-23 19:02:40 +00:00
Jonathan Druart 56a9dcd48b Bug 7806: [20.05] Fix remaining occurrences of 0000-00-00
We should remove all SQL queries that contain 0000-00-00 and finally
assume we do not longer have such value in our DB (for date type)

We already dealt with such values in previous update DB entries.
The 2 added by this one haven't been replaced already.

The code will now assume that either a valid date exist, or NULL/undef.

Test plan:
QA review is needed and test of the different places where code is
modified.

Not sure about the change from reports/issues_avg_stats.pl

Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>

Signed-off-by: Andrew Fuerste-Henry <andrew@bywatersolutions.com>
2021-03-08 14:26:22 +00:00