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

(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/circ/circulation_batch_checkouts.tt (+13 lines)
Lines 292-298 Link Here
292
[% MACRO jsinclude BLOCK %]
292
[% MACRO jsinclude BLOCK %]
293
    [% INCLUDE 'calendar.inc' %]
293
    [% INCLUDE 'calendar.inc' %]
294
    [% INCLUDE 'datatables.inc' %]
294
    [% INCLUDE 'datatables.inc' %]
295
    [% Asset.js("lib/jquery/plugins/jquery-ui-timepicker-addon.min.js") %]
295
    <script type="text/javascript">
296
    <script type="text/javascript">
297
298
        /* Set some variables needed in members-menu.js */
299
        var borrowernumber = "[% patron.borrowernumber %]";
300
        var advsearch = "[% advsearch %]";
301
        var dateformat = "[% dateformat %]";
302
        var NorwegianPatronDBEnable = "[% NorwegianPatronDBEnable %]";
303
        var CATCODE_MULTI = "[% CATCODE_MULTI %]";
304
        var catcode = "[% catcode %]";
305
        var destination = "[% destination %]";
306
        var CAN_user_borrowers_edit_borrowers = "[% CAN_user_borrowers_edit_borrowers %]";
307
296
        $(document).ready(function() {
308
        $(document).ready(function() {
297
            if($('#barcodelist').length) {
309
            if($('#barcodelist').length) {
298
                $('#barcodelist').focus();
310
                $('#barcodelist').focus();
Lines 310-315 Link Here
310
            }));
322
            }));
311
        });
323
        });
312
    </script>
324
    </script>
325
    [% Asset.js("js/members-menu.js") %]
313
[% END %]
326
[% END %]
314
327
315
[% INCLUDE 'intranet-bottom.inc' %]
328
[% INCLUDE 'intranet-bottom.inc' %]
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/members/deletemem.tt (+11 lines)
Lines 64-69 Link Here
64
64
65
[% MACRO jsinclude BLOCK %]
65
[% MACRO jsinclude BLOCK %]
66
    [% Asset.js("js/members-menu.js") %]
66
    [% Asset.js("js/members-menu.js") %]
67
    <script>
68
        /* Set some variables needed in members-menu.js */
69
        var borrowernumber = "[% patron.borrowernumber %]";
70
        var advsearch = "[% advsearch %]";
71
        var dateformat = "[% dateformat %]";
72
        var NorwegianPatronDBEnable = "[% NorwegianPatronDBEnable %]";
73
        var CATCODE_MULTI = "[% CATCODE_MULTI %]";
74
        var catcode = "[% catcode %]";
75
        var destination = "[% destination %]";
76
        var CAN_user_borrowers_edit_borrowers = "[% CAN_user_borrowers_edit_borrowers %]";
77
    </script>
67
[% END %]
78
[% END %]
68
79
69
[% INCLUDE 'intranet-bottom.inc' %]
80
[% INCLUDE 'intranet-bottom.inc' %]
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/members/housebound.tt (-1 / +12 lines)
Lines 427-440 Link Here
427
427
428
[% MACRO jsinclude BLOCK %]
428
[% MACRO jsinclude BLOCK %]
429
    [% INCLUDE 'calendar.inc' %]
429
    [% INCLUDE 'calendar.inc' %]
430
    [% Asset.js("js/members-menu.js") %]
431
    <script type="text/javascript">
430
    <script type="text/javascript">
431
432
        /* Set some variables needed in members-menu.js */
433
        var borrowernumber = "[% patron.borrowernumber %]";
434
        var advsearch = "[% advsearch %]";
435
        var dateformat = "[% dateformat %]";
436
        var NorwegianPatronDBEnable = "[% NorwegianPatronDBEnable %]";
437
        var CATCODE_MULTI = "[% CATCODE_MULTI %]";
438
        var catcode = "[% catcode %]";
439
        var destination = "[% destination %]";
440
        var CAN_user_borrowers_edit_borrowers = "[% CAN_user_borrowers_edit_borrowers %]";
441
432
        $(document).ready(function() {
442
        $(document).ready(function() {
433
            $("a.delete").click(function(){
443
            $("a.delete").click(function(){
434
                return confirm(_("Are you sure you want to delete this delivery?"));
444
                return confirm(_("Are you sure you want to delete this delivery?"));
435
            });
445
            });
436
        });
446
        });
437
    </script>
447
    </script>
448
    [% Asset.js("js/members-menu.js") %]
