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

(-)a/koha-tmpl/intranet-tmpl/prog/en/includes/holds_table.inc (-2 / +6 lines)
Lines 12-18 Link Here
12
        <th>Patron</th>
12
        <th>Patron</th>
13
        <th>Notes</th>
13
        <th>Notes</th>
14
        <th>Date</th>
14
        <th>Date</th>
15
        <th>Expiration</th>
15
        [% IF Koha.Preference('ReserveExpiration') %]
16
            <th>Expiration</th>
17
        [% END %]
16
        <th>Pickup library</th>
18
        <th>Pickup library</th>
17
        <th>Details</th>
19
        <th>Details</th>
18
        [% IF ( CAN_user_reserveforothers_modify_holds_priority ) %]
20
        [% IF ( CAN_user_reserveforothers_modify_holds_priority ) %]
Lines 117-123 Link Here
117
                    [% hold.date | $KohaDates %]
119
                    [% hold.date | $KohaDates %]
118
                [% END %]
120
                [% END %]
119
            </td>
121
            </td>
120
            <td><input type="text" class="datepicker futuredate" value="[% hold.expirationdate | $KohaDates %]" size="10" name="expirationdate" /></td>
122
            [% IF Koha.Preference('ReserveExpiration') %]
123
                <td><input type="text" class="datepicker futuredate" value="[% hold.expirationdate | $KohaDates %]" size="10" name="expirationdate" /></td>
124
            [% END %]
121
125
122
            <td>
126
            <td>
123
                [% IF ( hold.found ) %]
127
                [% IF ( hold.found ) %]
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/circ/circulation.tt (+1 lines)
Lines 1094-1099 Link Here
1094
            relatives_borrowernumbers.push("[% b | html %]");
1094
            relatives_borrowernumbers.push("[% b | html %]");
1095
        [% END %]
1095
        [% END %]
1096
        var SuspendHoldsIntranet = [% ( Koha.Preference('SuspendHoldsIntranet') ) ? 1 : 0 | html %];
1096
        var SuspendHoldsIntranet = [% ( Koha.Preference('SuspendHoldsIntranet') ) ? 1 : 0 | html %];
1097
        var ReserveExpiration = [% ( Koha.Preference('ReserveExpiration') ) ? 1 : 0 | html %];
1097
    </script>
1098
    </script>
1098
    [% Asset.js("js/pages/circulation.js") | $raw %]
1099
    [% Asset.js("js/pages/circulation.js") | $raw %]
1099
    [% Asset.js("js/checkouts.js") | $raw %]
1100
    [% Asset.js("js/checkouts.js") | $raw %]
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/members/holdshistory.tt (-17 / +24 lines)
Lines 48-56 Link Here
48
        <th class="title-string">Expiration date</th>
48
        <th class="title-string">Expiration date</th>
49
        <th class="title-string">Waiting date</th>
49
        <th class="title-string">Waiting date</th>
50
        <th class="title-string">Cancellation date</th>
50
        <th class="title-string">Cancellation date</th>
51
        [% IF show_itemtype_column %]
51
        <th>Requested item type</th>
52
          <th>Requested item type</th>
53
        [% END %]
54
        <th>Status</th>
52
        <th>Status</th>
55
        </tr>
53
        </tr>
56
      </thead>
54
      </thead>
Lines 62-74 Link Here
62
          <td>[% hold.item.barcode | html %]</td>
60
          <td>[% hold.item.barcode | html %]</td>
63
          <td>[% Branches.GetName( hold.branchcode ) | html %]</td>
61
          <td>[% Branches.GetName( hold.branchcode ) | html %]</td>
64
          <td><span title="[% hold.reservedate | html %]">[% hold.reservedate | $KohaDates %]</span></td>
62
          <td><span title="[% hold.reservedate | html %]">[% hold.reservedate | $KohaDates %]</span></td>
65
          <td>
63
            <td>
66
              [% IF hold.expirationdate %]
64
                [% IF hold.expirationdate %]
67
                  <span title="[% hold.expirationdate | html %]">[% hold.expirationdate | $KohaDates %]</span>
65
                    <span title="[% hold.expirationdate | html %]">[% hold.expirationdate | $KohaDates %]</span>
