[Bug 24615] New: REST API order by prefetched columns
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=24615 Bug ID: 24615 Summary: REST API order by prefetched columns Change sponsored?: --- Product: Koha Version: master Hardware: All OS: All Status: NEW Severity: enhancement Priority: P5 - low Component: REST API Assignee: agustinmoyano@theke.io Reporter: agustinmoyano@theke.io CC: tomascohen@gmail.com Depends on: 24502 Blocks: 20936 Make object.search helper be able to order by prefetched columns Referenced Bugs: https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20936 [Bug 20936] Holds History for patrons in OPAC https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=24502 [Bug 24502] Add a query language and param (q=) to the API -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=24615 Agustín Moyano <agustinmoyano@theke.io> changed: What |Removed |Added ---------------------------------------------------------------------------- Patch complexity|--- |Small patch Status|NEW |Needs Signoff -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=24615 --- Comment #1 from Agustín Moyano <agustinmoyano@theke.io> --- Created attachment 98604 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=98604&action=edit Bug 24615: Make object.search helper also order by embedded columns With this patch REST API request can order results by embedded columns. Full path to the column must be given for it to work. For example: If you are on biblio endpoint and you want to order by holding patron's card number you could
GET /biblio/1?_order_by=item.holds.cardnumber HTTP/1.1 x-koha-embed: item.holds
To test: 1. apply this patch 2. prove t/db_dependent/Koha/REST/Plugin/Objects.t -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=24615 Agustín Moyano <agustinmoyano@theke.io> changed: What |Removed |Added ---------------------------------------------------------------------------- Blocks| |24561 Referenced Bugs: https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=24561 [Bug 24561] Add embedded column filter feature to datatables api wrapper -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=24615 Agustín Moyano <agustinmoyano@theke.io> changed: What |Removed |Added ---------------------------------------------------------------------------- Blocks|20936 | Referenced Bugs: https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20936 [Bug 20936] Holds History for patrons in OPAC -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=24615 David Nind <david@davidnind.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Needs Signoff |Patch doesn't apply CC| |david@davidnind.com --- Comment #2 from David Nind <david@davidnind.com> --- Path doesn't apply: .git/rebase-apply/patch:67: trailing whitespace. warning: 1 line adds whitespace errors. Using index info to reconstruct a base tree... M Koha/REST/Plugin/Query.pm M t/db_dependent/Koha/REST/Plugin/Objects.t .git/rebase-apply/patch:67: trailing whitespace. warning: 1 line applied after fixing whitespace errors. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=24615 Agustín Moyano <agustinmoyano@theke.io> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Patch doesn't apply |Signed Off --- Comment #3 from Agustín Moyano <agustinmoyano@theke.io> --- Dependency 24502 was in Failed QA state. Patches now apply. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=24615 Agustín Moyano <agustinmoyano@theke.io> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Signed Off |Needs Signoff -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=24615 David Nind <david@davidnind.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Needs Signoff |Signed Off -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=24615 David Nind <david@davidnind.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #98604|0 |1 is obsolete| | --- Comment #4 from David Nind <david@davidnind.com> --- Created attachment 99338 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=99338&action=edit Bug 24615: Make object.search helper also order by embedded columns With this patch REST API request can order results by embedded columns. Full path to the column must be given for it to work. For example: If you are on biblio endpoint and you want to order by holding patron's card number you could
GET /biblio/1?_order_by=item.holds.cardnumber HTTP/1.1 x-koha-embed: item.holds
To test: 1. apply this patch 2. prove t/db_dependent/Koha/REST/Plugin/Objects.t Signed-off-by: David Nind <david@davidnind.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=24615 Martin Renvoize <martin.renvoize@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #99338|0 |1 is obsolete| | --- Comment #5 from Martin Renvoize <martin.renvoize@ptfs-europe.com> --- Created attachment 99353 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=99353&action=edit Bug 24615: Make object.search helper also order by embedded columns With this patch REST API request can order results by embedded columns. Full path to the column must be given for it to work. For example: If you are on biblio endpoint and you want to order by holding patron's card number you could
GET /biblio/1?_order_by=item.holds.cardnumber HTTP/1.1 x-koha-embed: item.holds
To test: 1. apply this patch 2. prove t/db_dependent/Koha/REST/Plugin/Objects.t Signed-off-by: David Nind <david@davidnind.com> Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=24615 Martin Renvoize <martin.renvoize@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |martin.renvoize@ptfs-europe | |.com Status|Signed Off |Passed QA --- Comment #6 from Martin Renvoize <martin.renvoize@ptfs-europe.com> --- Clear patch and no QA failures. Passing QA -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=24615 Martin Renvoize <martin.renvoize@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Passed QA |Pushed to master Version(s)| |20.05.00 released in| | -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=24615 --- Comment #7 from Martin Renvoize <martin.renvoize@ptfs-europe.com> --- Nice work everyone! Pushed to master for 20.05 -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=24615 Joy Nelson <joy@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |joy@bywatersolutions.com --- Comment #8 from Joy Nelson <joy@bywatersolutions.com> --- enhancement not backported to 19.11.x -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=24615 Tomás Cohen Arazi <tomascohen@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Summary|REST API order by |Order by related object |prefetched columns |columns QA Contact| |martin.renvoize@ptfs-europe | |.com -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=24615 Martin Renvoize <martin.renvoize@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Summary|Order by related object |Add support for ordering by |columns |related object columns in | |the REST API -- You are receiving this mail because: You are watching all bug changes.
participants (1)
-
bugzilla-daemon@bugs.koha-community.org