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

(-)a/koha-tmpl/intranet-tmpl/prog/en/includes/checkouts-table.inc (-85 / +84 lines)
Lines 1-98 Link Here
1
[% USE Koha %]
1
[% USE Koha %]
2
[% PROCESS 'modal-claims.inc' %]
2
[% PROCESS 'modal-claims.inc' %]
3
[% INCLUDE 'format_price.inc' %]
3
[% INCLUDE 'format_price.inc' %]
4
<div id="checkouts" role="tabpanel" class="tab-pane active">
5
    [% IF ( issuecount ) %]
6
        <div id="issues-table-loading-message">
7
            <p>
8
                <a id="issues-table-load-now-button" href="#" class="btn btn-default"><i class="fa fa-book"></i> Show checkouts</a>
9
            </p>
10
        </div>
11
        <form name="issues" action="/cgi-bin/koha/tools/export.pl" method="post">
12
            <table id="issues-table" style="width: 100% !Important;">
13
                <thead>
14
                    <tr>
15
                        <th scope="col">&nbsp;</th>
16
                        <th scope="col">&nbsp;</th>
17
                        <th scope="col">Due date</th>
18
                        <th scope="col">Due date</th>
19
                        <th scope="col">Title</th>
20
                        <th scope="col">Record-level item type</th>
21
                        <th scope="col">Item type</th>
22
                        <th scope="col">Collection</th>
23
                        <th scope="col">Location</th>
24
                        <th scope="col">Home library</th>
25
                        <th scope="col">&nbsp;</th>
26
                        <th scope="col">Checked out on</th>
27
                        <th scope="col">Checked out from</th>
28
                        <th scope="col">Call number</th>
29
                        <th scope="col">Copy number</th>
30
                        <th scope="col">Charge</th>
31
                        <th scope="col">Fine</th>
32
                        <th scope="col">Price</th>
33
                        <th scope="col">Renew <p class="column-tool"><a href="#" id="CheckAllRenewals">select all</a> | <a href="#" id="UncheckAllRenewals">none</a></p></th>
34
                        <th scope="col">Check in <p class="column-tool"><a href="#" id="CheckAllCheckins">select all</a> | <a href="#" id="UncheckAllCheckins">none</a></p></th>
35
                        <th scope="col">Return claims</th>
36
                        <th scope="col">Export <p class="column-tool"><a href="#" id="CheckAllExports">select all</a> | <a href="#" id="UncheckAllExports">none</a></p></th>
37
                    </tr>
38
                </thead>
39
                [% INCLUDE 'checkouts-table-footer.inc' %]
40
            </table>
41
4
42
            <label for="issues-table-load-immediately">Always show checkouts immediately</label>
5
[% IF ( issuecount ) %]
43
            <input id="issues-table-load-immediately" type="checkbox" />
6
    <div id="issues-table-loading-message">
7
        <p>
8
            <a id="issues-table-load-now-button" href="#" class="btn btn-default"><i class="fa fa-book"></i> Show checkouts</a>
9
        </p>
10
    </div>
11
    <form name="issues" action="/cgi-bin/koha/tools/export.pl" method="post">
12
        <table id="issues-table" style="width: 100% !Important;">
13
            <thead>
14
                <tr>
15
                    <th scope="col">&nbsp;</th>
16
                    <th scope="col">&nbsp;</th>
17
                    <th scope="col">Due date</th>
18
                    <th scope="col">Due date</th>
19
                    <th scope="col">Title</th>
20
                    <th scope="col">Record-level item type</th>
21
                    <th scope="col">Item type</th>
22
                    <th scope="col">Collection</th>
23
                    <th scope="col">Location</th>
24
                    <th scope="col">Home library</th>
25
                    <th scope="col">&nbsp;</th>
26
                    <th scope="col">Checked out on</th>
27
                    <th scope="col">Checked out from</th>
28
                    <th scope="col">Call number</th>
29
                    <th scope="col">Copy number</th>
30
                    <th scope="col">Charge</th>
31
                    <th scope="col">Fine</th>
32
                    <th scope="col">Price</th>
33
                    <th scope="col">Renew <p class="column-tool"><a href="#" id="CheckAllRenewals">select all</a> | <a href="#" id="UncheckAllRenewals">none</a></p></th>
34
                    <th scope="col">Check in <p class="column-tool"><a href="#" id="CheckAllCheckins">select all</a> | <a href="#" id="UncheckAllCheckins">none</a></p></th>
35
                    <th scope="col">Return claims</th>
36
                    <th scope="col">Export <p class="column-tool"><a href="#" id="CheckAllExports">select all</a> | <a href="#" id="UncheckAllExports">none</a></p></th>
37
                </tr>
38
            </thead>
39
            [% INCLUDE 'checkouts-table-footer.inc' %]
40
        </table>
44
41
45
            <div id="issues-table-actions">
42
        <label for="issues-table-load-immediately">Always show checkouts immediately</label>
46
                <fieldset class="action">
43
        <input id="issues-table-load-immediately" type="checkbox" />
47
                    [% IF ( CAN_user_circulate_override_renewals ) %]
44
48
                        [% IF Koha.Preference( 'AllowRenewalLimitOverride' ) || Koha.Preference( 'AllowRenewalOnHoldOverride' ) %]
45
        <div id="issues-table-actions">
49
                            <label for="override_limit">Override renewal restrictions:</label>
46
            <fieldset class="action">
50
                            <input type="checkbox" name="override_limit" id="override_limit" value="1" />
47
                [% IF ( CAN_user_circulate_override_renewals ) %]
51
                        [% END %]
48
                    [% IF Koha.Preference( 'AllowRenewalLimitOverride' ) || Koha.Preference( 'AllowRenewalOnHoldOverride' ) %]
49
                        <label for="override_limit">Override renewal restrictions:</label>
50
                        <input type="checkbox" name="override_limit" id="override_limit" value="1" />
52
                    [% END %]
51
                    [% END %]
53
                    [% IF ( CAN_user_circulate_circulate_remaining_permissions ) %]
52
                [% END %]
54
                        [% IF Koha.Preference( 'UnseenRenewals' ) %]
53
                [% IF ( CAN_user_circulate_circulate_remaining_permissions ) %]
55
                            <label id="renew_as_unseen_label" for="override_limit">Renew as &quot;unseen&quot; if appropriate:</label>
54
                    [% IF Koha.Preference( 'UnseenRenewals' ) %]
56
                            <input type="checkbox" name="renew_as_unseen" id="renew_as_unseen_checkbox" value="1" />
55
                        <label id="renew_as_unseen_label" for="override_limit">Renew as &quot;unseen&quot; if appropriate:</label>
57
                        [% END %]
56
                        <input type="checkbox" name="renew_as_unseen" id="renew_as_unseen_checkbox" value="1" />
58
                        <button class="btn btn-default" id="RenewCheckinChecked"><i class="fa fa-check"></i> Renew or check in selected items</button>
59
                        <button class="btn btn-default" id="RenewAll"><i class="fa fa-book"></i> Renew all</button>
60
                    [% END %]
57
                    [% END %]
61
                </fieldset>
58
                    <button class="btn btn-default" id="RenewCheckinChecked"><i class="fa fa-check"></i> Renew or check in selected items</button>
62
59
                    <button class="btn btn-default" id="RenewAll"><i class="fa fa-book"></i> Renew all</button>
63
                [% IF Koha.Preference('ExportCircHistory') %]
60
                [% END %]
64
                    <fieldset>
61
            </fieldset>
65
                        <label for="issues-table-output-format"><strong>Export checkouts using format:</strong></label>
66
                        <select name="issues-table-output-format" id="issues-table-output-format">
67
                            <option value="iso2709_995">MARC with items</option>
68
                            <option value="iso2709">MARC without items</option>
69
                            [% IF csv_profiles.count %]
70
                                <option value="csv">CSV</option>
71
                            [% END %]
72
                        </select>
73
62
63
            [% IF Koha.Preference('ExportCircHistory') %]
64
                <fieldset>
65
                    <label for="issues-table-output-format"><strong>Export checkouts using format:</strong></label>
66
                    <select name="issues-table-output-format" id="issues-table-output-format">
67
                        <option value="iso2709_995">MARC with items</option>
68
                        <option value="iso2709">MARC without items</option>
74
                        [% IF csv_profiles.count %]
69
                        [% IF csv_profiles.count %]
75
                            <select name="csv_profile_id">
70
                            <option value="csv">CSV</option>
76
                                [% FOREACH csv_profile IN csv_profiles %]
