Hi, with the HAL introduction in mind I plan to (at least) provide a sample implementation of the following:
- Add a 'to_api' method to Koha::Object and Koha::Objects that can be overloaded if needed (trivial, WIP 23770) - Pick a sample endpoint (probably /cities) and make sure the implementation keeps the current behaviour (trivial, besides the boring tests) - Move the existing controllers into using this (trivial) - Implement in some sample class, to be determined, ->to_api_hal. And make the endpoint that uses it, Accept: application/hal+json and return this new data structure. So if JSON is requested, the current behaviour is kept. Otherwise, the HAL representation will be returned. Things to think about and which we will be able to play with: - How to determine the depth of the embedding? (HAL has that ability) - Should we specify which FK to follow and embed on the query? how would that query look like? Thanks for your time :-D -- Tomás Cohen Arazi Theke Solutions (http://theke.io) ✆ +54 9351 3513384 GPG: B2F3C15F
_______________________________________________ Koha-devel mailing list Koha-devel@lists.koha-community.org https://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-devel website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/