Commit Graph

2083 Commits

Author SHA1 Message Date
Wainui Witika-Park 31991dfbf4 Increment version for 19.11.21 release
Signed-off-by: Wainui Witika-Park <wainuiwitikapark@catalyst.net.nz>
2021-08-25 00:47:42 +00:00
Wainui Witika-Park 0160075ee5 Increment version for 19.11.20 release
Signed-off-by: Wainui Witika-Park <wainuiwitikapark@catalyst.net.nz>
2021-07-22 11:19:06 +00:00
Wainui Witika-Park 3df14a7f6d Increment version for 19.11.19 release
Signed-off-by: Wainui Witika-Park <wainuiwitikapark@catalyst.net.nz>
2021-06-27 05:13:49 +00:00
Wainui Witika-Park 21b3c012eb Revert "Increment version for 19.11.19 release"
This reverts commit f2cc49863d.
2021-06-27 04:13:52 +00:00
Wainui Witika-Park f2cc49863d Increment version for 19.11.19 release
Signed-off-by: Wainui Witika-Park <wainuiwitikapark@catalyst.net.nz>
2021-06-21 23:30:17 +00:00
Victor Grousset/tuxayo 9284d09eec Increment version for 19.11.18 release
Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net>
2021-05-25 17:17:07 +02:00
Victor Grousset/tuxayo a954906de7 Increment version for 19.11.17 release
Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net>
2021-04-26 17:21:56 +02:00
Victor Grousset/tuxayo 1b824d62d0 Increment version for 19.05.16 release
Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net>
2021-03-24 00:43:04 +01:00
Jonathan Druart c5f788fa22 Bug 27821: Make sanitize_zero_date support datetime and timestamp
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit 3e3803ee20)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
(cherry picked from commit 3652f652d2)

Signed-off-by: Andrew Fuerste-Henry <andrew@bywatersolutions.com>
(cherry picked from commit 244d8924d1)
Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net>
2021-03-22 16:25:09 +01:00
Martin Renvoize 73e54648df Bug 26997: (QA follow-up) Fix Typo
Feel free to squash this ;)

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 63e3311b10)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
(cherry picked from commit faec602d3e)

Signed-off-by: Andrew Fuerste-Henry <andrew@bywatersolutions.com>
(cherry picked from commit 2fcda64855)
Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net>
2021-03-18 21:08:07 +01:00
Jonathan Druart 7ee274001b Bug 26997: CAST AS CHAR to prevent the error
To prevent the DBMS to fail on 0000-00-00 we can cast it as a char and
compare.
This patch also moves to a subroutine, in case we need to adjust (or
reuse) it later.

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 0a40b4bb50)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
(cherry picked from commit 9327130853)

Signed-off-by: Andrew Fuerste-Henry <andrew@bywatersolutions.com>
(cherry picked from commit d4a5f258b6)
Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net>
2021-03-18 21:07:04 +01:00
Jonathan Druart 7e3bf82654 Bug 26997: Fix upgrade process under MySQL 8
If you are coming from an old version of Koha, you may face an upgrade
error for the SQL query using 0000-00-00.
The idea was to fix it, but actually the DBMS will raise an error (not
blocking the upgrade process however).

We can hide them to not cause confusion

Errors are like:
DBD::mysql::db do failed: Incorrect date value: '0000-00-00' for column 'suggesteddate' at row 1 [for Statement "UPDATE suggestions SET suggesteddate = '1970-01-01' WHERE suggesteddate = '0000-00-00';"] at /kohadevbox/koha/installer/data/mysql/updatedatabase.pl line 23312.

Test plan:
Checkout an old version of Koha (3.20, not older)
Insert a dump, install Koha
Checkout a recent version of Koha, apply the patch (or use master)
Execute the upgrade process
You should not see the errors

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 3c087bc216)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
(cherry picked from commit da58f3e2c5)