68
              [% ELSE %]
66
                [% ELSE %]
69
                  <span title="0000-00-00"></span>
67
                    <span title="0000-00-00"></span>
70
              [% END %]
68
                [% END %]
71
          </td>
69
            </td>
72
          <td>
70
          <td>
73
              [% IF hold.waitingdate %]
71
              [% IF hold.waitingdate %]
74
                  <span title="[% hold.waitingdate | html %]">[% hold.waitingdate | $KohaDates %]</span>
72
                  <span title="[% hold.waitingdate | html %]">[% hold.waitingdate | $KohaDates %]</span>
Lines 83-89 Link Here
83
                  <span title="0000-00-00"></span>
81
                  <span title="0000-00-00"></span>
84
              [% END %]
82
              [% END %]
85
          </td>
83
          </td>
86
          [% IF show_itemtype_column %]
87
            <td>
84
            <td>
88
              [% IF hold.itemtype %]
85
              [% IF hold.itemtype %]
89
                  [% ItemTypes.GetDescription( hold.itemtype ) | html %]
86
                  [% ItemTypes.GetDescription( hold.itemtype ) | html %]
Lines 91-97 Link Here
91
                  <span>Any item type</span>
88
                  <span>Any item type</span>
92
              [% END %]
89
              [% END %]
93
            </td>
90
            </td>
94
          [% END %]
95
          <td>
91
          <td>
96
          [% IF hold.found == 'F' %]
92
          [% IF hold.found == 'F' %]
97
              Fulfilled
93
              Fulfilled
Lines 134-145 Link Here
134
    [% INCLUDE 'str/members-menu.inc' %]
130
    [% INCLUDE 'str/members-menu.inc' %]
135
    [% Asset.js("js/members-menu.js") | $raw %]
131
    [% Asset.js("js/members-menu.js") | $raw %]
136
    <script>
132
    <script>
133
        var ReserveExpiration = [% ( Koha.Preference('ReserveExpiration') ) ? 1 : 0 | html %];
134
        var show_itemtype_column = [% ( show_itemtype_column ) ? 1 : 0 | html %];
135
        var columns_settings = [% TablesSettings.GetColumns('members', 'holdshistory', 'holdshistory-table', 'json') %];
