[Koha-bugs] [Bug 16826] REST API: Add API routes for getting item availability and holdability

bugzilla-daemon at bugs.koha-community.org bugzilla-daemon at bugs.koha-community.org
Mon Feb 13 13:34:57 CET 2017


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

Lari Taskula <lari.taskula at jns.fi> changed:

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

--- Comment #40 from Lari Taskula <lari.taskula at jns.fi> ---
Created attachment 60156
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=60156&action=edit
Bug 16826: Swaggerize Koha::Availability objects

Koha::Biblio::Availability->swaggerize
Koha::Item::Availability->swaggerize

Constructs a HASHref that contains all availability data to be returned in a
JSON
object. Numifies numbers to be numbers instead of strings. E.g. biblio
swaggerize

{
  "biblionumber": 1234,
  "availability": {
    "available": true,
    "notes": {
      "Patron::SomethingToNote": {
        "cool": 1
      }
    }
  },
  "item_availabilities": [
    {
      "itemnumber": 5678,
      "availability": {
        "available": false,
        "unavailabilities": {
          "Item::Withdrawn": {}
        }
      }
    }
  ]
}

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


More information about the Koha-bugs mailing list