Signed-off-by: Andrew Fuerste-Henry <andrew@bywatersolutions.com>
(cherry picked from commit c720acc3c9)
Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net>
2021-03-18 21:02:41 +01:00
Victor Grousset/tuxayo 976cd863ec Increment version for 19.11.15 release
Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net>
2021-02-23 22:33:02 +01:00
Victor Grousset/tuxayo d0c6983692 Increment version for 19.11.14 release
Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net>
2021-01-23 01:21:02 +01:00
Andrew Fuerste-Henry a4d35d3de8 Bug 27252: DBRev 19.11.13.001
Signed-off-by: Andrew Fuerste-Henry <andrew@bywatersolutions.com>
(cherry picked from commit f40b7c2b6c)
Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net>
2021-01-17 21:50:49 +01:00
Victor Grousset/tuxayo 684408c759 Increment version for 19.11.13 release
Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net>
2021-01-06 19:46:15 +01:00
Aleisha Amohia fd6ccb4a54 Increment version for 19.11.12 release
Signed-off-by: Aleisha Amohia <aleishaamohia@hotmail.com>
2020-11-24 13:45:39 +13:00
Aleisha Amohia 026316d551 Bug 18050: DBRev 19.11.11.002
Signed-off-by: Aleisha Amohia <aleishaamohia@hotmail.com>
2020-11-17 17:56:18 +13:00
Aleisha Amohia 70348d8d4d Bug 26569: DBRev 19.11.11.001
Signed-off-by: Aleisha Amohia <aleishaamohia@hotmail.com>
2020-11-17 17:32:14 +13:00
Aleisha Amohia 476865d0fe Increment version for 19.11.11 release
Signed-off-by: Aleisha Amohia <aleishaamohia@hotmail.com>
2020-10-28 09:15:11 +13:00
Aleisha Amohia 17c44ac5ca Bug 18958: DBRev 19.11.10.001
Signed-off-by: Aleisha Amohia <aleishaamohia@hotmail.com>
2020-10-20 14:36:25 +13:00
Aleisha Amohia c24769ce8b Increment version for 19.11.10 release
Signed-off-by: Aleisha Amohia <aleishaamohia@hotmail.com>
2020-09-22 10:54:45 +12:00
Aleisha Amohia ec714bc6ce Bug 25958: DBRev 19.11.09.001
Signed-off-by: Aleisha Amohia <aleishaamohia@hotmail.com>
2020-09-09 21:51:23 +12:00
Aleisha Amohia b06292b883 Increment version for 19.11.09 release
Signed-off-by: Aleisha Amohia <aleishaamohia@hotmail.com>
2020-08-25 09:52:50 +12:00
Aleisha Amohia be3ab938d8 Bug 26070: DBRev 19.11.08.003
Signed-off-by: Aleisha Amohia <aleishaamohia@hotmail.com>
2020-08-07 14:22:05 +12:00
Aleisha Amohia a2139daaa5 Bug 24379: DBRev 19.11.08.002
Signed-off-by: Aleisha Amohia <aleishaamohia@hotmail.com>
2020-08-05 12:07:40 +12:00
Nick Clemens f4899bafe3 Bug 24379: Make login_attempts not nullable
While the column defaults to 0 in Koha::Object->store we set to NULL if NULLABLE

When trying to reset a patrons password we check that the account is not administratively locked:
login_attempts != -1

This query does not return rows where login_attempts IS NULL. It will return accounts where login_attempts = 0

Let's default to 0 like we intend

To test:
1 - Create a new patron
2 - Note their login_attempts is NULL
    SELECT login_attempts FROM borrowers ORDER BY borrowernumber DESC LIMIT 1
3 - Enable  OpacResetPassword
4 - Attempt to reset password before logging in, you cannot
5 - Apply patch, updatedatabase, restart_all, update schema
6 - Create another patron
7 - Their login attempts should be 0
8 - Attempt to reset password, it works!

Bug 24379: Fix the test

First we create a patron using TestBuilder to get a hashref of valid
info. Then we delete it and create a new patron using Koha::Patron->new
Once stored, we should call discard_changes to make the calculated
values available in the currenct object.

Bug 24379: Don't drop default of 0 for login attempts

When moving the column we drop the default, this means that DBs upgraded form earlier versions
get the wrong values set

To test:
1 - Checkout 16.11.x
2 - Reset all
3 - Checkout master
4 - updatedatabase
5 - SHOW CREATE TABLE borrowers;
6 - Note the column login_attempts defaults to NULL
7 - Apply patch(es)
8 - Repeat
9 - Now it defaults ot 0 (and has NOT NULL if applied all)

Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit 7bb31cffae)

Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
(cherry picked from commit 6d675b61ad)

Signed-off-by: Aleisha Amohia <aleishaamohia@hotmail.com>
2020-08-05 12:04:55 +12:00
Aleisha Amohia adf8e12eb1 Bug 25709: DBRev 19.11.08.001 - fixing output message 2020-08-05 11:46:48 +12:00
Aleisha Amohia 54f653d270 Bug 25709: DBRev 19.11.08.001
Signed-off-by: Aleisha Amohia <aleishaamohia@hotmail.com>
2020-07-31 03:39:32 +12:00
Aleisha Amohia 68af6695b0 Increment version for 19.11.08 release
Signed-off-by: Aleisha Amohia <aleishaamohia@hotmail.com>
2020-07-22 12:53:18 +12:00
Aleisha Amohia 4f6b3c4a61 [19.11.x] Bug 25858: Use bitwise OR for setting a bit in borrowers.flag
Signed-off-by: Aleisha Amohia <aleishaamohia@hotmail.com>
2020-07-16 16:24:38 +12:00
Aleisha Amohia 6d6132777b [19.11.x] Bug 25858: Don't attempt to set flag if already set
Signed-off-by: Aleisha Amohia <aleishaamohia@hotmail.com>
2020-07-16 16:23:07 +12:00
Aleisha Amohia 7efb135dfb Bug 24986: DBRev 19.11.07.001
Signed-off-by: Aleisha Amohia <aleishaamohia@hotmail.com>
2020-07-16 16:14:40 +12:00
Aleisha Amohia e5785ec8db Increment version for 19.11.07 release
Signed-off-by: Aleisha Amohia <aleishaamohia@hotmail.com>
2020-06-23 09:39:05 +12:00
Aleisha Amohia d411d6b47c [19.11.x] Bug 25045: (follow-up) Fix typo adding the RESTPublicAnonymousRequests syspref
Signed-off-by: Aleisha Amohia <aleishaamohia@hotmail.com>
2020-06-22 10:19:38 +12:00
Martin Renvoize f6589ccf90 Bug 25045: (RM follow-up) Correction to updatedatebase.pl
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 733874e24e)

