@@ -, +, @@ defaults --- Koha/CirculationRules.pm | 4 +++- admin/smart-rules.pl | 8 +++----- tools/manage-marc-import.pl | 2 +- 3 files changed, 7 insertions(+), 7 deletions(-) --- a/Koha/CirculationRules.pm +++ a/Koha/CirculationRules.pm @@ -250,7 +250,7 @@ sub get_effective_rules { sub set_rule { my ( $self, $params ) = @_; - +warn Data::Dumper::Dumper( $params ); for my $mandatory_parameter (qw( rule_name rule_value ) ) { Koha::Exceptions::MissingParameter->throw( "Required parameter '$mandatory_parameter' missing") @@ -302,6 +302,7 @@ sub set_rule { } else { if ( defined $rule_value ) { + warn "presumably here"; $rule = Koha::CirculationRule->new( { branchcode => $branchcode, @@ -333,6 +334,7 @@ sub set_rules { my $rule_objects = []; while ( my ( $rule_name, $rule_value ) = each %$rules ) { + warn "name: $rule_name, value: $rule_value"; my $rule_object = Koha::CirculationRules->set_rule( { %set_params, --- a/admin/smart-rules.pl +++ a/admin/smart-rules.pl @@ -337,12 +337,10 @@ elsif ($op eq "set-branch-defaults") { my $patron_maxissueqty = strip_non_numeric( scalar $input->param('patron_maxissueqty') ); my $patron_maxonsiteissueqty = $input->param('patron_maxonsiteissueqty'); $patron_maxonsiteissueqty = strip_non_numeric($patron_maxonsiteissueqty); - my $holdallowed = $input->param('holdallowed'); - my $hold_fulfillment_policy = $input->param('hold_fulfillment_policy'); - my $returnbranch = $input->param('returnbranch'); + my $holdallowed = $input->param('holdallowed') || undef; + my $hold_fulfillment_policy = $input->param('hold_fulfillment_policy') || undef; + my $returnbranch = $input->param('returnbranch') || undef; my $max_holds = strip_non_numeric( scalar $input->param('max_holds') ); - $holdallowed =~ s/\s//g; - $holdallowed = undef if $holdallowed !~ /^\d+/; if ($branch eq "*") { Koha::CirculationRules->set_rules( --- a/tools/manage-marc-import.pl +++ a/tools/manage-marc-import.pl @@ -42,7 +42,7 @@ my $script_name = "/cgi-bin/koha/tools/manage-marc-import.pl"; my $input = new CGI; my $op = $input->param('op') || ''; my $completedJobID = $input->param('completedJobID'); -our $runinbackground = $input->param('runinbackground'); +our $runinbackground = 0;#$input->param('runinbackground'); my $import_batch_id = $input->param('import_batch_id') || ''; # record list displays --