Josef Moravec
dad848a0a7
Test plan: 1) Apply the patch 2) Type into search form patron's name & check his date of birth in autocompletion 3) Go to intranet/cgi-bin/koha/members/member.pl & submit a search with more than one result .. now should in the table appear patron's date of birth 4) Try show/hide columns section if it works correctly for date of birth 5) Go to intranet/cgi-bin/koha/admin/columns_settings.pl -> go to patrons section & check there is dateofbirth & it's functionality Signed-off-by: Frederic Demians <f.demians@tamil.fr> Works as described. Syspref dateformat respected. Column dateofbirth configurable, but mandatory on autocompletion search result. Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
47 lines
2.7 KiB
Text
47 lines
2.7 KiB
Text
[% USE To %]
|
|
[% USE AuthorisedValues %]
|
|
[% USE KohaDates %]
|
|
{
|
|
"sEcho": [% sEcho %],
|
|
"iTotalRecords": [% iTotalRecords %],
|
|
"iTotalDisplayRecords": [% iTotalDisplayRecords %],
|
|
"aaData": [
|
|
[% FOREACH data IN aaData %]
|
|
{
|
|
[% IF CAN_user_tools_manage_patron_lists %]
|
|
"dt_borrowernumber":
|
|
"<input type='checkbox' class='selection' name='borrowernumber' value='[% data.borrowernumber %]' />",
|
|
[% END %]
|
|
"dt_cardnumber":
|
|
"[% data.cardnumber | html %]",
|
|
"dt_name":
|
|
"<span style='white-space:nowrap'><a href='/cgi-bin/koha/members/moremember.pl?borrowernumber=[% data.borrowernumber %]'>[% INCLUDE 'patron-title.inc' borrowernumber = data.borrowernumber category_type = data.category_type firstname = data.firstname surname = data.surname othernames = data.othernames invert_name = 1 %]</a><br />[% INCLUDE escape_address data = data %]</span>",
|
|
"dt_dateofbirth":
|
|
"[% data.dateofbirth | $KohaDates %]",
|
|
"dt_category":
|
|
"[% data.category_description |html %] ([% data.category_type |html %])",
|
|
"dt_branch":
|
|
"[% data.branchname |html %]",
|
|
"dt_dateexpiry":
|
|
"[% data.dateexpiry %]",
|
|
"dt_od_checkouts":
|
|
"[% IF data.overdues %]<span class='overdue'><strong>[% data.overdues %]</strong></span>[% ELSE %][% data.overdues %][% END %] / [% data.issues %]",
|
|
"dt_fines":
|
|
"<span style='text-align: right; display: block;'>[% IF data.fines < 0 %]<span class='credit'>[% data.fines |html %]</span> [% ELSIF data.fines > 0 %] <span class='debit'><strong>[% data.fines |html %]</strong></span> [% ELSE %] [% data.fines |html%] [% END %]</span>",
|
|
"dt_borrowernotes":
|
|
"[% data.borrowernotes.replace('\\\\' , '\\\\') |html |html_line_break |collapse %]",
|
|
"dt_action":
|
|
"<a href='/cgi-bin/koha/members/memberentry.pl?op=modify&destination=circ&borrowernumber=[% data.borrowernumber %]'>Edit</a>",
|
|
"borrowernumber":
|
|
"[% data.borrowernumber %]"
|
|
}[% UNLESS loop.last %],[% END %]
|
|
[% END %]
|
|
]
|
|
}
|
|
[% BLOCK escape_address %]
|
|
[%~ SET address = data.streetnumber _ ' ' %]
|
|
[%~ IF data.streettype %][% address = address _ AuthorisedValues.GetByCode( 'ROADTYPE', data.streettype ) _ ' ' %][% END %]
|
|
[%~ IF data.address %][% address = address _ data.address _ ' ' %][% END %]
|
|
[%~ IF data.address2 %][% address = address _ data.address2 _ ' ' %][% END %]
|
|
[%~ To.json( address ) ~%]
|
|
[% END %]
|