438
[% END %]
449
[% END %]
439
450
440
[% INCLUDE 'intranet-bottom.inc' %]
451
[% INCLUDE 'intranet-bottom.inc' %]
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/members/notices.tt (-1 / +12 lines)
Lines 90-98 Link Here
90
</div>
90
</div>
91
91
92
[% MACRO jsinclude BLOCK %]
92
[% MACRO jsinclude BLOCK %]
93
    [% Asset.js("js/members-menu.js") %]
94
    [% INCLUDE 'datatables.inc' %]
93
    [% INCLUDE 'datatables.inc' %]
95
    <script type="text/javascript">
94
    <script type="text/javascript">
95
96
        /* Set some variables needed in members-menu.js */
97
        var borrowernumber = "[% patron.borrowernumber %]";
98
        var advsearch = "[% advsearch %]";
99
        var dateformat = "[% dateformat %]";
100
        var NorwegianPatronDBEnable = "[% NorwegianPatronDBEnable %]";
101
        var CATCODE_MULTI = "[% CATCODE_MULTI %]";
102
        var catcode = "[% catcode %]";
103
        var destination = "[% destination %]";
104
        var CAN_user_borrowers_edit_borrowers = "[% CAN_user_borrowers_edit_borrowers %]";
105
96
        $(document).ready(function() {
106
        $(document).ready(function() {
97
            $("#noticestable").dataTable($.extend(true, {}, dataTablesDefaults, {
107
            $("#noticestable").dataTable($.extend(true, {}, dataTablesDefaults, {
98
                "aaSorting": [[ 3, "desc" ]],
108
                "aaSorting": [[ 3, "desc" ]],
Lines 116-121 Link Here
116
            });
126
            });
117
        });
127
        });
118
    </script>
128
    </script>
129
    [% Asset.js("js/members-menu.js") %]
119
[% END %]
130
[% END %]
120
131
121
[% INCLUDE 'intranet-bottom.inc' %]
132
[% INCLUDE 'intranet-bottom.inc' %]
(-)a/members/deletemem.pl (+7 lines)
Lines 31-36 use C4::Members; Link Here
31
use Module::Load;
31
use Module::Load;
32
use Koha::Patrons;
32
use Koha::Patrons;
33
use Koha::Token;
33
use Koha::Token;
34
use Koha::Patron::Categories;
34
35
35
if ( C4::Context->preference('NorwegianPatronDBEnable') && C4::Context->preference('NorwegianPatronDBEnable') == 1 ) {
36
if ( C4::Context->preference('NorwegianPatronDBEnable') && C4::Context->preference('NorwegianPatronDBEnable') == 1 ) {
36
    load Koha::NorwegianPatronDB, qw( NLMarkForDeletion NLSync );
37
    load Koha::NorwegianPatronDB, qw( NLMarkForDeletion NLSync );
Lines 100-105 if (C4::Context->preference("IndependentBranches")) { Link Here
100
    }
101
    }
101
}
102
}
102
103
104
if ( $patron->is_child ) {
105
    my $patron_categories = Koha::Patron::Categories->search_limited({ category_type => 'A' }, {order_by => ['categorycode']});
106
    $template->param( 'CATCODE_MULTI' => 1) if $patron_categories->count > 1;
107
    $template->param( 'catcode' => $patron_categories->next->categorycode )  if $patron_categories->count == 1;
108
}
109
103
my $op = $input->param('op') || 'delete_confirm';
110
my $op = $input->param('op') || 'delete_confirm';
104
my $dbh = C4::Context->dbh;
111
my $dbh = C4::Context->dbh;
105
my $is_guarantor = $dbh->selectrow_array("SELECT COUNT(*) FROM borrowers WHERE guarantorid=?", undef, $member);
112
my $is_guarantor = $dbh->selectrow_array("SELECT COUNT(*) FROM borrowers WHERE guarantorid=?", undef, $member);
(-)a/members/files.pl (+7 lines)
Lines 30-35 use C4::Debug; Link Here
30
use Koha::DateUtils;
30
use Koha::DateUtils;
31
use Koha::Patrons;
31
use Koha::Patrons;
32
use Koha::Patron::Files;
32
use Koha::Patron::Files;
33
use Koha::Patron::Categories;
33
34
34
my $cgi = CGI->new;
35
my $cgi = CGI->new;
35
36
Lines 114-119 else { Link Here
114
        );
115
        );
115
    }
116
    }
116
117
118
    if ( $patron->is_child ) {
119
        my $patron_categories = Koha::Patron::Categories->search_limited({ category_type => 'A' }, {order_by => ['categorycode']});
120
        $template->param( 'CATCODE_MULTI' => 1) if $patron_categories->count > 1;
121
        $template->param( 'catcode' => $patron_categories->next->categorycode )  if $patron_categories->count == 1;
122
    }
