https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20212
Martin Renvoize <martin.renvo...@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #112882|0 |1 is obsolete| | --- Comment #110 from Martin Renvoize <martin.renvo...@ptfs-europe.com> --- Created attachment 114612 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=114612&action=edit Bug 20212: Controller changes regression tests This patchset did a copy and paste of the objects->search helper inside the controller, to handle a very special case that wasn't worth generalizing: the fact that the biblio object (that this patchset makes embeddable) is actually built from two tables, and we want to filter by fields in both tables. This requires us to translate: - Any filter reference to fields in biblioitems we allow to search on, through an allow list. - For filtering to work, we need to tweak the stashed 'embed' object so the prefetch is done correctly This patchset also adds a new query parameter: only_active. It is used to only request active orders (see the spec for more details). This patch adds tests for: - Filtering by a column in bilbioitems (this implies correctly prefetching the bilbio => biblioitems relation, and translating the filtering parameter. - Using the only_active query parameter to retrieve only active orders To test: 1. Apply this patchset 2. Run: $ kshell k$ prove t/db_dependent/api/v1/acquisitions_orders.t => SUCCESS: Tests pass! 3. Verify the tests check for the explained behaviours. => SUCCESS: They do! 4. Sign off :-D Signed-off-by: Tomas Cohen Arazi <tomasco...@theke.io> Signed-off-by: Martin Renvoize <martin.renvo...@ptfs-europe.com> -- You are receiving this mail because: You are watching all bug changes. _______________________________________________ Koha-bugs mailing list Koha-bugs@lists.koha-community.org https://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/