[Koha-bugs] [Bug 17007] REST API: add route to get biblio

bugzilla-daemon at bugs.koha-community.org bugzilla-daemon at bugs.koha-community.org
Tue Aug 9 11:35:05 CEST 2016


https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17007

Lari Taskula <larit at student.uef.fi> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
  Attachment #53836|0                           |1
        is obsolete|                            |

--- Comment #9 from Lari Taskula <larit at student.uef.fi> ---
Created attachment 54187
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=54187&action=edit
Bug 17007: REST API: add route to get biblio

This patch adds route to get one biblio from koha.biblios table. On top of this
biblio there is added key "items" with value being array of items belonging to
the
requested biblio.

As Magnus Enger pointed out, we should hide all the items defined in the
OpacHiddenItems syspref from all but staff. This patch adds this functionality.

To test:
1. Open a browser tab on Koha staff and log in (to create CGISESSID
   cookie).
2. Send GET request to http://yourlibrary/api/v1/biblios/YYY
   where YYY is an existing biblionumber.
3. Make sure the returned data is correct.
4. Find items which are hidden in OPAC with OpacHiddenItems syspref, note their
record's biblionumber and repeat point 2 with it.
5. Check that if you are logged in as staff, you see all the items (even those
hidden from OPAC)
6. Check that if you are not logged in as staff, you see only the items which
are
not hidden from OPAC
7. Run unit tests in t/db_dependent/api/v1/biblios.t

Signed-off-by: Lari Taskula <larit at student.uef.fi>

-- 
You are receiving this mail because:
You are watching all bug changes.


More information about the Koha-bugs mailing list