[Bug 20145] New: borrowers.datexpiry eq '0000-00-00' means expired?
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20145 Bug ID: 20145 Summary: borrowers.datexpiry eq '0000-00-00' means expired? Change sponsored?: --- Product: Koha Version: unspecified Hardware: All OS: All Status: NEW Severity: major Priority: P5 - low Component: Architecture, internals, and plumbing Assignee: koha-bugs@lists.koha-community.org Reporter: jonathan.druart@bugs.koha-community.org QA Contact: testopia@bugs.koha-community.org See bug http://lists.koha-community.org/pipermail/koha-devel/2018-February/044322.ht... Koha::Patron->is_expired returns 0 if $self->dateexpiry eq '0000-00-00' And there is a test I wrote for it on bug 17578 (commit 5a0a2ce584dec74808f471b0f92b2114c3d6029e , GetMemberDetails - Remove is_expired) But then we also have, in C4::Circulation::CanBookBeIssued: 752 if ( !defined $patron->dateexpiry || $patron->dateexpiry eq '0000-00-00') { 753 $issuingimpossible{EXPIRED} = 1; 754 } else { With a test: is( $issuingimpossible->{EXPIRED}, 1, 'The patron should be considered as expired if dateexpiry is 0000-00-00' ); So, my questions, do you have a very old Koha installations to search if there is borrowers.is_expired == "0000-00-00" in it? Do you remember if it meant expired or not at some point? -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20145 Jonathan Druart <jonathan.druart@bugs.koha-community.org> changed: What |Removed |Added ---------------------------------------------------------------------------- See Also| |https://bugs.koha-community | |.org/bugzilla3/show_bug.cgi | |?id=20144 -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20145 Jonathan Druart <jonathan.druart@bugs.koha-community.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |Needs Signoff -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20145 --- Comment #1 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- Created attachment 71633 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=71633&action=edit Bug 20145: Do not insert 0000-00-00 in patron tests (and more) We should call Koha::Patron->is_expired in CanBookBeIssued instead of doing the same calculation. Tests have been adapted to pass with new SQL modes. We should not need to update the values in DB, we already have Bug 14717: Prevent 0000-00-00 dates in patron data (3.21.00.023) Test plan: prove t/db_dependent/Circulation/dateexpiry.t prove t/db_dependent/Koha/Patrons.t must return green -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20145 Jonathan Druart <jonathan.druart@bugs.koha-community.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Assignee|koha-bugs@lists.koha-commun |jonathan.druart@bugs.koha-c |ity.org |ommunity.org -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20145 Roch D'Amour <roch.damour@inlibro.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Needs Signoff |Signed Off -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20145 Roch D'Amour <roch.damour@inlibro.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #71633|0 |1 is obsolete| | --- Comment #2 from Roch D'Amour <roch.damour@inlibro.com> --- Created attachment 71859 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=71859&action=edit Bug 20145: Do not insert 0000-00-00 in patron tests (and more) We should call Koha::Patron->is_expired in CanBookBeIssued instead of doing the same calculation. Tests have been adapted to pass with new SQL modes. We should not need to update the values in DB, we already have Bug 14717: Prevent 0000-00-00 dates in patron data (3.21.00.023) Test plan: prove t/db_dependent/Circulation/dateexpiry.t prove t/db_dependent/Koha/Patrons.t must return green Signed-off-by: Roch D'Amour <roch.damour@inlibro.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20145 Roch D'Amour <roch.damour@inlibro.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |roch.damour@inlibro.com -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20145 Katrin Fischer <katrin.fischer@bsz-bw.de> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Signed Off |Passed QA Patch complexity|--- |Medium patch -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20145 Katrin Fischer <katrin.fischer@bsz-bw.de> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #71859|0 |1 is obsolete| | --- Comment #3 from Katrin Fischer <katrin.fischer@bsz-bw.de> --- Created attachment 71897 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=71897&action=edit Bug 20145: Do not insert 0000-00-00 in patron tests (and more) We should call Koha::Patron->is_expired in CanBookBeIssued instead of doing the same calculation. Tests have been adapted to pass with new SQL modes. We should not need to update the values in DB, we already have Bug 14717: Prevent 0000-00-00 dates in patron data (3.21.00.023) Test plan: prove t/db_dependent/Circulation/dateexpiry.t prove t/db_dependent/Koha/Patrons.t must return green Signed-off-by: Roch D'Amour <roch.damour@inlibro.com> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20145 Jonathan Druart <jonathan.druart@bugs.koha-community.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Passed QA |Pushed to Master --- Comment #4 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- Pushed to master for 18.05, thanks to everybody involved! -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20145 Josef Moravec <josef.moravec@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Blocks| |20331 Referenced Bugs: https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20331 [Bug 20331] Patrons search results sorting and pagination does not work properly -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20145 Nick Clemens <nick@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |nick@bywatersolutions.com Status|Pushed to Master |Pushed to Stable --- Comment #5 from Nick Clemens <nick@bywatersolutions.com> --- Awsome work all! Pushed to stable for 17.11.04 -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20145 Fridolin SOMERS <fridolin.somers@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |fridolin.somers@biblibre.co | |m --- Comment #6 from Fridolin SOMERS <fridolin.somers@biblibre.com> --- Pushed to 17.05.x for v17.05.10 In order to apply I added in C4/Circulation.pm (exists in 17.11) : # # BORROWER STATUS # + my $patron = Koha::Patrons->find( $borrower->{borrowernumber} ); -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20145 Jonathan Druart <jonathan.druart@bugs.koha-community.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Blocks| |20455 Referenced Bugs: https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20455 [Bug 20455] Can't sort patron search on date expired -- You are receiving this mail because: You are watching all bug changes.
participants (1)
-
bugzilla-daemon@bugs.koha-community.org