[Bug 29975] New: (Bug 21729 followup) patron_expiration_date missing in API
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=29975 Bug ID: 29975 Summary: (Bug 21729 followup) patron_expiration_date missing in API Change sponsored?: --- Product: Koha Version: master Hardware: All OS: All Status: NEW Severity: normal Priority: P5 - low Component: REST API Assignee: koha-bugs@lists.koha-community.org Reporter: fridolin.somers@biblibre.com CC: tomascohen@gmail.com Bug 21729 added to holds table the column patron_expiration_date. This must impact the REST API. Currently test suite is failing : https://jenkins.koha-community.org/view/master/job/Koha_Master_D10/516/testR... -- 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=29975 Fridolin Somers <fridolin.somers@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Depends on| |21729 Referenced Bugs: https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=21729 [Bug 21729] When reverting a hold the expirationdate should be reset -- 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=29975 --- Comment #1 from Fridolin Somers <fridolin.somers@biblibre.com> --- Created attachment 129961 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=129961&action=edit Bug 29975: [DRAFT] fix API -- 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=29975 --- Comment #2 from Fridolin Somers <fridolin.somers@biblibre.com> --- (In reply to Fridolin Somers from comment #1)
Created attachment 129961 [details] [review] Bug 29975: [DRAFT] fix API
This draft patch makes api test suite happy. But I don't know if it is the correct solution. -- 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=29975 Fridolin Somers <fridolin.somers@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- See Also| |https://bugs.koha-community | |.org/bugzilla3/show_bug.cgi | |?id=29976 -- 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=29975 Jonathan Druart <jonathan.druart+koha@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |Needs Signoff -- 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=29975 Jonathan Druart <jonathan.druart+koha@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #129961|0 |1 is obsolete| | --- Comment #3 from Jonathan Druart <jonathan.druart+koha@gmail.com> --- Created attachment 129988 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=129988&action=edit Bug 29975: (bug 21729 follow-up) Fix api/v1/holds.t Unknown column 'patron_expiration_date' in 'field list' The REST API routes don't need to be aware of the new column patron_expiration_date -- 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=29975 Jonathan Druart <jonathan.druart+koha@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |jonathan.druart+koha@gmail. | |com Assignee|koha-bugs@lists.koha-commun |jonathan.druart+koha@gmail. |ity.org |com -- 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=29975 --- Comment #4 from Fridolin Somers <fridolin.somers@biblibre.com> --- Thanks a lot for the real patch Jonathan :D -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=29975 Fridolin Somers <fridolin.somers@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Patch complexity|--- |Trivial patch 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=29975 Fridolin Somers <fridolin.somers@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #129988|0 |1 is obsolete| | --- Comment #5 from Fridolin Somers <fridolin.somers@biblibre.com> --- Created attachment 130058 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=130058&action=edit Bug 29975: (bug 21729 follow-up) Fix api/v1/holds.t Unknown column 'patron_expiration_date' in 'field list' The REST API routes don't need to be aware of the new column patron_expiration_date Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=29975 Tomás Cohen Arazi <tomascohen@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- QA Contact| |tomascohen@gmail.com -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=29975 --- Comment #6 from Tomás Cohen Arazi <tomascohen@gmail.com> --- Created attachment 130090 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=130090&action=edit Bug 29975: Add missing patron_expiration_date attribute to hold spec On bug 21729 a new attribute was added to the holds objects, but we forgot to add it to the spec. This broke the holds routes. To test: 1. Run: $ kshell k$ prove t/db_dependent/api/v1/holds.t => FAIL: Tests fail, boo. 2. Apply this patch 3. Repeat 1 => SUCCESS: Tests pass! 4. Sign off :-D Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=29975 Tomás Cohen Arazi <tomascohen@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #130058|0 |1 is obsolete| | -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=29975 Tomás Cohen Arazi <tomascohen@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- QA Contact|tomascohen@gmail.com |martin.renvoize@ptfs-europe | |.com -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=29975 Tomás Cohen Arazi <tomascohen@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #130090|0 |1 is obsolete| | -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=29975 Tomás Cohen Arazi <tomascohen@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- QA Contact|martin.renvoize@ptfs-europe |tomascohen@gmail.com |.com | -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=29975 Tomás Cohen Arazi <tomascohen@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #130058|1 |0 is obsolete| | -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=29975 --- Comment #7 from Tomás Cohen Arazi <tomascohen@gmail.com> --- I revert what I did because Jonathan is right, this attribute is not strictly required on the API (yet?) so we should delay exposing it until there's a real need for it. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=29975 Tomás Cohen Arazi <tomascohen@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Signed Off |Passed QA -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=29975 Tomás Cohen Arazi <tomascohen@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #130058|0 |1 is obsolete| | --- Comment #8 from Tomás Cohen Arazi <tomascohen@gmail.com> --- Created attachment 130092 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=130092&action=edit Bug 29975: (bug 21729 follow-up) Fix api/v1/holds.t Unknown column 'patron_expiration_date' in 'field list' The REST API routes don't need to be aware of the new column patron_expiration_date Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=29975 Fridolin Somers <fridolin.somers@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Version(s)| |22.05.00 released in| | Status|Passed QA |Pushed to master -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=29975 --- Comment #9 from Fridolin Somers <fridolin.somers@biblibre.com> --- Pushed to master for 22.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=29975 Nick Clemens <nick@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |nick@bywatersolutions.com --- Comment #10 from Nick Clemens <nick@bywatersolutions.com> --- Just for clarification here: When creating a hold if an expirationdate is passed then it will be set as the patron_expiration_date When the patron_expiration_date is set, this is copied to the expiration_date When Koha sets an expiration date (when hold filled) it will use the lesser of the patron_expiration_date or the calculated date i.e. the expiration_date field in the api will represent the patron_expiration_date or the Koha expiration_date as appropriate i.e. The field is not so much hidden, as not needed externally - I didn't fully understand and leave this for others as muddled as me -- You are receiving this mail because: You are watching all bug changes.
participants (1)
-
bugzilla-daemon@bugs.koha-community.org