Bug 19398: Format date of birth in circ patron search
[koha.git] / koha-tmpl / intranet-tmpl / prog / en / includes / circ-patron-search-results.inc
1 [% USE KohaDates %]
2 <script type="text/javascript">
3     $(document).ready(function() {
4         $(".clickable").click(function() {
5             window.document.location = $(this).data('url');
6         });
7         var table = $("#table_borrowers").dataTable($.extend(true, {}, dataTablesDefaults, {
8             "aaSorting": [ 0, "asc" ],
9             "sDom": "t",
10             "iDisplayLength": -1
11         }));
12     });
13 </script>
14 <legend>Patron selection</legend>
15 <table id="table_borrowers" class="table_borrowers">
16     <thead>
17         <tr>
18             <th>Name</th>
19             <th>Card number</th>
20             <th>Date of birth</th>
21             <th>Category</th>
22             <th>Library</th>
23             <th>Address</th>
24         </tr>
25     </thead>
26     <tbody>
27         [% FOREACH borrower IN borrowers %]
28             [% IF ( destination == "circ" ) %]
29                 <tr class="clickable" data-url="/cgi-bin/koha/circ/circulation.pl?borrowernumber=[% borrower.borrowernumber %]">
30                     <td><a href="/cgi-bin/koha/circ/circulation.pl?borrowernumber=[% borrower.borrowernumber %]">[% borrower.surname %], [% borrower.firstname %]</a></td>
31             [% ELSE %]
32                 <tr class="clickable" data-url="/cgi-bin/koha/reserve/request.pl?borrowernumber=[% borrower.borrowernumber %]&amp;biblionumber=[% biblionumber %]">
33                     <td><a href="/cgi-bin/koha/reserve/request.pl?borrowernumber=[% borrower.borrowernumber %]&amp;biblionumber=[% biblionumber %]">[% borrower.surname %], [% borrower.firstname %]</a></td>
34             [% END %]
35                 <td>[% borrower.cardnumber %]</td>
36                 <td>[% borrower.dateofbirth | $KohaDates %]</td>
37                 <td>[% Categories.GetName( borrower.categorycode ) %]</td>
38                 <td>[% Branches.GetName( borrower.branchcode ) %]</td>
39                 <td>[% borrower.address %]</td>
40             </tr>
41         [% END %]
42     </tbody>
43 </table>