123
117
    $template->param(
124
    $template->param(
118
        files => Koha::Patron::Files->new( borrowernumber => $borrowernumber )
125
        files => Koha::Patron::Files->new( borrowernumber => $borrowernumber )
119
          ->GetFilesInfo(),
126
          ->GetFilesInfo(),
(-)a/members/housebound.pl (+6 lines)
Lines 166-171 if ( C4::Context->preference('ExtendedPatronAttributes') and $patron ) { Link Here
166
    );
166
    );
167
}
167
}
168
168
169
if ( $patron->is_child ) {
170
    my $patron_categories = Koha::Patron::Categories->search_limited({ category_type => 'A' }, {order_by => ['categorycode']});
171
    $template->param( 'CATCODE_MULTI' => 1) if $patron_categories->count > 1;
172
    $template->param( 'catcode' => $patron_categories->next->categorycode )  if $patron_categories->count == 1;
173
}
174
169
$template->param(
175
$template->param(
170
    housebound_profile => $houseboundprofile,
176
    housebound_profile => $houseboundprofile,
171
    visit              => $houseboundvisit,
177
    visit              => $houseboundvisit,
(-)a/members/notices.pl (-2 / +8 lines)
Lines 27-32 use C4::Members; Link Here
27
use C4::Letters;
27
use C4::Letters;
28
use C4::Members::Attributes qw(GetBorrowerAttributes);
28
use C4::Members::Attributes qw(GetBorrowerAttributes);
29
use Koha::Patrons;
29
use Koha::Patrons;
30
use Koha::Patron::Categories;
30
31
31
my $input=new CGI;
32
my $input=new CGI;
32
33
Lines 39-46 unless ( $patron ) { Link Here
39
}
40
}
40
my $borrower = $patron->unblessed;
41
my $borrower = $patron->unblessed;
41
42
42
my ($template, $loggedinuser, $cookie)
43
my ($template, $loggedinuser, $cookie)= get_template_and_user({template_name => "members/notices.tt",
43
= get_template_and_user({template_name => "members/notices.tt",
44
				query => $input,
44
				query => $input,
45
				type => "intranet",
45
				type => "intranet",
46
				authnotrequired => 0,
46
				authnotrequired => 0,
Lines 51-56 my ($template, $loggedinuser, $cookie) Link Here
51
my $logged_in_user = Koha::Patrons->find( $loggedinuser ) or die "Not logged in";
51
my $logged_in_user = Koha::Patrons->find( $loggedinuser ) or die "Not logged in";
52
output_and_exit_if_error( $input, $cookie, $template, { module => 'members', logged_in_user => $logged_in_user, current_patron => $patron } );
52
output_and_exit_if_error( $input, $cookie, $template, { module => 'members', logged_in_user => $logged_in_user, current_patron => $patron } );
53
53
54
if ( $patron->is_child ) {
55
    my $patron_categories = Koha::Patron::Categories->search_limited({ category_type => 'A' }, {order_by => ['categorycode']});
56
    $template->param( 'CATCODE_MULTI' => 1) if $patron_categories->count > 1;
57
    $template->param( 'catcode' => $patron_categories->next->categorycode )  if $patron_categories->count == 1;
58
}
59
54
# Allow resending of messages in Notices tab
60
# Allow resending of messages in Notices tab
55
my $op = $input->param('op') || q{};
61
my $op = $input->param('op') || q{};
56
if ( $op eq 'resend_notice' ) {
62
if ( $op eq 'resend_notice' ) {
(-)a/members/statistics.pl (-1 / +7 lines)
Lines 32-37 use C4::Members::Statistics; Link Here
32
use C4::Members::Attributes qw(GetBorrowerAttributes);
32
use C4::Members::Attributes qw(GetBorrowerAttributes);
33
use C4::Output;
33
use C4::Output;
34
use Koha::Patrons;
34
use Koha::Patrons;
35
use Koha::Patron::Categories;
35
36
36
my $input = new CGI;
37
my $input = new CGI;
37
38
Lines 84-89 if (C4::Context->preference('ExtendedPatronAttributes')) { Link Here
84
    );
85
    );
85
}
86
}
86
87
88
if ( $patron->is_child ) {
89
    my $patron_categories = Koha::Patron::Categories->search_limited({ category_type => 'A' }, {order_by => ['categorycode']});
90
    $template->param( 'CATCODE_MULTI' => 1) if $patron_categories->count > 1;
91
    $template->param( 'catcode' => $patron_categories->next->categorycode )  if $patron_categories->count == 1;
92
}
93
87
$template->param(
94
$template->param(
88
    patron             => $patron,
95
    patron             => $patron,
89
    statisticsview     => 1,
96
    statisticsview     => 1,
90
- 

Return to bug 20805