From 3b4217c3b8547c66d6d49f51c86ead512cb0c77d Mon Sep 17 00:00:00 2001 From: Hammat Wele Date: Tue, 28 Mar 2023 16:31:34 +0000 Subject: [PATCH] Bug 27428: (QA follow-up) Add missing POD, remove ES template literals in opac-display-record-count.js Signed-off-by: Petro Vashchuk Signed-off-by: David Nind --- Koha/SearchEngine/Elasticsearch/Browse.pm | 8 ++++++++ .../opac-tmpl/bootstrap/js/opac-display-record-count.js | 2 +- 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/Koha/SearchEngine/Elasticsearch/Browse.pm b/Koha/SearchEngine/Elasticsearch/Browse.pm index 5d4282ed2f..14e1d1b0f9 100644 --- a/Koha/SearchEngine/Elasticsearch/Browse.pm +++ b/Koha/SearchEngine/Elasticsearch/Browse.pm @@ -175,6 +175,14 @@ sub _build_query_count_record { return $query; } +=head2 count_record + + $result = $browser->count_record($ses); + +Return an arrayref of record counts + +=cut + sub count_record { my ($self, $cgi_q) = @_; my @results_return; diff --git a/koha-tmpl/opac-tmpl/bootstrap/js/opac-display-record-count.js b/koha-tmpl/opac-tmpl/bootstrap/js/opac-display-record-count.js index 47265534f3..7fc68f19f0 100644 --- a/koha-tmpl/opac-tmpl/bootstrap/js/opac-display-record-count.js +++ b/koha-tmpl/opac-tmpl/bootstrap/js/opac-display-record-count.js @@ -46,7 +46,7 @@ var not_symbols = { function NumberResultsRecord(){ - var regex = `a[href*="${regex_es_link}"]`; + var regex = 'a[href*="${' + regex_es_link + '}"]'; var all_link = $(regex); /* array json data to server */ var json_data=[]; -- 2.34.1