From f4ec53cc13663d3a2027c48672f8d325aa390c5c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marc=20V=C3=A9ron?= Date: Fri, 20 Jun 2014 22:40:03 +0200 Subject: [PATCH] Bug 12481 - Follow up: Link to results is not refreshed when item is on next or prev result page Test plan for this follow up Reproduce issue without patch: Do a search that results in 3 or more pages. Print out list or do the same search in an other browser (to have a reference for the following) Go to a detail view and step through details to a detail that ist on result #3 Click on Link "Return to details" Result: The first page will display (instead of page #2) With patch, the correct page should display. --- koha-tmpl/intranet-tmpl/js/browser.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/koha-tmpl/intranet-tmpl/js/browser.js b/koha-tmpl/intranet-tmpl/js/browser.js index b0676a5..0dbd2f5 100644 --- a/koha-tmpl/intranet-tmpl/js/browser.js +++ b/koha-tmpl/intranet-tmpl/js/browser.js @@ -77,6 +77,8 @@ KOHA.browser = function (searchid, biblionumber) { var searchURL = '/cgi-bin/koha/catalogue/search.pl?' + decodeURIComponent(me.searchCookie.query) + '&limit=' + decodeURIComponent(me.searchCookie.limit) + '&sort=' + me.searchCookie.sort + '&searchid=' + me.searchid + '&offset=' + me.offset; var prevbutton; var nextbutton; + var returnbutton; +returnbutton = '
' + BROWSER_RETURN_TO_SEARCH + '
'; if (me.curPos === 0 && me.searchCookie.offset === 1) { prevbutton = '« ' + BROWSER_PREVIOUS + ''; } else { @@ -87,7 +89,7 @@ KOHA.browser = function (searchid, biblionumber) { } else { nextbutton = '' + BROWSER_NEXT + ' »'; } - $('#menu').before('
' + prevbutton + nextbutton + '
'); + $('#menu').before('
' +returnbutton + '
' + prevbutton + nextbutton + '
'); $('a#browse-previous').click(function (ev) { ev.preventDefault(); browseRecords(-1); -- 1.7.10.4