Bugzilla – Attachment 39708 Details for
Bug 14029
Provide link to clear reports search filters
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 14029: Provide 'clear' link to empty reports search filters
Bug-14029-Provide-clear-link-to-empty-reports-sear.patch (text/plain), 2.49 KB, created by
Katrin Fischer
on 2015-05-31 13:43:13 UTC
(
hide
)
Description:
Bug 14029: Provide 'clear' link to empty reports search filters
Filename:
MIME Type:
Creator:
Katrin Fischer
Created:
2015-05-31 13:43:13 UTC
Size:
2.49 KB
patch
obsolete
>From ac4e28bcf194fa5f46ded84a8277626ff0dc54d4 Mon Sep 17 00:00:00 2001 >From: Katrin Fischer <Katrin.Fischer.83@web.de> >Date: Mon, 25 May 2015 11:03:14 +0200 >Subject: [PATCH] Bug 14029: Provide 'clear' link to empty reports search > filters >MIME-Version: 1.0 >Content-Type: text/plain; charset=UTF-8 >Content-Transfer-Encoding: 8bit > >Patch adds a 'clear' link next to the 'Apply filters' button to >empty out the form fields. > >To test: >- go to the reports module >- make sure you have some saved reports >- search your saved reports using the author, keyword and date filters >- verify searching works as expected >- verify the new 'clear' link works as expected > >Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de> >Changed patch to include suggestion from Marc VÃeron for >reloading the form on clearing. Thx Marc! >--- > .../prog/en/modules/reports/guided_reports_start.tt | 12 ++++++++++-- > 1 file changed, 10 insertions(+), 2 deletions(-) > >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/reports/guided_reports_start.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/reports/guided_reports_start.tt >index e769af2..4ef7e91 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/reports/guided_reports_start.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/reports/guided_reports_start.tt >@@ -150,6 +150,12 @@ $(document).ready(function(){ > return false; > } > }); >+ >+ $("#resetReportsFilter").click(function(e) { >+ e.preventDefault(); >+ $("form[name='ReportsFilter']").find("input[type=text]").val(""); >+ $("form[name='ReportsFilter']").submit(); >+ }); > [% END %] > > [% IF ( showsql ) %] >@@ -1031,7 +1037,7 @@ Sub report:<select name="subreport"> > > [% IF ( saved1 ) %] > <div id="saved-reports-filter"> >-<form action="/cgi-bin/koha/reports/guided_reports.pl" method="get"> >+<form action="/cgi-bin/koha/reports/guided_reports.pl" method="get" name="ReportsFilter"> > <input type="hidden" name="phase" value="Use saved" /> > <input type="hidden" name="filter_set" value="1" /> > <fieldset class="brief"> >@@ -1045,7 +1051,9 @@ Sub report:<select name="subreport"> > <li><label for="filter_keyword">Keyword:</label> <input type="text" id="filter_keyword" name="filter_keyword" value="[% filters.keyword %]" /></li> > </ol> > </fieldset> >- <fieldset class="action"><input type="submit" value="Apply filter" /></fieldset> >+ <fieldset class="action"><input type="submit" value="Apply filter" /> >+ <a id="resetReportsFilter" href="#">Clear</a> >+ </fieldset> > </form> > </div> > [% END %] >-- >1.9.1
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 14029
:
39474
|
39708
|
39736
|
39856
|
39866
|
39868
|
39869
|
39933