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

(-)a/admin/branch_transfer_limits.pl (+4 lines)
Lines 28-33 use C4::Koha; Link Here
28
use C4::Circulation qw{ IsBranchTransferAllowed DeleteBranchTransferLimits CreateBranchTransferLimit };
28
use C4::Circulation qw{ IsBranchTransferAllowed DeleteBranchTransferLimits CreateBranchTransferLimit };
29
29
30
my $input = new CGI;
30
my $input = new CGI;
31
my %errors; # Collect possible errors here.
31
32
32
my ($template, $loggedinuser, $cookie)
33
my ($template, $loggedinuser, $cookie)
33
    = get_template_and_user({template_name => "admin/branch_transfer_limits.tt",
34
    = get_template_and_user({template_name => "admin/branch_transfer_limits.tt",
Lines 47-52 else Link Here
47
    $fromBranch = Koha::Libraries->find($input->param('fromBranch'));
48
    $fromBranch = Koha::Libraries->find($input->param('fromBranch'));
48
}
49
}
49
50
51
$errors{syspref_UseBranchTransferLimits_isMissing} = 1 if not(C4::Context->preference('UseBranchTransferLimits'));
52
50
# Set the template language for the correct limit type using $limitType
53
# Set the template language for the correct limit type using $limitType
51
my $limitType = C4::Context->preference("BranchTransferLimitsType") || "ccode";
54
my $limitType = C4::Context->preference("BranchTransferLimitsType") || "ccode";
52
55
Lines 101-106 foreach my $code ( @codes ) { Link Here
101
104
102
105
103
$template->param(
106
$template->param(
107
		errors => \%errors,
104
		branchcount => $branchcount,
108
		branchcount => $branchcount,
105
		codes_loop => \@codes_loop,
109
		codes_loop => \@codes_loop,
106
		branches => \@branches,
110
		branches => \@branches,
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/branch_transfer_limits.tt (-1 / +4 lines)
Lines 19-24 Link Here
19
        <div class="col-sm-10 col-sm-push-2">
19
        <div class="col-sm-10 col-sm-push-2">
20
            <main>
20
            <main>
21
21
22
[% IF errors.syspref_UseBranchTransferLimits_isMissing %]
23
    <div class="dialog alert"><strong>Warning:</strong> This feature is disabled while system preference 'UseBranchTransferLimits' is not set. This feature is enabled and configured from the system preferences.</div>
24
[% END %]
25
22
<h1>Library [% fromBranch.branchcode | html %] - [% fromBranch.branchname | html %] Checkin and transfer policy</h1>
26
<h1>Library [% fromBranch.branchcode | html %] - [% fromBranch.branchname | html %] Checkin and transfer policy</h1>
23
    <form method="get" action="/cgi-bin/koha/admin/branch_transfer_limits.pl" id="selectlibrary">
27
    <form method="get" action="/cgi-bin/koha/admin/branch_transfer_limits.pl" id="selectlibrary">
24
        <label for="branchselect">Select a library :</label>
28
        <label for="branchselect">Select a library :</label>
25
- 

Return to bug 23344