77
                                    <option value="[% csv_profile.export_format_id | html %]">[% csv_profile.profile | html %]</option>
78
                                [% END %]
79
                            </select>
80
                        [% END %]
71
                        [% END %]
81
                        <label for="export_items_bundle_contents">Export items bundle contents</label> <input type="checkbox" name="export_items_bundle_contents" id="export_items_bundle_contents">
72
                    </select>
82
                        <label for="export_remove_fields">Don't export fields:</label> <input type="text" id="export_remove_fields" name="export_remove_fields" value="[% Koha.Preference('ExportRemoveFields') | html %]" title="Use for MARC exports" />
73
83
                        <input type="hidden" name="op" value="export" />
74
                    [% IF csv_profiles.count %]
84
                        <input type="hidden" id="output_format" name="output_format" value="iso2709" />
75
                        <select name="csv_profile_id">
85
                        <input type="hidden" id="dont_export_item" name="dont_export_item" value="0" />
76
                            [% FOREACH csv_profile IN csv_profiles %]
86
                        <input type="hidden" id="record_type" name="record_type" value="bibs" />
77
                                <option value="[% csv_profile.export_format_id | html %]">[% csv_profile.profile | html %]</option>
87
                        <button class="btn btn-default btn-sm" id="export_submit"><i class="fa fa-download"></i> Export</button>
78
                            [% END %]
88
                    </fieldset>
79
                        </select>
89
                [% END %]
80
                    [% END %]
90
            </div>
81
                    <label for="export_items_bundle_contents">Export items bundle contents</label> <input type="checkbox" name="export_items_bundle_contents" id="export_items_bundle_contents">
91
        </form>
82
                    <label for="export_remove_fields">Don't export fields:</label> <input type="text" id="export_remove_fields" name="export_remove_fields" value="[% Koha.Preference('ExportRemoveFields') | html %]" title="Use for MARC exports" />
92
    [% ELSE %]
83
                    <input type="hidden" name="op" value="export" />
93
        <p>Patron has nothing checked out.</p>
84
                    <input type="hidden" id="output_format" name="output_format" value="iso2709" />
94
    [% END %]
85
                    <input type="hidden" id="dont_export_item" name="dont_export_item" value="0" />
95
</div>
86
                    <input type="hidden" id="record_type" name="record_type" value="bibs" />
87
                    <button class="btn btn-default btn-sm" id="export_submit"><i class="fa fa-download"></i> Export</button>
88
                </fieldset>
89
            [% END %]
90
        </div>
91
    </form>
92
[% ELSE %]
93
    <p>Patron has nothing checked out.</p>
94
[% END %]
96
95
97
<!-- Claims Returned Modal -->
96
<!-- Claims Returned Modal -->
98
[% PROCESS 'modal-claims-display' %]
97
[% PROCESS 'modal-claims-display' %]
(-)a/koha-tmpl/intranet-tmpl/prog/en/includes/html_helpers.inc (-1 / +1 lines)
Lines 393-399 Link Here
393
    [% ELSE %]
393
    [% ELSE %]
394
        <li role="presentation">
394
        <li role="presentation">
395
    [% END %]
395
    [% END %]
396
        <a href="#[% tabname | uri %]_panel" data-tabname="[% tabname | uri %]" aria-controls="[% tabname | uri %]_panel" role="tab" data-toggle="tab">
396
        <a href="#[% tabname | uri %]_panel" id="[% tabname | uri %]-tab" data-tabname="[% tabname | uri %]" aria-controls="[% tabname | uri %]_panel" role="tab" data-toggle="tab">
397
            [% content | $raw %]
397
            [% content | $raw %]
398
        </a>
398
        </a>
399
    </li>
399
    </li>
(-)a/koha-tmpl/intranet-tmpl/prog/en/includes/patron-article-requests.inc (-2 lines)
Lines 1-6 Link Here
1
[% USE Context %]
1
[% USE Context %]
2
[% SET current_article_requests = Context.Scalar( Context.Scalar( patron, 'article_requests' ), 'filter_by_current' ) %]
2
[% SET current_article_requests = Context.Scalar( Context.Scalar( patron, 'article_requests' ), 'filter_by_current' ) %]
3
<div id="article-requests" role="tabpanel" class="tab-pane">
4
[% IF current_article_requests.count > 0 %]
3
[% IF current_article_requests.count > 0 %]
5
    <table id="article-requests-table" class="table table-bordered table-striped">
4
    <table id="article-requests-table" class="table table-bordered table-striped">
6
        <thead>
5
        <thead>
Lines 102-105 Link Here
102
    [% ELSE %]
101
    [% ELSE %]
103
        <span>Patron has no current article requests.</span>
102
        <span>Patron has no current article requests.</span>
104
    [% END %]
103
    [% END %]
105
</div>
(-)a/koha-tmpl/intranet-tmpl/prog/en/includes/patron-detail-tabs.inc (+227 lines)
Line 0 Link Here
1
<!-- patron-detail-tabs.inc -->
2
[% USE raw %]
3
[% PROCESS 'html_helpers.inc' %]
4
[% WRAPPER tabs id= "finesholdsissues" %]
5
    [% WRAPPER tabs_nav %]
6
        [% WRAPPER tab_item tabname= "checkouts" bt_active= 1 %]
7
            <span>Checkouts ([% issuecount || 0 | html %])</span>
8
        [% END %]
9
10
        [% IF relatives_issues_count %]
11
            [% WRAPPER tab_item tabname= "relatives-issues" %]
12
                <span>Relatives' checkouts ([% relatives_issues_count | html %])</span>
13
            [% END %]
14
        [% END %]
15
16
        [% IF ( fines ) %]
17
            [% WRAPPER tab_item tabname= "finesandcharges" %]
18
                <span>Charges ([% fines | $Price %])</span>
19
            [% END %]
20
        [% END %]
21
22
        [% IF ( guarantees_fines ) %]
23
            [% WRAPPER tab_item tabname= "guarantees_finesandcharges" %]
24
                <span>Guarantees' charges ([% guarantees_fines | $Price %])</span>
25
            [% END %]
26
        [% END %]
27
28
        [% IF ( CAN_user_circulate_circulate_remaining_permissions ) %]
29
            [% WRAPPER tab_item tabname= "holds" %]
30
                <span>Holds ([% holds_count || 0 | html %])</span>
31
            [% END %]
32
        [% END %]
33
34
        [% IF Koha.Preference('UseRecalls') %]
35
            [% WRAPPER tab_item tabname= "recalls" %]
36
                <span>Recalls ([% recalls.count || 0 | html %])</span>
37
            [% END %]
38
        [% END %]
39
40
        [% IF Koha.Preference('ArticleRequests') %]
41
            [% SET article_requests = Context.Scalar( Context.Scalar( patron, 'article_requests' ), 'filter_by_current') %]
42
            [% WRAPPER tab_item tabname= "article-requests" %]
43
                <span>Article requests ([% article_requests.count || 0 | html %])</span>
44
            [% END %]
45
        [% END %]
46
47
        [% IF Koha.Preference('ClaimReturnedLostValue') || Koha.Preference('BundleLostValue') %]
48
            [% WRAPPER tab_item tabname= "return-claims" %]
49
                <span>Claims</span>
50
                [% IF ( patron.return_claims.count ) %]
51
                    ([% IF patron.return_claims.resolved.count == 0 %]
52
                        <span title="Resolved claims" class="label label-default" id="return-claims-count-resolved">[% patron.return_claims.resolved.count | html %]</span>
53
                    [% ELSE %]
54
                        <span title="Resolved claims" class="label label-success" id="return-claims-count-resolved">[% patron.return_claims.resolved.count | html %]</span>
55
                    [% END %]
56
                    [% IF patron.return_claims.unresolved.count == 0 %]
57
                        <span title="Unresolved claims" class="label label-default" id="return-claims-count-unresolved">[% patron.return_claims.unresolved.count | html %]</span>
58
                    [% ELSE %]
59
                        <span title="Unresolved claims" class="label label-warning" id="return-claims-count-unresolved">[% patron.return_claims.unresolved.count | html %]</span>
60
                    [% END %])
61
                [% ELSE %]
62
                    [% no_claims = 0 %]
63
                    (<span title="Resolved claims" class="label label-default" id="return-claims-count-resolved">[% no_claims | html %]</span>
64
                    <span title="Unresolved claims" class="label label-default" id="return-claims-count-unresolved">[% no_claims | html %]</span>)
