What the title says :-D
Created attachment 88222 [details] [review] Bug 22729: Adapt Koha::Patron(s) and tests This patch adapts the Koha::Patron(s) code to the column change. To test: - Apply this patches - Run: $ kshell k$ prove t/db_dependent/Koha/Patrons.t => SUCCESS: Tests pass! - Sign off :-D
Created attachment 88223 [details] [review] Bug 22729: DBIC update I add this DBIC update because I didn't manage to add the +anonymize => { is_boolean => 1 } change without the schema updating script to bark because of the non-existent column...
Created attachment 88224 [details] [review] Bug 22729: Adapt /patrons controller code to the change This patch makes the controller code aware of the flgAnonymized => anonymized change. To test: - Run $ kshell k$ prove t/db_dependent/api/v1/patrons.t => SUCCESS: Tests pass! - Sign off :-D
Testing here now
Created attachment 88337 [details] [review] Bug 22729: Add dbrev to rename column (incl kohastructure) Speaks for itself. Test plan: Run the dbrev. Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Hmm Running Koha/Patrons.t with perl twice no problem, but running with prove the second time results in a failure. Sql mode ? # Failed test 'With BorrowerLogs and TrackLastPatronActivity we should not spam the logs' # at t/db_dependent/Koha/Patrons.t line 1477. # got: '2' # expected: '1' t/db_dependent/Koha/Patrons.t .. 31/39 # Looks like you failed 1 test of 4.
This should resolve the second prove: diff --git a/Koha/Patron.pm b/Koha/Patron.pm index 6a25d717c1..90c4f38853 100644 --- a/Koha/Patron.pm +++ b/Koha/Patron.pm @@ -752,7 +752,7 @@ sub track_login { return if !$params->{force} && !C4::Context->preference('TrackLastPatronActivity'); - $self->lastseen( dt_from_string() )->store; + $self->lastseen( dt_from_string() )->SUPER::store; } =head3 move_to_deleted Obviously, there is a relation with Koha::Patron's sub store too. Safe to say that it is not directly related to this patch. We should resolve it on a new report. Opened report 22741.
Created attachment 88338 [details] [review] Bug 22729: [DO_NOT_PUSH] DBIC update I add this DBIC update because I didn't manage to add the +anonymize => { is_boolean => 1 } change without the schema updating script to bark because of the non-existent column... Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Created attachment 88339 [details] [review] Bug 22729: Adapt Koha::Patron(s) and tests This patch adapts the Koha::Patron(s) code to the column change. To test: - Apply this patches - Run: $ kshell k$ prove t/db_dependent/Koha/Patrons.t => SUCCESS: Tests pass! - Sign off :-D Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Created attachment 88340 [details] [review] Bug 22729: Adapt /patrons controller code to the change This patch makes the controller code aware of the flgAnonymized => anonymized change. To test: - Run $ kshell k$ prove t/db_dependent/api/v1/patrons.t => SUCCESS: Tests pass! - Sign off :-D Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Marcel, I missed to upload the dbrev patch I originally wrote, and it differs from yours as I made it NOT NULL also.
Created attachment 88349 [details] [review] Bug 22729: DB update
Created attachment 88350 [details] [review] Bug 22729: DB update Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Created attachment 88351 [details] [review] Bug 22729: [DO_NOT_PUSH] DBIC update I add this DBIC update because I didn't manage to add the +anonymize => { is_boolean => 1 } change without the schema updating script to bark because of the non-existent column... Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Created attachment 88352 [details] [review] Bug 22729: Adapt Koha::Patron(s) and tests This patch adapts the Koha::Patron(s) code to the column change. To test: - Apply this patches - Run: $ kshell k$ prove t/db_dependent/Koha/Patrons.t => SUCCESS: Tests pass! - Sign off :-D Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Created attachment 88353 [details] [review] Bug 22729: Adapt /patrons controller code to the change This patch makes the controller code aware of the flgAnonymized => anonymized change. To test: - Run $ kshell k$ prove t/db_dependent/api/v1/patrons.t => SUCCESS: Tests pass! - Sign off :-D Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Created attachment 88692 [details] [review] Bug 22729: DB update Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io> Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Created attachment 88693 [details] [review] Bug 22729: [DO_NOT_PUSH] DBIC update I add this DBIC update because I didn't manage to add the +anonymize => { is_boolean => 1 } change without the schema updating script to bark because of the non-existent column... Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io> Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Created attachment 88694 [details] [review] Bug 22729: Adapt Koha::Patron(s) and tests This patch adapts the Koha::Patron(s) code to the column change. To test: - Apply this patches - Run: $ kshell k$ prove t/db_dependent/Koha/Patrons.t => SUCCESS: Tests pass! - Sign off :-D Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io> Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Created attachment 88695 [details] [review] Bug 22729: Adapt /patrons controller code to the change This patch makes the controller code aware of the flgAnonymized => anonymized change. To test: - Run $ kshell k$ prove t/db_dependent/api/v1/patrons.t => SUCCESS: Tests pass! - Sign off :-D Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io> Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Created attachment 88696 [details] [review] Bug 22729: (QA follow-up) Ensure no NULL values before setting NOT NULL Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Great work, Passing QA
Created attachment 88745 [details] [review] Bug 22729: (RM follow-up) Correct column in schema addition
Awesome work all! Pushed to master for 19.05
Bug in enhancement not in 18.11.x series.