https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=40013 --- Comment #3 from Jonathan Druart <jonathan.druart@gmail.com> --- (In reply to Pedro Amorim from comment #2)
This makes sense, but I wonder if we should tackle it differently?
kohaTable is defined twice, once for Intra, once for OPAC (another example where bug 35716 would prevent it): /koha/koha-tmpl/intranet-tmpl/prog/js/datatables.js /koha/koha-tmpl/opac-tmpl/bootstrap/js/datatables.js
Intra kohaTable implements _dt_add_filters, OPAC does not. I suppose it was never implemented for OPAC kohaTable because there was no need for it, not until now anyway.
My suggestion here would be to implement _dt_add_filters in the OPAC kohaTable, adding the possibility of column filters and enabling the REST API based filtering we're aiming for here.
This would also enable any future REST driven OPAC table to have searchable columns.
I may be completely wrong here, or this can also be considered as a follow-up. Up for discussion.
The two versions of datatables.js are not identical. You could move and centralize most of the code, not everything. -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug.