Bug 18103 - REST API: Add endpoint for patron status / blocks
Summary: REST API: Add endpoint for patron status / blocks
Status: NEW
Alias: None
Product: Koha
Classification: Unclassified
Component: REST API (show other bugs)
Version: Main
Hardware: All All
: P5 - low enhancement
Assignee: Lari Taskula
QA Contact:
URL:
Keywords:
Depends on: 16826
Blocks:
  Show dependency treegraph
 
Reported: 2017-02-13 13:04 UTC by Lari Taskula
Modified: 2017-09-25 18:01 UTC (History)
2 users (show)

See Also:
Change sponsored?: ---
Patch complexity: ---
Documentation contact:
Documentation submission:
Text to go in the release notes:
Version(s) released in:
Circulation function:


Attachments
Bug 18013: Add patronstatus to Swagger (5.17 KB, patch)
2017-02-13 16:09 UTC, Lari Taskula
Details | Diff | Splinter Review
Bug 18013: Add patronstatus operation to controller (6.72 KB, patch)
2017-02-13 16:10 UTC, Lari Taskula
Details | Diff | Splinter Review
Bug 18103: Add patronstatus to Swagger (5.17 KB, patch)
2017-02-13 16:12 UTC, Lari Taskula
Details | Diff | Splinter Review
Bug 18103: Add patronstatus operation to controller (6.72 KB, patch)
2017-02-13 16:12 UTC, Lari Taskula
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Lari Taskula 2017-02-13 13:04:58 UTC
Add endpoint that returns information on patron's debarments / excessive fines etc. This endpoint can be used to find out patron's ability for checkouts and holds.
Comment 1 Lari Taskula 2017-02-13 16:09:06 UTC
Created attachment 60159 [details] [review]
Bug 18013: Add patronstatus to Swagger

This patch adds the Swagger definition for patronstatus.
Comment 2 Lari Taskula 2017-02-13 16:10:31 UTC
Created attachment 60160 [details] [review]
Bug 18013: Add patronstatus operation to controller

This patch adds patronstatus operation to Koha::REST::V1::Patron.

Also adds new method Koha::Patron->status_not_ok that returns an array of
Koha::Exceptions if there are some issues with patron status.

To test:
1. prove t/db_dependent/Koha/Patrons.t
2. prove t/db_dependent/api/v1/patrons.t
Comment 3 Lari Taskula 2017-02-13 16:11:00 UTC
Tests are still failing due to data type changes.
Comment 4 Lari Taskula 2017-02-13 16:12:05 UTC
Created attachment 60161 [details] [review]
Bug 18103: Add patronstatus to Swagger

This patch adds the Swagger definition for patronstatus.
Comment 5 Lari Taskula 2017-02-13 16:12:22 UTC
Created attachment 60162 [details] [review]
Bug 18103: Add patronstatus operation to controller

This patch adds patronstatus operation to Koha::REST::V1::Patron.

Also adds new method Koha::Patron->status_not_ok that returns an array of
Koha::Exceptions if there are some issues with patron status.

To test:
1. prove t/db_dependent/Koha/Patrons.t
2. prove t/db_dependent/api/v1/patrons.t
Comment 6 Lari Taskula 2017-02-13 16:13:44 UTC
Corrected invalid Bug number.
Comment 7 Mirko Tietgen 2017-05-17 10:15:21 UTC
Is this ready to be tested? Please set the status to "Needs signoff" then.