Bugzilla – Attachment 21171 Details for
Bug 9811
Patrons search improvements
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 9811: QA followup
Bug-9811-QA-followup.patch (text/plain), 4.77 KB, created by
Jonathan Druart
on 2013-09-18 11:47:18 UTC
(
hide
)
Description:
Bug 9811: QA followup
Filename:
MIME Type:
Creator:
Jonathan Druart
Created:
2013-09-18 11:47:18 UTC
Size:
4.77 KB
patch
obsolete
>From 82e9bdb37b3ee637bbbe84abc7995995e2b0abd2 Mon Sep 17 00:00:00 2001 >From: Jonathan Druart <jonathan.druart@biblibre.com> >Date: Mon, 1 Jul 2013 10:39:06 +0200 >Subject: [PATCH] Bug 9811: QA followup > >- removes 2 tabs >- removes mysqlisms >- add sort on borrowernotes >- fix wrong capitalization >- cat => Category > >Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de> >Thx for fixing these! >--- > C4/Utils/DataTables/Members.pm | 8 ++++---- > koha-tmpl/intranet-tmpl/prog/en/includes/patron-search.inc | 4 ++-- > koha-tmpl/intranet-tmpl/prog/en/modules/members/member.tt | 9 +++++---- > 3 files changed, 11 insertions(+), 10 deletions(-) > >diff --git a/C4/Utils/DataTables/Members.pm b/C4/Utils/DataTables/Members.pm >index 2f99d90..aeb0eba 100644 >--- a/C4/Utils/DataTables/Members.pm >+++ b/C4/Utils/DataTables/Members.pm >@@ -27,7 +27,7 @@ sub search { > } > > my $dbh = C4::Context->dbh; >- my $select = "SELECT SQL_CALC_FOUND_ROWS >+ my $select = "SELECT > borrowers.borrowernumber, borrowers.surname, borrowers.firstname, borrowers.address, > borrowers.address2, borrowers.city, borrowers.zipcode, borrowers.country, > CAST(borrowers.cardnumber AS UNSIGNED) AS cardnumber, borrowers.dateexpiry, >@@ -80,7 +80,7 @@ sub search { > if @where_strs_or; > > my $where; >- $where = "WHERE " . join (" AND ", @where_strs) if @where_strs; >+ $where = " WHERE " . join (" AND ", @where_strs) if @where_strs; > my $orderby = dt_build_orderby($dt_params); > > my $limit; >@@ -104,9 +104,9 @@ sub search { > my $patrons = $sth->fetchall_arrayref({}); > > # Get the iTotalDisplayRecords DataTable variable >- $query = "SELECT FOUND_ROWS()"; >+ $query = "SELECT COUNT(*) " . $from . ($where ? $where : ""); > $sth = $dbh->prepare($query); >- $sth->execute; >+ $sth->execute(@where_args); > ($iTotalDisplayRecords) = $sth->fetchrow_array; > > # Get the iTotalRecords DataTable variable >diff --git a/koha-tmpl/intranet-tmpl/prog/en/includes/patron-search.inc b/koha-tmpl/intranet-tmpl/prog/en/includes/patron-search.inc >index 722fec8..3172208 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/includes/patron-search.inc >+++ b/koha-tmpl/intranet-tmpl/prog/en/includes/patron-search.inc >@@ -91,8 +91,8 @@ > <option value="[% categorie.categorycode %]" selected="selected">[% categorie.description %]</option>[% ELSE %] > <option value="[% categorie.categorycode %]">[% categorie.description %]</option>[% END %] > [% END %]</select> >- </p> >- [% END %] >+ </p> >+ [% END %] > </form> > </div> > >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/members/member.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/members/member.tt >index b8a7ce0..5aa0009 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/members/member.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/members/member.tt >@@ -2,6 +2,7 @@ > <title>Koha › Patrons [% IF ( searching ) %]› Search results[% END %]</title> > [% INCLUDE 'doc-head-close.inc' %] > <script type="text/javascript" src="[% themelang %]/lib/jquery/plugins/jquery.dataTables.min.js"></script> >+[% INCLUDE 'datatables-strings.inc' %] > <script type="text/javascript" src="[% themelang %]/js/datatables.js"></script> > <link rel="stylesheet" type="text/css" href="[% themelang %]/css/datatables.css" /> > <script type="text/javascript"> >@@ -92,7 +93,7 @@ > { 'mDataProp': 'dt_dateexpiry' }, > { 'mDataProp': 'dt_od_checkouts', 'bSortable': false }, > { 'mDataProp': 'dt_fines', 'bSortable': false }, >- { 'mDataProp': 'dt_borrowernotes', 'bSortable': false }, >+ { 'mDataProp': 'dt_borrowernotes' }, > { 'mDataProp': 'dt_action', 'bSortable': false } > ], > 'fnRowCallback': function(nRow, aData, iDisplayIndex, iDisplayIndexFull) { >@@ -212,7 +213,7 @@ > <tr> > <th>Card</th> > <th>Name</th> >- <th>Cat</th> >+ <th>Category</th> > <th>Library</th> > <th>Expires on</th> > <th>OD/Checkouts</th> >@@ -261,9 +262,9 @@ > <option value='phone'>Phone number</option> > [% END %] > [% IF searchfieldstype == "address" %] >- <option selected="selected" value='address'>Street Address</option> >+ <option selected="selected" value='address'>Street address</option> > [% ELSE %] >- <option value='address'>Street Address</option> >+ <option value='address'>Street address</option> > [% END %] > [% IF searchfieldstype == "dateofbirth" %] > <option selected="selected" value='dateofbirth'>Date of birth</option> >-- >1.7.10.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 9811
:
16096
|
16111
|
16112
|
16320
|
16362
|
16403
|
16957
|
19056
|
19057
|
19307
|
19633
|
19642
|
20094
|
20095
|
20096
|
20174
|
20266
|
20290
|
20291
|
21169
|
21170
|
21171
|
21172
|
21173
|
21174
|
21175
|
22265
|
23261
|
24095
|
24111
|
26067
|
26068
|
26261
|
26336
|
26337
|
26342
|
26347
|
27642
|
27643
|
27644
|
27645
|
27646
|
27711
|
28738
|
28739
|
28740
|
28741
|
28742
|
28743
|
28744
|
28745
|
28746
|
28747
|
28781
|
28782
|
29019
|
29020
|
29021
|
29022
|
29023
|
29024
|
29025
|
29026
|
29027
|
29028
|
29029
|
29442