Bugzilla – Attachment 82990 Details for
Bug 18078
Updating buttons for z39.50 Authority search
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 18078: Updating buttons for z39.50 Authority search
Bug-18078-Updating-buttons-for-z3950-Authority-sea.patch (text/plain), 4.80 KB, created by
Owen Leonard
on 2018-12-07 17:37:09 UTC
(
hide
)
Description:
Bug 18078: Updating buttons for z39.50 Authority search
Filename:
MIME Type:
Creator:
Owen Leonard
Created:
2018-12-07 17:37:09 UTC
Size:
4.80 KB
patch
obsolete
>From 371a7d157d8b63f843270c483705c5cde2591cf9 Mon Sep 17 00:00:00 2001 >From: Owen Leonard <oleonard@myacpl.org> >Date: Fri, 7 Dec 2018 17:12:21 +0000 >Subject: [PATCH] Bug 18078: Updating buttons for z39.50 Authority search > >This patch is an alternate proposal for updating buttons on the Z39.50 >authority search popup window. It takes some aspects of the original >proposal--Styling the pagination buttons with Bootstrap--and adds a new >interaction for navigating to a specific page in results. > >To test, apply the patch and go to Authorities -> New Authority -> New >from Z39.50/SRU. > > - Perform a search which will return multiple pages of results > - At the bottom of the search results there should be a dropdown menu > offering selection of page numbers. > - Selecting a number from the dropdown should automatically load that > page of results. > - The current page number should be correctly pre-selected in the > dropdown. > - The "Previous" and "Next" buttons should work normally. > - Perform a search which returns only a single page of results. There > should be no navigation controls at the bottom of the page. >--- > .../en/modules/cataloguing/z3950_auth_search.tt | 36 +++++++++++++++++----- > 1 file changed, 28 insertions(+), 8 deletions(-) > >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/z3950_auth_search.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/z3950_auth_search.tt >index 0251ba4..6eb8a95 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/z3950_auth_search.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/z3950_auth_search.tt >@@ -118,7 +118,7 @@ > </div> > </div> > >- <form method="post" action="z3950_auth_search.pl" id="page_form" name="page_form" class="checkboxed"> >+ <form method="post" action="z3950_auth_search.pl" id="page_form" name="page_form"> > <input type="hidden" name="op" id="op" value="do_search" /> > <input type="hidden" name="current_page" id="current_page" value="[% current_page | html %]" /> > <input type="hidden" id="nameany" name="nameany" value="[% nameany | html %]" /> >@@ -138,14 +138,30 @@ > <input type="hidden" name="id" id="z3950_[% server.id | html %]" value="[% server.id | html %]" /> > [% END %] > >- [% IF ( show_prevbutton ) %] >- <input type="button" name="changepage_prev" value="Previous page" data-currentpage="[% current_page | html %]" /> >- [% END %] >- Page [% current_page | html %] / [% total_pages | html %] >- [% IF ( show_nextbutton ) %] >- <input type="button" name="changepage_next" value="Next page" data-currentpage="[% current_page | html %]" /> >+ [% IF ( total_pages > 1 ) %] >+ <fieldset class="action"> >+ [% IF ( show_prevbutton ) %] >+ <button type="button" name="changepage_prev" class="btn btn-default btn-xs" data-currentpage="[% current_page | html %]"><i class="fa fa-angle-double-left"></i> Previous page</button> >+ [% END %] >+ Page >+ [% i = 1 %] >+ <select name="goto_page" id="goto_page"> >+ [% WHILE i <= total_pages %] >+ [% IF ( current_page == i ) %] >+ <option value="[% i | html %]" selected="selected">[% i | html %]</option> >+ [% ELSE %] >+ <option value="[% i | html %]">[% i | html %]</option> >+ [% END %] >+ [% i = i + 1 %] >+ [% END %] >+ </select> >+ / [% total_pages | html %] >+ [% IF ( show_nextbutton ) %] >+ <button type="button" name="changepage_next" class="btn btn-default btn-xs" data-currentpage="[% current_page | html %]">Next page <i class="fa fa-angle-double-right"></i></button> >+ [% END %] >+ <input type="hidden" name="" id="changepage_goto" value="Go" /> >+ </fieldset> > [% END %] >- <br />Go to page : <input id="goto_page" name="goto_page" value="[% current_page | html %]" size="4" type="text" /><input type="submit" name="changepage_goto" value="Go" /> > </form> > > <p><form method="get" action="/cgi-bin/koha/cataloguing/z3950_auth_search.pl"><input type="hidden" name="authid" value="[% authid | html %]" /><input type="submit" value="Try another search"/></form></p> >@@ -173,6 +189,10 @@ > [% INCLUDE 'datatables.inc' %] > <script type="text/javascript"> > $(document).ready(function(){ >+ $("#goto_page").on("change", function(){ >+ $("#changepage_goto").attr("name", "changepage_goto"); >+ $("#page_form").submit(); >+ }); > > $(".dropdown").on("hidden.bs.dropdown", function(){ > // Reset menu styles so that a click on the >-- >2.1.4
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 18078
:
60002
|
61172
|
82990