View | Details | Raw Unified | Return to bug 18073
Collapse All | Expand All

(-)a/admin/columns_settings.yml (+27 lines)
Lines 394-396 modules: Link Here
394
          columnname: date
394
          columnname: date
395
        -
395
        -
396
          columnname: notes
396
          columnname: notes
397
398
    holds:
399
      holds-to-pull:
400
        -
401
          columnname: pull_items
402
        -
403
          columnname: avalaible_items
404
        -
405
          columnname: patrons
406
        -
407
          columnname: patron
408
        -
409
          columnname: title
410
        -
411
          columnname: libraries
412
        -
413
          columnname: call_numbers
414
        -
415
          columnname: copy_numbers
416
        -
417
          columnname: enumeration
418
        -
419
          columnname: itemtypes
420
        -
421
          columnname: locations
422
        -
423
          columnname: hold_date
(-)a/circ/pendingreserves.pl (-1 / +5 lines)
Lines 35-40 use Koha::Biblios; Link Here
35
use C4::Debug;
35
use C4::Debug;
36
use Koha::DateUtils;
36
use Koha::DateUtils;
37
use DateTime::Duration;
37
use DateTime::Duration;
38
use Koha::Patrons;
38
39
39
my $input = new CGI;
40
my $input = new CGI;
40
my $startdate=$input->param('from');
41
my $startdate=$input->param('from');
Lines 122-133 if ( $run_report ) { Link Here
122
            biblio.title,
123
            biblio.title,
123
            biblio.author,
124
            biblio.author,
124
            count(DISTINCT items.itemnumber) as icount,
125
            count(DISTINCT items.itemnumber) as icount,
125
            count(DISTINCT reserves.borrowernumber) as rcount
126
            count(DISTINCT reserves.borrowernumber) as rcount,
127
            CONCAT_WS(' ', borrowers.firstname, borrowers.surname) as l_patron
126
    FROM  reserves
128
    FROM  reserves
127
        LEFT JOIN items ON items.biblionumber=reserves.biblionumber 
129
        LEFT JOIN items ON items.biblionumber=reserves.biblionumber 
128
        LEFT JOIN biblio ON reserves.biblionumber=biblio.biblionumber
130
        LEFT JOIN biblio ON reserves.biblionumber=biblio.biblionumber
129
        LEFT JOIN branchtransfers ON items.itemnumber=branchtransfers.itemnumber
131
        LEFT JOIN branchtransfers ON items.itemnumber=branchtransfers.itemnumber
130
        LEFT JOIN issues ON items.itemnumber=issues.itemnumber
132
        LEFT JOIN issues ON items.itemnumber=issues.itemnumber
133
        LEFT JOIN borrowers ON reserves.borrowernumber=borrowers.borrowernumber
131
    WHERE
134
    WHERE
132
    reserves.found IS NULL
135
    reserves.found IS NULL
133
    $sqldatewhere
136
    $sqldatewhere
Lines 154-159 if ( $run_report ) { Link Here
154
157
155
    while ( my $data = $sth->fetchrow_hashref ) {
158
    while ( my $data = $sth->fetchrow_hashref ) {
156
        my $record = Koha::Biblios->find($data->{biblionumber});
159
        my $record = Koha::Biblios->find($data->{biblionumber});
160
        my $patron = Koha::Patrons->find($data->{borrowernumber});
157
        if ($record){
161
        if ($record){
158
            $data->{subtitle} = [ $record->subtitles ];
162
            $data->{subtitle} = [ $record->subtitles ];
159
        }
163
        }
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/circ/pendingreserves.tt (-13 / +19 lines)
Lines 1-4 Link Here
1
[% USE KohaDates %]
1
[% USE KohaDates %]
2
[% USE ColumnsSettings %]
2
[% USE AuthorisedValues %]
3
[% USE AuthorisedValues %]
3
[%- USE Branches -%]
4
[%- USE Branches -%]
4
[%- USE ItemTypes -%]
5
[%- USE ItemTypes -%]
Lines 9-25 Link Here
9
<!-- Plugin datatables -->
10
<!-- Plugin datatables -->
10
<link rel="stylesheet" type="text/css" href="[% interface %]/[% theme %]/css/datatables.css" />
11
<link rel="stylesheet" type="text/css" href="[% interface %]/[% theme %]/css/datatables.css" />
11
[% INCLUDE 'datatables.inc' %]
12
[% INCLUDE 'datatables.inc' %]
13
[% INCLUDE 'columns_settings.inc' %]
12
<script type="text/JavaScript">
14
<script type="text/JavaScript">
13
//<![CDATA[
15
//<![CDATA[
14
$(document).ready(function() {
16
$(document).ready(function() {
15
  var holdst = $("#holdst").dataTable($.extend(true, {}, dataTablesDefaults, {
17
  var columns_settings = [% ColumnsSettings.GetColumns('circ', 'holds', 'holds-to-pull', 'json') %];
18
  var holdst = KohaTable("#holdst", {
16
    "aoColumnDefs": [
19
    "aoColumnDefs": [
17
        { "sType": "anti-the", "aTargets" : [ "anti-the" ] },
20
        { "sType": "anti-the", "aTargets" : [ "anti-the" ] },
18
        { "sType": "title-string", "aTargets" : [ "title-string" ] },
21
        { "sType": "title-string", "aTargets" : [ "title-string" ] },
19
        { "sType": "string", "aTargets": [ "string-sort" ] } //Target columns that use <br> separators and pull-down menus.
22
        { "sType": "string", "aTargets": [ "string-sort" ] } //Target columns that use <br> separators and pull-down menus.
20
    ],
23
    ],
21
    "sPaginationType": "full_numbers"
24
    "sPaginationType": "full_numbers"
22
  }));
25
  }, columns_settings);
23
  holdst.fnAddFilters("filter");
26
  holdst.fnAddFilters("filter");
24
  [%# add separateData function to cleanse jQuery select lists by breaking apart strings glued with BR tags and then de-duplicating any repeated library codes %]
27
  [%# add separateData function to cleanse jQuery select lists by breaking apart strings glued with BR tags and then de-duplicating any repeated library codes %]
25
  function separateData ( ColumnData ){
28
  function separateData ( ColumnData ){
Lines 47-68 $(document).ready(function() { Link Here
47
      return r+'</select>';
50
      return r+'</select>';
48
  }
51
  }
49
  $("#homebranchfilter").each( function () {
52
  $("#homebranchfilter").each( function () {
50
      $(this).html( createSelect( holdst.fnGetColumnData(4) ) );
53
      $(this).html( createSelect( holdst.fnGetColumnData(5) ) );
51
      $('select', this).change( function () {
54
      $('select', this).change( function () {
52
          var filter_value = $(this).val();
55
          var filter_value = $(this).val();
53
          holdst.fnFilter( filter_value, 4, true );
56
          holdst.fnFilter( filter_value, 5, true );
54
      } );
57
      } );
55
  } );
58
  } );
56
  $("#itypefilter").each( function () {
59
  $("#itypefilter").each( function () {
57
      $(this).html( createSelect( holdst.fnGetColumnData(8) ) );
60
      $(this).html( createSelect( holdst.fnGetColumnData(9) ) );
58
      $('select', this).change( function () {
61
      $('select', this).change( function () {
59
          holdst.fnFilter( $(this).val(), 8 );
62
          holdst.fnFilter( $(this).val(), 9 );
60
      } );
63
      } );
61
  } );
64
  } );
62
  $("#locationfilter").each( function () {
65
  $("#locationfilter").each( function () {
63
      $(this).html( createSelect( holdst.fnGetColumnData(9) ) );
66
      $(this).html( createSelect( holdst.fnGetColumnData(10) ) );
64
      $('select', this).change( function () {
67
      $('select', this).change( function () {
65
          holdst.fnFilter( $(this).val(), 9 );
68
          holdst.fnFilter( $(this).val(), 10 );
66
      } );
69
      } );
67
  } );
70
  } );
68
});
71
});
Lines 94-99 $(document).ready(function() { Link Here
94
        <th>Pull this many items</th>
97
        <th>Pull this many items</th>
95
        <th>Items available</th>
98
        <th>Items available</th>
96
        <th>Patrons with holds</th>
99
        <th>Patrons with holds</th>
100
        <th>First patron</td>
97
        <th class="anti-the">Title</th>
101
        <th class="anti-the">Title</th>
98
        <th class="string-sort">Libraries</th>
102
        <th class="string-sort">Libraries</th>
99
        <th>Available call numbers</th>
103
        <th>Available call numbers</th>
Lines 111-116 $(document).ready(function() { Link Here
111
            <td><p><b>[% reserveloo.pullcount %]</b></p></td>
115
            <td><p><b>[% reserveloo.pullcount %]</b></p></td>
112
            <td>[% reserveloo.count %]</td>
116
            <td>[% reserveloo.count %]</td>
113
            <td>[% reserveloo.rcount %]</td>
117
            <td>[% reserveloo.rcount %]</td>
118
            <td><a href="/cgi-bin/koha/members/moremember.pl?borrowernumber=[% reserveloo.borrowernumber %]">[% reserveloo.name %]</a></td>
114
            <td>
119
            <td>
115
            <p>
120
            <p>
116
                [% INCLUDE 'biblio-default-view.inc' biblionumber = reserveloo.biblionumber %]
121
                [% INCLUDE 'biblio-default-view.inc' biblionumber = reserveloo.biblionumber %]
Lines 122-127 $(document).ready(function() { Link Here
122
            <td>"</td>
127
            <td>"</td>
123
            <td>"</td>
128
            <td>"</td>
124
            <td>"</td>
129
            <td>"</td>
130
            <td>"</td>
125
        [% END %]
131
        [% END %]
126
        <td>
132
        <td>
127
            [% FOREACH holdingbranch IN reserveloo.holdingbranches %]
133
            [% FOREACH holdingbranch IN reserveloo.holdingbranches %]
Lines 153-163 $(document).ready(function() { Link Here
153
        <td><input type="text" class="filter" data-column_num="0" placeholder="Pull this many items" style="width:95%"/></td>
159
        <td><input type="text" class="filter" data-column_num="0" placeholder="Pull this many items" style="width:95%"/></td>
154
        <td><input type="text" class="filter" data-column_num="1" placeholder="Items available" style="width:95%"/></td>
160
        <td><input type="text" class="filter" data-column_num="1" placeholder="Items available" style="width:95%"/></td>
155
        <td><input type="text" class="filter" data-column_num="2" placeholder="Patron holds" style="width:95%"/></td>
161
        <td><input type="text" class="filter" data-column_num="2" placeholder="Patron holds" style="width:95%"/></td>
156
        <td><input type="text" class="filter" data-column_num="3" placeholder="Title" style="width:95%"/></td>
162
        <td><input type="text" class="filter" data-column_num="3" placeholder="Patron name" style="width:95%"/></td>
163
        <td><input type="text" class="filter" data-column_num="4" placeholder="Title" style="width:95%"/></td>
157
        <td id="homebranchfilter"></td>
164
        <td id="homebranchfilter"></td>
158
        <td><input type="text" class="filter" data-column_num="5" placeholder="Call number" style="width:95%"/></td>
165
        <td><input type="text" class="filter" data-column_num="6" placeholder="Call number" style="width:95%"/></td>
159
        <td><input type="text" class="filter" data-column_num="6" placeholder="Available copy" style="width:95%"/></td>
166
        <td><input type="text" class="filter" data-column_num="7" placeholder="Available copy" style="width:95%"/></td>
160
        <td><input type="text" class="filter" data-column_num="7" placeholder="Available enumeration" style="width:95%"/></td>
167
        <td><input type="text" class="filter" data-column_num="8" placeholder="Available enumeration" style="width:95%"/></td>
161
        <td id="itypefilter"></td>
168
        <td id="itypefilter"></td>
162
        <td id="locationfilter"></td>
169
        <td id="locationfilter"></td>
163
        <td></td>
170
        <td></td>
164
- 

Return to bug 18073