Summary: | Add GET /biblios/:biblio_id/items | ||
---|---|---|---|
Product: | Koha | Reporter: | Tomás Cohen Arazi (tcohen) <tomascohen> |
Component: | REST API | Assignee: | Tomás Cohen Arazi (tcohen) <tomascohen> |
Status: | CLOSED FIXED | QA Contact: | |
Severity: | enhancement | ||
Priority: | P5 - low | CC: | caroline.cyr-la-rose, fridolin.somers, jonathan.druart, lucas, martin.renvoize |
Version: | Main | ||
Hardware: | All | ||
OS: | All | ||
Change sponsored?: | --- | Patch complexity: | --- |
Documentation contact: | Documentation submission: | ||
Text to go in the release notes: | Version(s) released in: |
21.05.00
|
|
Circulation function: | |||
Bug Depends on: | 27034 | ||
Bug Blocks: | 27358 | ||
Attachments: |
Bug 27352: Add GET /biblios/:biblio_id/items
Bug 27352: Unit tests Bug 27352: Missed case in bug 25032 Bug 27352: Add GET /biblios/:biblio_id/items Bug 27352: Unit tests Bug 27352: Missed case in bug 25032 Bug 27352: Add GET /biblios/:biblio_id/items Bug 27352: Unit tests Bug 27352: Missed case in bug 25032 |
Description
Tomás Cohen Arazi (tcohen)
2021-01-06 14:39:34 UTC
Created attachment 114892 [details] [review] Bug 27352: Add GET /biblios/:biblio_id/items This patch adds a route to fetch the items for a biblio. It relies entirely on already existing methods. To test: 1. Use your favourite REST tool 2. Play with the new route. => SUCCESS: It works as expected! Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io> Created attachment 114894 [details] [review] Bug 27352: Unit tests Created attachment 114895 [details] [review] Bug 27352: Missed case in bug 25032 Probably because of the order things got pushed. Created attachment 114983 [details] [review] Bug 27352: Add GET /biblios/:biblio_id/items This patch adds a route to fetch the items for a biblio. It relies entirely on already existing methods. To test: 1. Use your favourite REST tool 2. Play with the new route. => SUCCESS: It works as expected! Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io> Signed-off-by: Lucas Gass <lucas@bywatersolutions.com> Created attachment 114984 [details] [review] Bug 27352: Unit tests Signed-off-by: Lucas Gass <lucas@bywatersolutions.com> Created attachment 114985 [details] [review] Bug 27352: Missed case in bug 25032 Probably because of the order things got pushed. Signed-off-by: Lucas Gass <lucas@bywatersolutions.com> Works good with PostMan. I also play around with stuff like: let url = '/api/v1/biblios/144/items'; $.getJSON(url, function(data) { data.forEach(element => console.log(element.collection_code)); }); Just to see how it works. I really like this route. Also tests pass for me: prove -v t/db_dependent/api/v1/biblios.t Created attachment 115810 [details] [review] Bug 27352: Add GET /biblios/:biblio_id/items This patch adds a route to fetch the items for a biblio. It relies entirely on already existing methods. To test: 1. Use your favourite REST tool 2. Play with the new route. => SUCCESS: It works as expected! Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io> Signed-off-by: Lucas Gass <lucas@bywatersolutions.com> Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> Created attachment 115811 [details] [review] Bug 27352: Unit tests Signed-off-by: Lucas Gass <lucas@bywatersolutions.com> Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> Created attachment 115812 [details] [review] Bug 27352: Missed case in bug 25032 Probably because of the order things got pushed. Signed-off-by: Lucas Gass <lucas@bywatersolutions.com> Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> It's great to see these routes getting added.. Thanks for all your diligent work Tomas! Works great, all makes sense and passes QA scripts and Unit tests. Passing QA Pushed to master for 21.05, thanks to everybody involved! Depends on Bug 27034 not in 20.11.x |