We can replace it with biblio.items.filter_by_bookable, no need to have this TT method.
Created attachment 160960 [details] [review] Bug 35787: Remove Koha::Template::Plugin::Biblio::CanBook We can replace it with biblio.items.filter_by_bookable, no need to have this TT method. Additionally there was no test for it. Test plan: Make sure the Bookings tab on the left of the biblio detail page is displayed when needed. Note that there is also a "Place booking" button that should appear in the toolbar.
Created attachment 161038 [details] [review] Bug 35787: Remove Koha::Template::Plugin::Biblio::CanBook We can replace it with biblio.items.filter_by_bookable, no need to have this TT method. Additionally there was no test for it. Test plan: Make sure the Bookings tab on the left of the biblio detail page is displayed when needed. Note that there is also a "Place booking" button that should appear in the toolbar. Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Works as expected, QA script happy. QA question: You considered this TT method too new for a dbrev? I'd agree, just mentioning in case it was an unintended miss.
(In reply to Tomás Cohen Arazi from comment #3) > Works as expected, QA script happy. > > QA question: You considered this TT method too new for a dbrev? I'd agree, > just mentioning in case it was an unintended miss. Yes, on purpose. I don't think we need one.
Agreed on the too new to warrant the db rev.. but I will submit the unit tests for filter_by_bookable first thing tomorrow.. I have them on a branch
Created attachment 161056 [details] [review] Bug 35787: Add unit test for filter_by_bookable Trivial test added for filter_by_bookable
Branch pushed https://github.com/PTFS-Europe/koha/tree/bug_35787
Pushed for 24.05! Well done everyone, thank you!
Enhancement not pushed to 23.11.x
Architecture change, nothing to add/edit in the Koha manual.