Signed-off-by: Aleisha Amohia <aleishaamohia@hotmail.com>
2020-06-22 10:11:13 +12:00
Martin Renvoize bdb8edb5b5 Bug 25045: (RM follow-up) Add the RESTPublicAnonymousRequests syspref
The atomic update alos included a quoting mistake

Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 19a241c131)

Signed-off-by: Aleisha Amohia <aleishaamohia@hotmail.com>
2020-06-22 10:10:59 +12:00
Aleisha Amohia 8b31591912 Bug 25045: DBRev 19.11.06.001
Signed-off-by: Aleisha Amohia <aleishaamohia@hotmail.com>
2020-06-22 10:09:42 +12:00
Tomas Cohen Arazi f409035865 Bug 25707: (QA follow-up) Clearer message about what's going on
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit f32825ae26)

Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
(cherry picked from commit 59adc02b74)

Signed-off-by: Aleisha Amohia <aleishaamohia@hotmail.com>
2020-06-17 11:27:58 +12:00
Kyle M Hall f7e5fddb86 Bug 25707: (bug 11529 follow-up) Do not update marc mappings, print old mappings to upgrade log
This patch removes the update of marc frameworks from the updatedatabase script and warns the
"MARC to Keyword" (fieldmappings ) to the upgrade log so they can be replaced manually

Signed-off-by: David Cook <dcook@prosentient.com.au>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit e239e13bc9)

Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
(cherry picked from commit 9d34cfb775)

Signed-off-by: Aleisha Amohia <aleishaamohia@hotmail.com>
2020-06-17 11:27:44 +12:00
Joy Nelson d3a009efcc Increment version for 19.11.06 release
Signed-off-by: Joy Nelson <joy@bywatersolutions.com>
2020-05-21 22:23:33 +00:00
Joy Nelson dbcae29fa7 Bug 24854: DBRev correction
Signed-off-by: Joy Nelson <joy@bywatersolutions.com>
2020-05-20 17:11:03 +00:00
Joy Nelson a17ea63d02 Bug 24854: DBRev 19.11.05.007
Signed-off-by: Joy Nelson <joy@bywatersolutions.com>
2020-05-20 14:59:21 +00:00
Martin Renvoize 27a11c566f Bug 24994: Correct DB Updates
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>

Signed-off-by: Joy Nelson <joy@bywatersolutions.com>
2020-05-19 22:12:06 +00:00
Joy Nelson 1e2cb846ec Bug 25478: DBRev 19.11.05.006
Signed-off-by: Joy Nelson <joy@bywatersolutions.com>
2020-05-13 18:54:56 +00:00
Martin Renvoize 8ac1f30c91 Bug 25478: (25389 backport) Correct stray cases of LOST_RETURNED
The original DB update for bug 22563 incorrectly mapped CR to
LOST_RETURNED as aposed to LOST_RETURN.  This patch catches such cases
and updates them in the update for bug 23805

(cherry picked from commit 483e40d223)
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>

Signed-off-by: Joy Nelson <joy@bywatersolutions.com>
2020-05-13 16:55:09 +00:00
Martin Renvoize 57bf9fc48d Bug 25478: (25389 backport) Correct original DB update for bug 22563
(cherry picked from commit ed564837a6)
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>

Signed-off-by: Joy Nelson <joy@bywatersolutions.com>
2020-05-13 16:55:09 +00:00
Joy Nelson 8048acf225 Bug 25184: DBRev 19.11.05.005
Signed-off-by: Joy Nelson <joy@bywatersolutions.com>
2020-05-11 21:52:39 +00:00
Joy Nelson 0e3ad130ea Bug 23081: DBRev 19.11.05.004
Signed-off-by: Joy Nelson <joy@bywatersolutions.com>
2020-05-08 21:22:48 +00:00
Nick Clemens 017d03b741 Bug 24840: [19.11.x] Replace DateTime->now with dt_from_string
We should use Koha::DateUtils instead of Date::Time directly

This patch simplay replaces calls to now() with a call to dt_from_string()
which does effectively the same thing.

Probably reading the code and verifying changes is sufficient but...

To test:
1 - confirm the files all compile
2 - confirm all tests pass
3 - confirm Koha still works

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

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

Bug 24840: Catch some further cases of DateTime->now

This patch corrects a few additional cases where DateTime->now is called
directly instead of via Koha::DateUtils.

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

Signed-off-by: Joy Nelson <joy@bywatersolutions.com>
2020-05-07 17:17:12 +00:00