65
                [% END # /IF patron.return_claims.count %]
66
            [% END # /WRAPPER tab_item return-claims %]
67
        [% END %]
68
69
        [% WRAPPER tab_item tabname= "reldebarments" %]
70
            <span>Restrictions ([% patron.restrictions.count || 0 | html %])</span>
71
        [% END %]
72
73
        [% SET enrollments = patron.get_club_enrollments %]
74
        [% SET enrollable  = patron.get_enrollable_clubs(0) %] <!-- 0 => not OPAC -->
75
        [% IF CAN_user_clubs && ( enrollable.count || enrollments.count ) %]
76
            [% WRAPPER tab_item tabname= "clubs" %]
77
                <span>Clubs ([% enrollments.count | html %]/[% enrollable.count | html %])</span>
78
            [% END %]
79
        [% END %]
80
    [% END # /WRAPPER tabs_nav %]
81
82
83
    [% WRAPPER tab_panels %]
84
        [% WRAPPER tab_panel tabname="checkouts" bt_active= 1 %]
85
            [% INCLUDE "checkouts-table.inc" %]
86
        [% END # /tab_panel# %]
87
88
        [% WRAPPER tab_panel tabname="relatives-issues" %]
89
            [% INCLUDE "relatives-issues-table.inc" %]
90
        [% END # /tab_panel# %]
91
92
        [% WRAPPER tab_panel tabname="finesandcharges" %]
93
            [% IF ( fines ) %]
94
                <p>Total due: [% fines | $Price %]</p>
95
            [% ELSE %]
96
                <p>No outstanding charges</p>
97
            [% END %]
98
        [% END # /tab_panel# %]
99
100
        [% IF ( guarantees_fines ) %]
101
            [% WRAPPER tab_panel tabname="guarantees_finesandcharges" %]
102
                <table id="tguaranteesfines">
103
                    <thead>
104
                        <tr>
105
                            <th>Guarantee</th>
106
                            <th>Amount outstanding</th>
107
                        </tr>
108
                    </thead>
109
                    [% FOREACH guarantee IN guarantees %]
110
                        <tr>
111
                            <td>[% INCLUDE 'patron-title.inc' patron=guarantee hide_patron_infos_if_needed=1 %]</td>
112
                            [% IF logged_in_user.can_see_patron_infos( guarantee ) %]
113
                                <td>[% guarantee.account.balance | $Price %]</td>
114
                            [% ELSE %]
115
                                <td>-</td>
116
                            [% END %]
117
                        </tr>
118
                    [% END %]
119
                    <tfoot>
120
                        <td>Total due</td>
121
                        <td>[% guarantees_fines | $Price %]</td>
122
                    </tfoot>
123
                </table>
124
            [% END # /tab_panel# %]
125
        [% END # /tab_panel# %]
126
127
        [% IF CAN_user_clubs && ( enrollments.count || enrollable.count ) %]
128
            [% WRAPPER tab_panel tabname="clubs" %]
129
                Loading...
130
            [% END # /tab_panel# %]
131
        [% END %]
132
133
        [% WRAPPER tab_panel tabname="reldebarments" %]
134
            [% INCLUDE 'patron-restrictions-tab.inc' %]
135
        [% END # /tab_panel# %]
136
137
        [% IF ( CAN_user_circulate_circulate_remaining_permissions ) %]
138
            [% WRAPPER tab_panel tabname="holds" %]
139
                [% IF ( holds_count ) %]
140
                    <form action="/cgi-bin/koha/reserve/modrequest.pl" method="post">
141
                        <input type="hidden" name="from" value="circ" />
142
                        <table id="holds-table" style="width: 100% !Important;">
143
                            <thead>
144
                                <tr>
145
                                    <th>Hold date</th>
146
                                    <th>Title</th>
147
                                    <th>Call number</th>
148
                                    <th>Item type</th>
149
                                    <th>Barcode</th>
150
                                    <th>Pickup at</th>
151
                                    <th>Expiration</th>
152
                                    <th>Priority</th>
153
                                    <th>Delete?</th>
154
                                    <th>Suspend?</th>
155
                                    <th>Status</th>
156
                                </tr>
157
                            </thead>
158
                        </table>
159
160
                        <fieldset class="action">
161
                            <input type="submit" class="cancel" name="submit" value="Cancel marked holds" />
162
163
                            [% SET hold_cancellation = AuthorisedValues.GetAuthValueDropbox('HOLD_CANCELLATION') %]
164
                            [% IF hold_cancellation.count %]
165
                                <label for="cancellation-reason">Cancellation reason:</label>
166
                                <select name="cancellation-reason">
167
                                    <option value="">No reason given</option>
168
                                    [% FOREACH reason IN hold_cancellation %]
169
                                        <option value="[% reason.authorised_value | html %]">[% reason.lib | html %]</option>
170
                                    [% END %]
171
                                </select>
172
                            [% END %]
173
                        </fieldset>
174
                    </form>
175
176
                    [% IF Koha.Preference('SuspendHoldsIntranet') %]
177
                        <form action="/cgi-bin/koha/reserve/modrequest_suspendall.pl" method="post">
178
                            <fieldset class="action">
179
                                <input type="hidden" name="from" value="[% patronpage | html %]" />
180
                                <input type="hidden" name="borrowernumber" value="[% patron.borrowernumber | html %]" />
181
                                <input type="submit" class="btn btn-primary" value="Suspend all holds" />
182
183
                                [% IF Koha.Preference('AutoResumeSuspendedHolds') %]
184
                                    <label for="suspend_until">until</label>
185
                                    <input type="text" size="10" id="suspend_until" name="suspend_until" class="flatpickr" data-flatpickr-futuredate="true"/>
186
                                    <span class="hint">Specify date on which to resume [% INCLUDE 'date-format.inc' %]: </span>
187
                                [% END %]
188
                            </fieldset>
189
                        </form>
190
191
                        <form action="/cgi-bin/koha/reserve/modrequest_suspendall.pl" method="post">
192
                            <fieldset class="action">
193
                                <input type="hidden" name="from" value="borrower" />
194
                                <input type="hidden" name="borrowernumber" value="[% patron.borrowernumber | html %]" />
195
                                <input type="hidden" name="suspend" value="0" />
196
                                <input type="submit" class="btn btn-primary" value="Resume all suspended holds" />
197
                            </fieldset>
198
                        </form>
199
                    [% END # IF SuspendHoldsIntranet %]
200
201
                [% ELSE %]
202
                    <p>Patron has nothing on hold.</p>
203
                [% END %]
204
            [% END # /tab_panel#holds %]
205
        [% END %]
206
207
        [% IF Koha.Preference('UseRecalls') %]
208
            [% WRAPPER tab_panel tabname="recalls" %]
209
                [% INCLUDE 'recalls.inc' %]
210
            [% END # /tab_panel# %]
211
        [% END %]
212
213
        [% IF Koha.Preference('ClaimReturnedLostValue') || Koha.Preference('BundleLostValue') %]
214
            [% WRAPPER tab_panel tabname="return-claims" %]
215
                [% INCLUDE 'patron-return-claims.inc' %]
216
            [% END # /tab_panel# %]
217
        [% END %]
218
219
        [% IF Koha.Preference('ArticleRequests') %]
220
            [% WRAPPER tab_panel tabname="article-requests" %]
221
                [% INCLUDE 'patron-article-requests.inc' %]
222
            [% END %]
223
        [% END # /tab_panel# %]
224
225
    [% END # /WRAPPER tab_panels %]
226
[% END # /WRAPPER tabs %]
227
<!-- /patron-detail-tabs.inc -->
(-)a/koha-tmpl/intranet-tmpl/prog/en/includes/patron-restrictions-tab.inc (-72 / +70 lines)
Lines 1-81 Link Here
1
[% USE raw %]
1
[% USE raw %]
2
[% USE Koha %]
2
[% USE Koha %]
3
[% PROCESS 'restriction-types.inc' %]
3
[% PROCESS 'restriction-types.inc' %]
4
<div id="reldebarments" role="tabpanel" class="tab-pane">
4
[% IF ( patron.restrictions.count == 0 ) %]
5
    [% IF ( patron.restrictions.count == 0 ) %]
5
    <p>Patron is currently unrestricted.</p>
6
        <p>Patron is currently unrestricted.</p>
6
[% ELSE %]
7
    [% ELSE %]
7
    <table>
8
        <table>
8
        <thead>
9
            <thead>
9
            <tr>
10
                    <th>Type</th>
11
                    <th>Comment</th>
12
                    <th>Expiration</th>
13
                    <th>Created</th>
14
                    [% IF CAN_user_borrowers_edit_borrowers && CAN_user_circulate_manage_restrictions %]
15
                        <th>&nbsp;</th>
16
                    [% END %]
17
            </tr>
18
        </thead>
19
        <tbody>
20
            [% FOREACH restriction IN patron.restrictions %]
10
                <tr>
21
                <tr>
11
                     <th>Type</th>
22
                    <td>
12
                     <th>Comment</th>
23
                        [% PROCESS restriction_type_description restriction_type=restriction.type %]
13
                     <th>Expiration</th>
24
                    </td>
14
                     <th>Created</th>
25
                    <td>
15
                     [% IF CAN_user_borrowers_edit_borrowers && CAN_user_circulate_manage_restrictions %]
26
                        [% IF restriction.comment.search('OVERDUES_PROCESS') %]
16
                         <th>&nbsp;</th>
27
                            <span>Restriction added by overdues process [% restriction.comment.remove('OVERDUES_PROCESS ') | $raw %]</span>
17
                     [% END %]
28
                        [% ELSE %]
18
                </tr>
29
                            [% restriction.comment | $raw %]
19
            </thead>
30
                        [% END %]
20
            <tbody>
31
                    </td>
21
                [% FOREACH restriction IN patron.restrictions %]
32
                    <td>[% IF restriction.expiration %] [% restriction.expiration | $KohaDates %] [% ELSE %] <em>Indefinite</em> [% END %]</td>
22
                    <tr>
33
                    <td>[% restriction.created | $KohaDates %]</td>
34
                    [% IF CAN_user_borrowers_edit_borrowers && CAN_user_circulate_manage_restrictions %]
23
                        <td>
35
                        <td>
24
                            [% PROCESS restriction_type_description restriction_type=restriction.type %]
36
                            <a class="remove_restriction btn btn-default btn-xs" href="/cgi-bin/koha/members/mod_debarment.pl?borrowernumber=[% patron.borrowernumber | html %]&amp;borrower_debarment_id=[% restriction.borrower_debarment_id | html %]&amp;action=del">
37
                                <i class="fa fa-trash"></i> Remove
38
                            </a>
25
                        </td>
39
                        </td>
26
                        <td>
40
                    [% END %]
27
                            [% IF restriction.comment.search('OVERDUES_PROCESS') %]
41
                </tr>
28
                                <span>Restriction added by overdues process [% restriction.comment.remove('OVERDUES_PROCESS ') | $raw %]</span>
42
            [% END %]
29
                            [% ELSE %]
43
        </tbody>
30
                                [% restriction.comment | $raw %]
44
    </table>
45
[% END %]
46
[% IF CAN_user_borrowers_edit_borrowers && CAN_user_circulate_manage_restrictions %]
47
    <p><a href="#" id="add_manual_restriction"><i class="fa fa-plus"></i> Add manual restriction</a></p>
48
    <form method="post" action="/cgi-bin/koha/members/mod_debarment.pl" class="clearfix">
49
        <input type="hidden" name="borrowernumber" value="[% patron.borrowernumber | html %]" />
50
        <input type="hidden" name="action" value="add" />
51
        <fieldset class="rows" id="manual_restriction_form">
52
            <legend>Add manual restriction</legend>
53
            <ol>
54
                [% IF Koha.Preference('PatronRestrictionTypes') %]
55
                <li>
56
                    <label for="debarred_type">Type:</label>
57
                    <select name="debarred_type">
58
                        [% FOREACH restriction_type IN restriction_types %]
59
                            [% IF !restriction_type.is_system %]
60
                                [% IF restriction_type.is_default %]
61
                                <option value="[% restriction_type.code | html %]" selected>[% PROCESS restriction_type_description %]</option>
62
                                [% ELSE %]
63
                                <option value="[% restriction_type.code | html %]">[% PROCESS restriction_type_description %]</option>
64
                                [% END %]
31
                            [% END %]
65
                            [% END %]
32
                        </td>
33
                        <td>[% IF restriction.expiration %] [% restriction.expiration | $KohaDates %] [% ELSE %] <em>Indefinite</em> [% END %]</td>
34
                        <td>[% restriction.created | $KohaDates %]</td>
35
                        [% IF CAN_user_borrowers_edit_borrowers && CAN_user_circulate_manage_restrictions %]
36
                            <td>
37
                                <a class="remove_restriction btn btn-default btn-xs" href="/cgi-bin/koha/members/mod_debarment.pl?borrowernumber=[% patron.borrowernumber | html %]&amp;borrower_debarment_id=[% restriction.borrower_debarment_id | html %]&amp;action=del">
38
                                    <i class="fa fa-trash"></i> Remove
39
                                </a>
40
                            </td>
41
                        [% END %]
66
                        [% END %]
42
                    </tr>
67
                    </select>
68
                </li>
43
                [% END %]
69
                [% END %]
44
            </tbody>
70
                <li><label for="rcomment">Comment:</label> <input type="text" id="rcomment" name="comment" /></li>
45
        </table>
71
                <li>
46
    [% END %]
72
                    <label for="rexpiration">Expiration:</label>
47
    [% IF CAN_user_borrowers_edit_borrowers && CAN_user_circulate_manage_restrictions %]
73
                    <input name="expiration" id="rexpiration" size="20" value="" class="flatpickr" data-flatpickr-futuredate="true" type="text" />
48
        <p><a href="#" id="add_manual_restriction"><i class="fa fa-plus"></i> Add manual restriction</a></p>
74
                </li>
49
        <form method="post" action="/cgi-bin/koha/members/mod_debarment.pl" class="clearfix">
75
            </ol>
50
            <input type="hidden" name="borrowernumber" value="[% patron.borrowernumber | html %]" />
76
        <fieldset class="action"><input type="submit" value="Add restriction" /> <a href="#" class="cancel" id="cancel_manual_restriction">Cancel</a></fieldset>
51
            <input type="hidden" name="action" value="add" />
77
        </fieldset>
52
            <fieldset class="rows" id="manual_restriction_form">
78
    </form>
53
                <legend>Add manual restriction</legend>
79
[% END %]
54
                <ol>
55
                    [% IF Koha.Preference('PatronRestrictionTypes') %]
56
                    <li>
57
                        <label for="debarred_type">Type:</label>
58
                        <select name="debarred_type">
59
                            [% FOREACH restriction_type IN restriction_types %]
60
                                [% IF !restriction_type.is_system %]
61
                                   [% IF restriction_type.is_default %]
62
                                   <option value="[% restriction_type.code | html %]" selected>[% PROCESS restriction_type_description %]</option>
63
                                   [% ELSE %]
64
                                   <option value="[% restriction_type.code | html %]">[% PROCESS restriction_type_description %]</option>
65
                                   [% END %]
66
                                [% END %]
67
                            [% END %]
68
                        </select>
69
                    </li>
70
                    [% END %]
71
                    <li><label for="rcomment">Comment:</label> <input type="text" id="rcomment" name="comment" /></li>
72
                    <li>
73
                        <label for="rexpiration">Expiration:</label>
74
                        <input name="expiration" id="rexpiration" size="20" value="" class="flatpickr" data-flatpickr-futuredate="true" type="text" />
75
                    </li>
76
                </ol>
77
            <fieldset class="action"><input type="submit" value="Add restriction" /> <a href="#" class="cancel" id="cancel_manual_restriction">Cancel</a></fieldset>
78
            </fieldset>
79
        </form>
80
    [% END %]
81
</div>
(-)a/koha-tmpl/intranet-tmpl/prog/en/includes/patron-return-claims.inc (-25 / +23 lines)
Lines 1-25 Link Here
1
<div id="return-claims" role="tabpanel" class="tab-pane">
1
<p id="return-claims-controls">
2
    <p id="return-claims-controls">
2
    [% IF ( patron.return_claims.resolved.count > 0 || patron.return_claims.unresolved.count > 0 ) %]
3
        [% IF ( patron.return_claims.resolved.count > 0 || patron.return_claims.unresolved.count > 0 ) %]
3
        <a id="show_all_claims" class="ctrl_link" href="#">Show all [% patron.return_claims.count | html %] claim(s)</a>
4
            <a id="show_all_claims" class="ctrl_link" href="#">Show all [% patron.return_claims.count | html %] claim(s)</a>
4
        <a id="show_unresolved_claims" class="ctrl_link disabled" href="#">Show [% patron.return_claims.unresolved.count | html %] unresolved claims</a>
5
            <a id="show_unresolved_claims" class="ctrl_link disabled" href="#">Show [% patron.return_claims.unresolved.count | html %] unresolved claims</a>
5
    [% ELSE %]
6
        [% ELSE %]
6
        <a id="show_all_claims" class="ctrl_link" href="#"></a>
7
            <a id="show_all_claims" class="ctrl_link" href="#"></a>
7
        <a id="show_unresolved_claims" class="ctrl_link disabled" href="#"></a>
8
            <a id="show_unresolved_claims" class="ctrl_link disabled" href="#"></a>
8
    [% END %]
9
        [% END %]
9
</p>
10
    </p>
10
<table id="return-claims-table" class="table table-bordered table-striped">
11
  <table id="return-claims-table" class="table table-bordered table-striped">
11
    <thead>
12
      <thead>
12
        <tr>
13
          <tr>
13
            <th class="return-claim-id">Claim ID</th>
14
              <th class="return-claim-id">Claim ID</th>
14
            <th class="return-claim-id">Resolved?</th>
15
              <th class="return-claim-id">Resolved?</th>
15
            <th class="return-claim-record-title anti-the">Title</th>
16
              <th class="return-claim-record-title anti-the">Title</th>
16
            <th class="return-claim-notes">Notes</th>
17
              <th class="return-claim-notes">Notes</th>
17
            <th class="return-claim-created-on">Created on</th>
18
              <th class="return-claim-created-on">Created on</th>
18
            <th class="return-claim-updated-on">Updated on</th>
19
              <th class="return-claim-updated-on">Updated on</th>
19
            <th class="return-claim-resolution">Resolution</th>
20
              <th class="return-claim-resolution">Resolution</th>
20
            <th class="return-claim-actions NoSort">&nbsp;</th>
21
              <th class="return-claim-actions NoSort">&nbsp;</th>
21
        </tr>
22
          </tr>
22
    </thead>
23
      </thead>
23
</table>
24
  </table>
25
</div>
(-)a/koha-tmpl/intranet-tmpl/prog/en/includes/patron_messages.inc (-3 / +3 lines)
Lines 74-80 Link Here
74
                        [% END %]
74
                        [% END %]
75
                    </em><br/>
75
                    </em><br/>
76
                [% END %]
76
                [% END %]
77
                <a class="btn btn-xs btn-default" href="#reldebarments" onclick="$('#debarments-tab-link').click()"><i class="fa fa-ban"></i> View restrictions</a>
77
                <a class="btn btn-xs btn-default" href="#reldebarments" onclick="$('#reldebarments-tab').click()"><i class="fa fa-ban"></i> View restrictions</a>
78
78
79
                [% IF (noissues && CAN_user_circulate_force_checkout) %]
79
                [% IF (noissues && CAN_user_circulate_force_checkout) %]
80
                    <span class="override_debarment">
80
                    <span class="override_debarment">
Lines 314-323 Link Here
314
                    </span>
314
                    </span>
315
                    [% IF patron_message.branchcode == Branches.GetLoggedInBranchcode OR Koha.Preference('AllowAllMessageDeletion') %]
315
                    [% IF patron_message.branchcode == Branches.GetLoggedInBranchcode OR Koha.Preference('AllowAllMessageDeletion') %]
316
                        [% IF moremember %]
316
                        [% IF moremember %]
317
                            <a id="#edit_message_form_[% patron_message.message_id | html %]" class="btn btn-link edit_message" href="#edit_message_form_[% patron_message.message_id | uri %]" data-target="#edit_message_form_[% patron_message.message_id | html %]" data-toggle="modal" class="btn btn-default"><i class="fa fa-edit"></i> Edit</a>
317
                            <a id="#edit_message_form_[% patron_message.message_id | html %]" class="btn btn-link edit_message" href="#edit_message_form_[% patron_message.message_id | uri %]" data-target="#edit_message_form_[% patron_message.message_id | html %]" data-toggle="modal"><i class="fa fa-edit"></i> Edit</a>
318
                            <a class="btn btn-link delete_message" href="/cgi-bin/koha/circ/del_message.pl?message_id=[% patron_message.message_id | html %]&amp;borrowernumber=[% patron_message.borrowernumber | html %]&amp;from=moremember"><i class="fa fa-trash"></i> Delete</a>
318
                            <a class="btn btn-link delete_message" href="/cgi-bin/koha/circ/del_message.pl?message_id=[% patron_message.message_id | html %]&amp;borrowernumber=[% patron_message.borrowernumber | html %]&amp;from=moremember"><i class="fa fa-trash"></i> Delete</a>
319
                        [% ELSE %]
319
                        [% ELSE %]
320
                            <a id="#edit_message_form_[% patron_message.message_id | html %]" class="btn btn-link edit_message" href="#edit_message_form_[% patron_message.message_id | uri %]" data-target="#edit_message_form_[% patron_message.message_id | html %]" data-toggle="modal" class="btn btn-default"><i class="fa fa-edit"></i> Edit</a>
320
                            <a id="#edit_message_form_[% patron_message.message_id | html %]" class="btn btn-link edit_message" href="#edit_message_form_[% patron_message.message_id | uri %]" data-target="#edit_message_form_[% patron_message.message_id | html %]" data-toggle="modal"><i class="fa fa-edit"></i> Edit</a>
321
                            <a class="btn btn-link delete_message" href="/cgi-bin/koha/circ/del_message.pl?message_id=[% patron_message.message_id | html %]&amp;borrowernumber=[% patron_message.borrowernumber | html %]"><i class="fa fa-trash"></i> Delete</a>
321
                            <a class="btn btn-link delete_message" href="/cgi-bin/koha/circ/del_message.pl?message_id=[% patron_message.message_id | html %]&amp;borrowernumber=[% patron_message.borrowernumber | html %]"><i class="fa fa-trash"></i> Delete</a>
322
                        [% END %]
322
                        [% END %]
323
                    [% END %]
323
                    [% END %]
(-)a/koha-tmpl/intranet-tmpl/prog/en/includes/relatives-issues-table.inc (-24 / +22 lines)
Lines 1-27 Link Here
1
[% USE Koha %]
1
[% USE Koha %]
2
[% IF ( relatives_issues_count ) %]
2
[% IF ( relatives_issues_count ) %]
3
    <div id="relatives-issues" role="tabpanel" class="tab-pane">
3
    <table id="relatives-issues-table" style="width: 100% !Important;">
4
        <table id="relatives-issues-table" style="width: 100% !Important;">
4
        <thead>
5
            <thead>
5
            <tr>
6
                <tr>
6
                <th scope="col">Due date (unformatted, hidden)</th>
7
                    <th scope="col">Due date (unformatted, hidden)</th>
7
                <th scope="col">Due date</th>
8
                    <th scope="col">Due date</th>
8
                <th scope="col">Title</th>
9
                    <th scope="col">Title</th>
9
                <th scope="col">Record-level item type</th>
10
                    <th scope="col">Record-level item type</th>
10
                <th scope="col">Item type</th>
11
                    <th scope="col">Item type</th>
11
                <th scope="col">Collection</th>
12
                    <th scope="col">Collection</th>
12
                <th scope="col">Location</th>
13
                    <th scope="col">Location</th>
13
                <th scope="col">Checked out on (hidden, unformatted)</th>
14
                    <th scope="col">Checked out on (hidden, unformatted)</th>
14
                <th scope="col">Checked out on</th>
15
                    <th scope="col">Checked out on</th>
15
                <th scope="col">Checked out from</th>
16
                    <th scope="col">Checked out from</th>
16
                <th scope="col">Call number</th>
17
                    <th scope="col">Call number</th>
17
                <th scope="col">Copy number</th>
18
                    <th scope="col">Copy number</th>
18
                <th scope="col">Charge</th>
19
                    <th scope="col">Charge</th>
19
                <th scope="col">Fine</th>
20
                    <th scope="col">Fine</th>
20
                <th scope="col">Price</th>
21
                    <th scope="col">Price</th>
21
                <th scope="col">Patron</th>
22
                    <th scope="col">Patron</th>
22
            </tr>
23
                </tr>
23
        </thead>
24
            </thead>
24
    </table>
25
        </table>
26
    </div>
27
[% END %]
25
[% END %]
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/circ/circulation.tt (-174 / +1 lines)
Lines 815-988 Link Here
815
                    </div> <!-- /div or div.col-sm-6 -->
815
                    </div> <!-- /div or div.col-sm-6 -->
816
                </div> <!-- /.row -->
816
                </div> <!-- /.row -->
817
817
818
                <div id="patronlists" class="toptabs">
818
                    [% INCLUDE 'patron-detail-tabs.inc' patronpage = "circ" %]
819
                    <ul class="nav nav-tabs" role="tablist">
820
                        <li role="presentation" class="active">
821
                            <a href="#checkouts" aria-controls="checkouts" role="tab" data-toggle="tab">Checkouts ([% issuecount || 0 | html %])</a>
822
                        </li>
823
824
                        [% IF relatives_issues_count %]
825
                            <li role="presentation">
826
                                <a id="relatives-issues-tab" href="#relatives-issues" aria-controls="relatives-issues" role="tab" data-toggle="tab">Relatives' checkouts ([% relatives_issues_count | html %])</a>
827
                            </li>
828
                        [% END %]
829
830
                        <li role="presentation">
831
                            <a href="#reserves" id="holds-tab" aria-controls="reserves" role="tab" data-toggle="tab">Holds ([% holds_count || 0 | html %])</a>
832
                        </li>
833
834
                        [% IF Koha.Preference('UseRecalls') %]
835
                            <li role="presentation">
836
                                <a href="#recalls" id="recalls-tab" aria-controls="recalls" role="tab" data-toggle="tab">Recalls ([% recalls.count || 0 | html %])</a>
837
                            </li>
838
                        [% END %]
839
840
                        [% IF Koha.Preference('ArticleRequests') %]
841
                            [% SET current_article_requests = Context.Scalar( Context.Scalar( patron, 'article_requests' ), 'filter_by_current' ) %]
842
                            <li role="presentation">
843
                                <a href="#article-requests" id="article-requests-tab" aria-controls="article-requests" role="tab" data-toggle="tab">Article requests ([% current_article_requests.count || 0 | html %])</a>
844
                            </li>
845
                        [% END %]
846
847
                        [% IF Koha.Preference('ClaimReturnedLostValue') || Koha.Preference('BundleLostValue') %]
848
                            <li role="presentation">
849
                                [% IF ( patron.return_claims.count ) %]
850
                                    <a href="#return-claims" id="return-claims-tab" aria-controls="return-claims" role="tab" data-toggle="tab">
851
                                        Claims
852
                                        ([% IF patron.return_claims.resolved.count == 0 %]
853
                                            <span title="Resolved claims" class="label label-default" id="return-claims-count-resolved">[% patron.return_claims.resolved.count | html %]</span>
854
                                        [% ELSE %]
855
                                            <span title="Resolved claims" class="label label-success" id="return-claims-count-resolved">[% patron.return_claims.resolved.count | html %]</span>
856
                                        [% END %]
857
                                        [% IF patron.return_claims.unresolved.count == 0 %]
858
                                            <span title="Unresolved claims" class="label label-default" id="return-claims-count-unresolved">[% patron.return_claims.unresolved.count | html %]</span>
859
                                        [% ELSE %]
860
                                            <span title="Unresolved claims" class="label label-warning" id="return-claims-count-unresolved">[% patron.return_claims.unresolved.count | html %]</span>
861
                                        [% END %])
862
                                    </a>
863
                                [% ELSE %]
864
                                    [% no_claims = 0 %]
865
                                    <a href="#return-claims" id="return-claims-tab" aria-controls="return-claims" role="tab" data-toggle="tab">
866
                                        Claims
867
                                        (<span title="Resolved claims" class="label label-default" id="return-claims-count-resolved">[% no_claims | html %]</span>
868
                                        <span title="Unresolved claims" class="label label-default" id="return-claims-count-unresolved">[% no_claims | html %]</span>)
869
                                    </a>
870
                                [% END %]
871
                            </li>
872
                        [% END %]
873
874
                        <li role="presentation">
875
                            <a id="debarments-tab-link" href="#reldebarments" aria-controls="reldebarments" role="tab" data-toggle="tab">Restrictions ([% patron.restrictions.count || 0 | html %])</a>
876
                        </li>
877
878
                        [% SET enrollments = patron.get_club_enrollments %]
879
                        [% SET enrollable  = patron.get_enrollable_clubs(0) %] <!-- 0 => not OPAC -->
880
                        [% IF CAN_user_clubs && ( enrollable.count || enrollments.count ) %]
881
                            <li role="presentation">
882
                                <a id="clubs-tab-link" href="#clubs-tab" aria-controls="clubs-tab" role="tab" data-toggle="tab">
883
                                    Clubs ([% enrollments.count | html %]/[% enrollable.count | html %])
884
                                </a>
885
                            </li>
886
                        [% END %]
887
                    </ul>
888
889
                    <div class="tab-content">
890
                        <!-- SUMMARY : TODAY & PREVIOUS ISSUES -->
891
892
                        [% INCLUDE "checkouts-table.inc" %]
893
819
894
                        [% INCLUDE "relatives-issues-table.inc" %]
895
896
                        [% IF CAN_user_clubs && ( enrollable.count || enrollments.count ) %]
897
                            <div id="clubs-tab" role="tabpanel" class="tab-pane">
898
                                Loading...
899
                            </div> <!-- /#clubs-tab -->
900
                        [% END %]
901
902
                        [% INCLUDE "patron-restrictions-tab.inc" %]
903
904
                        <div id="reserves" role="tabpanel" class="tab-pane">
905
                            [% IF ( holds_count ) %]
906
                                <form action="/cgi-bin/koha/reserve/modrequest.pl" method="post">
907
                                    <input type="hidden" name="from" value="circ" />
908
                                    <table id="holds-table" style="width: 100% !Important;">
909
                                        <thead>
910
                                            <tr>
911
                                                <th>Hold date</th>
912
                                                <th>Title</th>
913
                                                <th>Call number</th>
914
                                                <th>Item type</th>
915
                                                <th>Barcode</th>
916
                                                <th>Pickup at</th>
917
                                                <th>Expiration</th>
918
                                                <th>Priority</th>
919
                                                <th>Cancel?</th>
920
                                                <th>Suspend?</th>
921
                                                <th>Status</th>
922
                                            </tr>
923
                                        </thead>
924
                                    </table>
925
926
                                    <fieldset class="action">
927
                                        <input type="submit" class="cancel" name="submit" value="Cancel marked holds" />
928
929
                                        [% SET hold_cancellation = AuthorisedValues.GetAuthValueDropbox('HOLD_CANCELLATION') %]
930
                                        [% IF hold_cancellation.count %]
931
                                            <select name="cancellation-reason">
932
                                                <option value="">No reason given</option>
933
                                                [% FOREACH reason IN hold_cancellation %]
934
                                                    <option value="[% reason.authorised_value | html %]">[% reason.lib | html %]</option>
935
                                                [% END %]
936
                                            </select>
937
                                        [% END %]
938
                                    </fieldset>
939
                                </form>
940
941
                                [% IF Koha.Preference('SuspendHoldsIntranet') %]
942
                                    <fieldset class="action">
943
                                        <form action="/cgi-bin/koha/reserve/modrequest_suspendall.pl" method="post">
944
                                            <input type="hidden" name="from" value="circ" />
945
                                            <input type="hidden" name="borrowernumber" value="[% patron.borrowernumber | html %]" />
946
                                            <input type="submit" class="btn btn-primary" value="Suspend all holds" />
947
948
                                            [% IF Koha.Preference('AutoResumeSuspendedHolds') %]
949
                                            <label for="suspend_until">until</label>
950
                                            <input type="text" size="10" id="suspend_until" name="suspend_until" class="flatpickr" data-flatpickr-futuredate="true" />
951
                                            <span class="hint">Specify date on which to resume [% INCLUDE 'date-format.inc' %]: </span>
952
                                            [% END %]
953
                                        </form>
954
                                    </fieldset>
955
956
                                    <fieldset class="action">
957
                                        <form action="/cgi-bin/koha/reserve/modrequest_suspendall.pl" method="post">
958
                                            <input type="hidden" name="from" value="circ" />
959
                                            <input type="hidden" name="borrowernumber" value="[% patron.borrowernumber | html %]" />
960
                                            <input type="hidden" name="suspend" value="0" />
961
                                            <input type="submit" class="btn btn-primary" value="Resume all suspended holds" />
962
                                        </form>
963
                                    </fieldset>
964
                                [% END # /IF SuspendHoldsIntranet %]
965
966
                            [% ELSE # IF holds_count %]
967
                                <p>Patron has nothing on hold.</p>
968
                            [% END # /IF holds_count %]
969
                        </div> <!-- /#reserves -->
970
971
                        [% IF Koha.Preference('UseRecalls') %]
972
                            <div id="recalls" role="tabpanel" class="tab-pane">
973
                                [% INCLUDE 'recalls.inc' %]
974
                            </div>
975
                        [% END %]
976
977
                        [% IF Koha.Preference('ClaimReturnedLostValue') || Koha.Preference('BundleLostValue') %]
978
                            [% INCLUDE 'patron-return-claims.inc' %]
979
                        [% END %]
980
981
                        [% IF Koha.Preference('ArticleRequests') %]
982
                            [% INCLUDE 'patron-article-requests.inc' %]
983
                        [% END %]
984
                    </div> <!-- /.tab-content -->
985
                </div> <!-- /#patronlists -->
986
                [% ELSIF borrowernumber # IF patron %]
820
                [% ELSIF borrowernumber # IF patron %]
987
                    <div class="dialog message">Patron not found. <a href="/cgi-bin/koha/members/members-home.pl">Return to search</a></div>
821
                    <div class="dialog message">Patron not found. <a href="/cgi-bin/koha/members/members-home.pl">Return to search</a></div>
988
                [% END # /IF patron %]
822
                [% END # /IF patron %]
Lines 1101-1113 Link Here
1101
                }
935
                }
1102
            });
936
            });
1103
937
1104
            if ( $('#clubs-tab').length ) {
1105
                $('#clubs-tab-link').on('click', function() {
1106
                    $('#clubs-tab').text(_("Loading..."));
1107
                    $('#clubs-tab').load('/cgi-bin/koha/clubs/patron-clubs-tab.pl?borrowernumber=[% patron.borrowernumber | html %]');
1108
                });
1109
            }
1110
1111
            // listen submit to trigger qslip on empty checkout
938
            // listen submit to trigger qslip on empty checkout
1112
            $('#mainform').bind('submit',function() {
939
            $('#mainform').bind('submit',function() {
1113
                if ($('#barcode').val() == '') {
940
                if ($('#barcode').val() == '') {
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/members/moremember.tt (-224 / +3 lines)
Lines 650-871 Link Here
650
                        </div> <!-- /div.col-sm-6 -->
650
                        </div> <!-- /div.col-sm-6 -->
651
                    </div> <!-- /div.row -->
651
                    </div> <!-- /div.row -->
652
652
653
                    <div id="finesholdsissues" class="toptabs">
653
                    [% INCLUDE 'patron-detail-tabs.inc' patronpage = "borrower" %]
654
                        <ul class="nav nav-tabs" role="tablist">
655
                            <li role="presentation" class="active">
656
                                <a href="#checkouts" aria-controls="checkouts" role="tab" data-toggle="tab">Checkouts ([% issuecount || 0 | html %])</a>
657
                            </li>
658
                            [% IF relatives_issues_count %]
659
                                <li role="presentation">
660
                                    <a href="#relatives-issues" id="relatives-issues-tab" aria-controls="relatives-issues" role="tab" data-toggle="tab">Relatives' checkouts ([% relatives_issues_count | html %])</a>
661
                                </li>
662
                            [% END %]
663
                            [% IF ( fines ) %]
664
                                <li role="presentation" id="finestab">
665
                                    <a href="#finesandcharges" aria-controls="finesandcharges" role="tab" data-toggle="tab">Charges ([% fines | $Price %])</a>
666
                                </li>
667
                            [% END %]
668
                            [% IF ( guarantees_fines ) %]
669
                                <li role="presentation" id="guarantees_finestab">
670
                                    <a href="#guarantees_finesandcharges" aria-controls="guarantees_finesandcharges" role="tab" data-toggle="tab">Guarantees' charges ([% guarantees_fines | $Price %])</a>
671
                                </li>
672
                            [% END %]
673
                            [% IF ( CAN_user_circulate_circulate_remaining_permissions ) %]
674
                                <li role="presentation">
675
                                        <a href="#reserves" id="holds-tab" aria-controls="reserves" role="tab" data-toggle="tab">Holds ([% holds_count || 0 | html %])</a>
676
                                </li>
677
                            [% END %]
678
654
679
                            [% IF Koha.Preference('UseRecalls') %]
680
                                <li role="presentation">
681
                                    <a href="#recalls" id="recalls-tab" aria-controls="recalls" role="tab" data-toggle="tab">Recalls ([% recalls.count || 0 | html %])</a>
682
                                </li>
683
                            [% END %]
684
685
                            [% IF Koha.Preference('ArticleRequests') %]
686
                                [% SET article_requests = Context.Scalar( Context.Scalar( patron, 'article_requests' ), 'filter_by_current') %]
687
                                <li role="presentation">
688
                                    <a href="#article-requests" id="article-requests-tab" aria-controls="article-requests" role="tab" data-toggle="tab">Article requests ([% article_requests.count || 0 | html %])</a>
689
                                </li>
690
                            [% END %]
691
692
                            [% IF Koha.Preference('ClaimReturnedLostValue') || Koha.Preference('BundleLostValue') %]
693
                                <li role="presentation">
694
                                    [% IF ( patron.return_claims.count ) %]
695
                                        <a href="#return-claims" id="return-claims-tab" aria-controls="return-claims" role="tab" data-toggle="tab">
696
                                            Claims
697
                                            ([% IF patron.return_claims.resolved.count == 0 %]
698
                                                <span title="Resolved claims" class="label label-default" id="return-claims-count-resolved">[% patron.return_claims.resolved.count | html %]</span>
699
                                            [% ELSE %]
700
                                                <span title="Resolved claims" class="label label-success" id="return-claims-count-resolved">[% patron.return_claims.resolved.count | html %]</span>
701
                                            [% END %]
702
                                            [% IF patron.return_claims.unresolved.count == 0 %]
703
                                                <span title="Unresolved claims" class="label label-default" id="return-claims-count-unresolved">[% patron.return_claims.unresolved.count | html %]</span>
704
                                            [% ELSE %]
705
                                                <span title="Unresolved claims" class="label label-warning" id="return-claims-count-unresolved">[% patron.return_claims.unresolved.count | html %]</span>
706
                                            [% END %])
707
                                        </a>
708
                                    [% ELSE %]
709
                                        [% no_claims = 0 %]
710
                                        <a href="#return-claims" id="return-claims-tab" aria-controls="return-claims" role="tab" data-toggle="tab">
711
                                            Claims
712
                                            (<span title="Resolved claims" class="label label-default" id="return-claims-count-resolved">[% no_claims | html %]</span>
713
                                            <span title="Unresolved claims" class="label label-default" id="return-claims-count-unresolved">[% no_claims | html %]</span>)
714
                                        </a>
715
                                    [% END %]
716
                                </li>
717
                            [% END %]
718
719
                            <li role="presentation">
720
                                <a id="debarments-tab-link" href="#reldebarments" aria-controls="reldebarments" role="tab" data-toggle="tab">Restrictions ([% patron.restrictions.count | html %])</a>
721
                            </li>
722
723
                            [% SET enrollments = patron.get_club_enrollments %]
724
                            [% SET enrollable  = patron.get_enrollable_clubs(0) %] <!-- 0 => not OPAC -->
725
                            [% IF CAN_user_clubs && ( enrollable.count || enrollments.count ) %]
726
                                <li role="presentation">
727
                                    <a id="clubs-tab-link" href="#clubs-tab" aria-controls="checkouts" role="tab" data-toggle="tab">
728
                                        Clubs ([% enrollments.count | html %]/[% enrollable.count | html %])
729
                                    </a>
730
                                </li>
731
                            [% END %]
732
                        </ul>
733
734
                        <div class="tab-content">
735
                            [% INCLUDE "checkouts-table.inc" %]
736
737
                            [% INCLUDE "relatives-issues-table.inc" %]
738
739
                            [% IF ( fines ) %]
740
                                <div id="finesandcharges" role="tabpanel" class="tab-pane">
741
                                    [% IF ( fines ) %]
742
                                        <p>Total due: [% fines | $Price %]</p>
743
                                    [% ELSE %]
744
                                        <p>No outstanding charges</p>
745
                                    [% END %]
746
                                </div>
747
                            [% END %]
748
749
                        [% IF ( guarantees_fines ) %]
750
                            <div id="guarantees_finesandcharges" role="tabpanel" class="tab-pane">
751
                                <table id="tguaranteesfines">
752
                                    <thead>
753
                                        <tr>
754
                                            <th>Guarantee</th>
755
                                            <th>Amount outstanding</th>
756
                                        </tr>
757
                                    </thead>
758
                                    [% FOREACH guarantee IN guarantees %]
759
                                        <tr>
760
                                            <td>[% INCLUDE 'patron-title.inc' patron=guarantee hide_patron_infos_if_needed=1 %]</td>
761
                                            [% IF logged_in_user.can_see_patron_infos( guarantee ) %]
762
                                                <td>[% guarantee.account.balance | $Price %]</td>
763
                                            [% ELSE %]
764
                                                <td>-</td>
765
                                            [% END %]
766
                                        </tr>
767
                                    [% END %]
768
                                    <tfoot>
769
                                        <td>Total due</td>
770
                                        <td>[% guarantees_fines | $Price %]</td>
771
                                    </tfoot>
772
                                </table>
773
                            </div>
774
                        [% END %]
775
776
                        [% IF CAN_user_clubs && ( enrollments.count || enrollable.count ) %]
777
                            <div id="clubs-tab">
778
                                Loading...
779
                            </div>
780
                        [% END %]
781
782
                            [% INCLUDE 'patron-restrictions-tab.inc' %]
783
784
                            [% IF ( CAN_user_circulate_circulate_remaining_permissions ) %]
785
                                <div id="reserves" role="tabpanel" class="tab-pane">
786
                                    [% IF ( holds_count ) %]
787
                                        <form action="/cgi-bin/koha/reserve/modrequest.pl" method="post">
788
                                            <input type="hidden" name="from" value="circ" />
789
                                            <table id="holds-table" style="width: 100% !Important;">
790
                                                <thead>
791
                                                    <tr>
792
                                                        <th>Hold date</th>
793
                                                        <th>Title</th>
794
                                                        <th>Call number</th>
795
                                                        <th>Item type</th>
796
                                                        <th>Barcode</th>
797
                                                        <th>Pickup at</th>
798
                                                        <th>Expiration</th>
799
                                                        <th>Priority</th>
800
                                                        <th>Delete?</th>
801
                                                        <th>Suspend?</th>
802
                                                        <th>Status</th>
803
                                                    </tr>
804
                                                </thead>
805
                                            </table>
806
807
                                            <fieldset class="action">
808
                                                <input type="submit" class="cancel" name="submit" value="Cancel marked holds" />
809
810
                                                [% SET hold_cancellation = AuthorisedValues.GetAuthValueDropbox('HOLD_CANCELLATION') %]
811
                                                [% IF hold_cancellation.count %]
812
                                                    <label for="cancellation-reason">Cancellation reason:</label>
813
                                                    <select name="cancellation-reason">
814
                                                        <option value="">No reason given</option>
815
                                                        [% FOREACH reason IN hold_cancellation %]
816
                                                            <option value="[% reason.authorised_value | html %]">[% reason.lib | html %]</option>
817
                                                        [% END %]
818
                                                    </select>
819
                                                [% END %]
820
                                            </fieldset>
821
                                        </form>
822
823
                                        [% IF Koha.Preference('SuspendHoldsIntranet') %]
824
                                            <form action="/cgi-bin/koha/reserve/modrequest_suspendall.pl" method="post">
825
                                                <fieldset class="action">
826
                                                    <input type="hidden" name="from" value="borrower" />
827
                                                    <input type="hidden" name="borrowernumber" value="[% patron.borrowernumber | html %]" />
828
                                                    <input type="submit" class="btn btn-primary" value="Suspend all holds" />
829
830
                                                    [% IF Koha.Preference('AutoResumeSuspendedHolds') %]
831
                                                        <label for="suspend_until">until</label>
832
                                                        <input type="text" size="10" id="suspend_until" name="suspend_until" class="flatpickr" data-flatpickr-futuredate="true"/>
833
                                                        <span class="hint">Specify date on which to resume [% INCLUDE 'date-format.inc' %]: </span>
834
                                                    [% END %]
835
                                                </fieldset>
836
                                            </form>
837
838
                                            <form action="/cgi-bin/koha/reserve/modrequest_suspendall.pl" method="post">
839
                                                <fieldset class="action">
840
                                                    <input type="hidden" name="from" value="borrower" />
841
                                                    <input type="hidden" name="borrowernumber" value="[% patron.borrowernumber | html %]" />
842
                                                    <input type="hidden" name="suspend" value="0" />
843
                                                    <input type="submit" class="btn btn-primary" value="Resume all suspended holds" />
844
                                                </fieldset>
845
                                            </form>
846
                                        [% END # IF SuspendHoldsIntranet %]
847
848
                                    [% ELSE %]
849
                                        <p>Patron has nothing on hold.</p>
850
                                    [% END %]
851
                                </div> [% # /div#reserves %]
852
                            [% END %]
853
854
                            [% IF Koha.Preference('UseRecalls') %]
855
                                <div id="recalls" role="tabpanel" class="tab-pane">
856
                                    [% INCLUDE 'recalls.inc' %]
857
                                </div>
858
                            [% END %]
859
860
                            [% IF Koha.Preference('ClaimReturnedLostValue') %]
861
                                [% INCLUDE 'patron-return-claims.inc' %]
862
                            [% END %]
863
864
                            [% IF Koha.Preference('ArticleRequests') %]
865
                                [% INCLUDE 'patron-article-requests.inc' %]
866
                            [% END %]
867
                        </div> <!-- /.tab-content -->
868
                    </div> <!-- /div#finesholdsissues -->
869
                </main>
655
                </main>
870
            </div> <!-- /.col-sm-10.col-sm-push-2 -->
656
            </div> <!-- /.col-sm-10.col-sm-push-2 -->
871
657
Lines 926-938 Link Here
926
        $(document).ready(function() {
712
        $(document).ready(function() {
927
            $("#info_digests").tooltip();
713
            $("#info_digests").tooltip();
928
714
929
            if ( $('#clubs-tab').length ) {
930
                $('#clubs-tab-link').on('click', function() {
931
                    $('#clubs-tab').text(_("Loading..."));
932
                    $('#clubs-tab').load('/cgi-bin/koha/clubs/patron-clubs-tab.pl?borrowernumber=[% patron.borrowernumber | html %]');
933
                });
934
            }
935
936
            $("#finesholdsissues a[data-toggle='tab']").on("shown.bs.tab", function(e){
715
            $("#finesholdsissues a[data-toggle='tab']").on("shown.bs.tab", function(e){
937
                var oTable = $('div.dataTables_wrapper > table', $(e.target.hash) ).dataTable();
716
                var oTable = $('div.dataTables_wrapper > table', $(e.target.hash) ).dataTable();
938
                if ( oTable.length > 0 ) {
717
                if ( oTable.length > 0 ) {
Lines 941-951 Link Here
941
            });
720
            });
942
721
943
            $("#view_restrictions").on("click",function(){
722
            $("#view_restrictions").on("click",function(){
944
                $('#debarments-tab-link').click();
723
                $('#reldebarments-tab').click();
945
            });
724
            });
946
725
947
            $("#view_guarantees_finesandcharges").on("click",function(){
726
            $("#view_guarantees_finesandcharges").on("click",function(){
948
                $('#guarantees_finestab a').click();
727
                $('#guarantees_finesandcharges-tab').click();
949
            });
728
            });
950
729
951
         });
730
         });
(-)a/koha-tmpl/intranet-tmpl/prog/js/pages/circulation.js (-2 / +8 lines)
Lines 1-3 Link Here
1
/* global borrowernumber */
1
$(document).ready(function() {
2
$(document).ready(function() {
2
    $("#CheckAllExports").on("click",function(){
3
    $("#CheckAllExports").on("click",function(){
3
        $(".export:visible").prop("checked", true);
4
        $(".export:visible").prop("checked", true);
Lines 8-14 $(document).ready(function() { Link Here
8
        return false;
9
        return false;
9
    });
10
    });
10
11
11
    $("#patronlists a[data-toggle='tab']").on("shown.bs.tab", function(e){
12
    $("#finesholdsissues a[data-toggle='tab']").on("shown.bs.tab", function(e){
12
        $(this).click();
13
        $(this).click();
13
    });
14
    });
14
15
Lines 96-101 $(document).ready(function() { Link Here
96
        activeTab && activeTab.tab('show');
97
        activeTab && activeTab.tab('show');
97
    }
98
    }
98
99
100
    if ( $('#clubs_panel').length ) {
101
        $('#clubs-tab').on('click', function() {
102
            $('#clubs_panel').text(_("Loading..."));
103
            $('#clubs_panel').load('/cgi-bin/koha/clubs/patron-clubs-tab.pl?borrowernumber=' + borrowernumber );
104
        });
105
    }
99
});
106
});
100
107
101
function export_checkouts(format) {
108
function export_checkouts(format) {
102
- 

Return to bug 33528