https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=37502
--- Comment #16 from Adolfo Rodríguez Taboada <[email protected]> --- Created attachment 201059 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=201059&action=edit Patch using Vue island Thank you for the feedback, Jonathan. The patch has been rewritten to address both points. The new approach: Vue island + dedicated REST API endpoint The new patch uses the Vue island pattern (ERMCatalogueTab.vue mounted via islands.ts) and fetches data from a new REST API endpoint: GET /api/v1/biblios/{biblio_id}/erm_holdings Why a new endpoint instead of the existing ERM routes? The existing /api/v1/erm/eholdings/local/titles requires erm: 1 permission. Since the requirement is that the tab should be visible to all staff with catalogue access (not only ERM users), reusing that endpoint would return 403 for users without ERM module access. The new endpoint is declared with x-koha-authorization: permissions: catalogue: "1" and returns a single nested payload (titles → resources → package + vendor + agreements → licenses) in one call. Links to ERM resources and vendors are conditionally rendered in the Vue component based on CAN_user_erm and CAN_user_acquisition_vendors_manage props passed from the template. All functionality from the previous patch is preserved: the tables are rendered via DataTables with per-column search, sorting, and export. The expandable "Licenses (N)" button is also retained. A new patch is attached for review. Have a nice weekend! Greetings, Adolfo. -- You are receiving this mail because: You are watching all bug changes. _______________________________________________ Koha-bugs mailing list [email protected] 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/
