Lines 22-27
use CGI qw ( -utf8 );
Link Here
|
22 |
use C4::Context; |
22 |
use C4::Context; |
23 |
use C4::Output qw( output_html_with_http_headers ); |
23 |
use C4::Output qw( output_html_with_http_headers ); |
24 |
use C4::Auth qw( get_template_and_user ); |
24 |
use C4::Auth qw( get_template_and_user ); |
|
|
25 |
use Koha::Exceptions::Exception; |
25 |
use Koha::DateUtils qw( dt_from_string output_pref ); |
26 |
use Koha::DateUtils qw( dt_from_string output_pref ); |
26 |
use Koha::Database; |
27 |
use Koha::Database; |
27 |
use Koha::Logger; |
28 |
use Koha::Logger; |
Lines 461-466
elsif ( $op eq "add-max-daily-article-requests" ) {
Link Here
|
461 |
my $categorycode = $input->param('categorycode'); |
462 |
my $categorycode = $input->param('categorycode'); |
462 |
my $max_daily_article_requests = strip_non_numeric( scalar $input->param('max_daily_article_requests') ); |
463 |
my $max_daily_article_requests = strip_non_numeric( scalar $input->param('max_daily_article_requests') ); |
463 |
|
464 |
|
|
|
465 |
Koha::Exceptions::Exception->throw("No value passed for article request limit") |
466 |
if not defined $max_daily_article_requests # There is a JS check for that |
467 |
|| $max_daily_article_requests eq ''; |
468 |
|
464 |
if ( $branch eq "*" ) { |
469 |
if ( $branch eq "*" ) { |
465 |
if ( $categorycode eq "*" ) { |
470 |
if ( $categorycode eq "*" ) { |
466 |
Koha::CirculationRules->set_rules( |
471 |
Koha::CirculationRules->set_rules( |