137
        $(document).ready(function() {
136
        $(document).ready(function() {
138
            var columns_settings = [% TablesSettings.GetColumns('members', 'holdshistory', 'holdshistory-table', 'json') %];
137
            columns_settings.forEach(function(thisCol) {
139
            [% UNLESS show_itemtype_column %]
138
                if( show_itemtype_column == 0 && thisCol.columnname == "itemtype" ){
140
              //Remove item type column settings
139
                    thisCol.cannot_be_modified = 1;
141
              columns_settings = columns_settings.filter(function(c){return c['columnname'] != 'itemtype';});
140
                    thisCol.cannot_be_toggled = 1;
142
            [% END %]
141
                    thisCol.is_hidden = 1;
142
                }
143
                if( ReserveExpiration == 0 && thisCol.columnname == "expirationdate" ){
144
                    thisCol.cannot_be_modified = 1;
145
                    thisCol.cannot_be_toggled = 1;
146
                    thisCol.is_hidden = 1;
147
                }
148
            });
149
143
            var table = KohaTable("table_holdshistory", {
150
            var table = KohaTable("table_holdshistory", {
144
                "sPaginationType": "full",
151
                "sPaginationType": "full",
145
                "aaSorting": [[4, 'desc']],
152
                "aaSorting": [[4, 'desc']],
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/members/moremember-print.tt (-2 / +6 lines)
Lines 80-86 Link Here
80
                <th>Title</th>
80
                <th>Title</th>
81
                <th>Author</th>
81
                <th>Author</th>
82
                <th>Placed on</th>
82
                <th>Placed on</th>
83
                <th>Expires on</th>
83
                [% IF Koha.Preference('ReserveExpiration') %]
84
                    <th>Expires on</th>
85
                [% END %]
84
                <th>Pick up location</th>
86
                <th>Pick up location</th>
85
            </tr>
87
            </tr>
86
88
Lines 89-95 Link Here
89
                    <td>[% reserve.title | html %]</td>
91
                    <td>[% reserve.title | html %]</td>
90
                    <td>[% reserve.author | html %]</td>
92
                    <td>[% reserve.author | html %]</td>
91
                    <td>[% reserve.reservedate | $KohaDates %]</td>
93
                    <td>[% reserve.reservedate | $KohaDates %]</td>
92
                    <td>[% reserve.expirationdate | $KohaDates %]</td>
94
                    [% IF Koha.Preference('ReserveExpiration') %]
95
                        <td>[% reserve.expirationdate | $KohaDates %]</td>
96
                    [% END %]
93
                    <td>[% reserve.waiting_at | html %]</td>
97
                    <td>[% reserve.waiting_at | html %]</td>
94
                </tr>
98
                </tr>
95
            [% END %]
99
            [% END %]
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/members/moremember.tt (+1 lines)
Lines 935-940 Link Here
935
            relatives_borrowernumbers.push("[% b | html %]");
935
            relatives_borrowernumbers.push("[% b | html %]");
936
        [% END %]
936
        [% END %]
937
        var SuspendHoldsIntranet = [% ( Koha.Preference('SuspendHoldsIntranet') ) ? 1 : 0 | html %];
937
        var SuspendHoldsIntranet = [% ( Koha.Preference('SuspendHoldsIntranet') ) ? 1 : 0 | html %];
938
        var ReserveExpiration = [% ( Koha.Preference('ReserveExpiration') ) ? 1 : 0 | html %];
938
    </script>
939
    </script>
939
    [% Asset.js("js/pages/circulation.js") | $raw %]
940
    [% Asset.js("js/pages/circulation.js") | $raw %]
940
    [% Asset.js("js/checkouts.js") | $raw %]
941
    [% Asset.js("js/checkouts.js") | $raw %]
(-)a/koha-tmpl/intranet-tmpl/prog/js/holds.js (-1 / +4 lines)
Lines 100-106 $(document).ready(function() { Link Here
100
                            else { return oObj.branchcode.escapeHtml() || ""; }
100
                            else { return oObj.branchcode.escapeHtml() || ""; }
101
                        }
101
                        }
102
                    },
102
                    },
103
                    { "data": { _: "expirationdate_formatted", "sort": "expirationdate" } },
103
                    {
104
                        "visible": ReserveExpiration,
105
                        "data": { _: "expirationdate_formatted", "sort": "expirationdate" }
106
                    },
104
                    {
107
                    {
105
                        "mDataProp": function( oObj ) {
108
                        "mDataProp": function( oObj ) {
106
                            if ( oObj.priority && parseInt( oObj.priority ) && parseInt( oObj.priority ) > 0 ) {
109
                            if ( oObj.priority && parseInt( oObj.priority ) && parseInt( oObj.priority ) > 0 ) {
(-)a/koha-tmpl/opac-tmpl/bootstrap/en/includes/holds-table.inc (-16 / +20 lines)
Lines 16-22 Link Here
16
                    [% ELSE %]
16
                    [% ELSE %]
17
                        <th class="psort title-string">Placed on</th>
17
                        <th class="psort title-string">Placed on</th>
18
                    [% END %]
18
                    [% END %]
19
                    <th class="title-string">Expires on</th>
19
                    [% IF Koha.Preference('ReserveExpiration') %]
20
                        <th class="title-string">Expires on</th>
21
                    [% END %]
20
                    [% UNLESS( singleBranchMode) %]
22
                    [% UNLESS( singleBranchMode) %]
21
                        <th>Pick up location</th>
23
                        <th>Pick up location</th>
22
                    [% END %]
24
                    [% END %]
Lines 68-90 Link Here
68
                                [% HOLD.reservedate | $KohaDates %]
70
                                [% HOLD.reservedate | $KohaDates %]
69
                            </span>
71
                            </span>
70
                        </td>
72
                        </td>
71
                        <td class="expirationdate">
73
                        [% IF Koha.Preference('ReserveExpiration') %]
72
                            [% IF ! HOLD.found %]
74
                            <td class="expirationdate">
73
                                [% IF ( HOLD.expirationdate ) %]
75
                                [% IF ! HOLD.found %]
74
                                    <span title="[% HOLD.expirationdate | html %]">
76
                                    [% IF ( HOLD.expirationdate ) %]
75
                                        <span class="tdlabel">Expiration:</span>
77
                                        <span title="[% HOLD.expirationdate | html %]">
76
                                            [% HOLD.expirationdate | $KohaDates %]
78
                                            <span class="tdlabel">Expiration:</span>
77
                                    </span>
79
                                                [% HOLD.expirationdate | $KohaDates %]
80
                                        </span>
81
                                    [% ELSE %]
82
                                        <span title="0000-00-00">
83
                                            <span class="tdlabel">Expiration:</span>
84
                                            Never expires
85
                                        </span>
86
                                    [% END %]
78
                                [% ELSE %]
87
                                [% ELSE %]
79
                                    <span title="0000-00-00">
88
                                    <span title="0000-00-00">-</span>
80
                                        <span class="tdlabel">Expiration:</span>
81
                                        Never expires
82
                                    </span>
83
                                [% END %]
89
                                [% END %]
84
                            [% ELSE %]
90
                            </td>
85
                                <span title="0000-00-00">-</span>
91
                        [% END %]
86
                            [% END %]
87
                        </td>
88
                        [% UNLESS( singleBranchMode) %]
92
                        [% UNLESS( singleBranchMode) %]
89
                            <td class="branch">
93
                            <td class="branch">
90
                                <span class="tdlabel">Pick up location:</span>
94
                                <span class="tdlabel">Pick up location:</span>
(-)a/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-holdshistory.tt (-9 / +12 lines)
Lines 90-96 Link Here
90
                                        <th>Barcode</th>
90
                                        <th>Barcode</th>
91
                                        <th>Library</th>
91
                                        <th>Library</th>
92
                                        <th class="title-string">Hold date</th>
92
                                        <th class="title-string">Hold date</th>
93
                                        <th class="title-string">Expiration date</th>
93
                                        [% IF Koha.Preference('ReserveExpiration') %]
94
                                            <th class="title-string">Expiration date</th>
95
                                        [% END %]
94
                                        <th class="title-string">Waiting date</th>
96
                                        <th class="title-string">Waiting date</th>
95
                                        <th class="title-string">Cancellation date</th>
97
                                        <th class="title-string">Cancellation date</th>
96
                                        [% IF show_itemtype_column %]
98
                                        [% IF show_itemtype_column %]
Lines 107-119 Link Here
107
                                        <td>[% hold.item.barcode | html %]</td>
109
                                        <td>[% hold.item.barcode | html %]</td>
108
                                        <td>[% Branches.GetName( hold.branchcode ) | html %]</td>
110
                                        <td>[% Branches.GetName( hold.branchcode ) | html %]</td>
109
                                        <td><span title="[% hold.reservedate | html %]">[% hold.reservedate | $KohaDates %]</span></td>
111
                                        <td><span title="[% hold.reservedate | html %]">[% hold.reservedate | $KohaDates %]</span></td>
110
                                        <td>
112
                                        [% IF Koha.Preference('ReserveExpiration') %]
111
                                            [% IF hold.expirationdate %]
113
                                            <td>
112
                                                <span title="[% hold.expirationdate | html %]">[% hold.expirationdate | $KohaDates %]</span>
114
                                                [% IF hold.expirationdate %]
113
                                            [% ELSE %]
115
                                                    <span title="[% hold.expirationdate | html %]">[% hold.expirationdate | $KohaDates %]</span>
114
                                                <span title="0000-00-00"></span>
116
                                                [% ELSE %]
115
                                            [% END %]
117
                                                    <span title="0000-00-00"></span>
116
                                        </td>
118
                                                [% END %]
119
                                            </td>
120
                                        [% END %]
117
                                        <td>
121
                                        <td>
118
                                            [% IF hold.waitingdate %]
122
                                            [% IF hold.waitingdate %]
119
                                                <span title="[% hold.waitingdate | html %]">[% hold.waitingdate | $KohaDates %]</span>
123
                                                <span title="[% hold.waitingdate | html %]">[% hold.waitingdate | $KohaDates %]</span>
120
- 

Return to bug 24194