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

(-)a/admin/authorised_values.pl (-3 / +3 lines)
Lines 119-126 if ($op eq 'add_form') { Link Here
119
    elsif ( $id ) { # Update
119
    elsif ( $id ) { # Update
120
        my $av = Koha::AuthorisedValues->new->find( $id );
120
        my $av = Koha::AuthorisedValues->new->find( $id );
121
121
122
        $av->lib( $input->param('lib') || undef );
122
        $av->lib( scalar $input->param('lib') || undef );
123
        $av->lib_opac( $input->param('lib_opac') || undef );
123
        $av->lib_opac( scalar $input->param('lib_opac') || undef );
124
        $av->category( $new_category );
124
        $av->category( $new_category );
125
        $av->authorised_value( $new_authorised_value );
125
        $av->authorised_value( $new_authorised_value );
126
        $av->imageurl( $imageurl );
126
        $av->imageurl( $imageurl );
Lines 192-198 if ($op eq 'add_form') { Link Here
192
192
193
    $op = 'list';
193
    $op = 'list';
194
} elsif ($op eq 'delete') {
194
} elsif ($op eq 'delete') {
195
    my $av = Koha::AuthorisedValues->new->find( $input->param('id') );
195
    my $av = Koha::AuthorisedValues->new->find( $id );
196
    my $deleted = eval {$av->delete};
196
    my $deleted = eval {$av->delete};
197
    if ( $@ or not $deleted ) {
197
    if ( $@ or not $deleted ) {
198
        push @messages, {type => 'error', code => 'error_on_delete' };
198
        push @messages, {type => 'error', code => 'error_on_delete' };
(-)a/admin/classsources.pl (-10 / +11 lines)
Lines 34-40 my $input = new CGI; Link Here
34
my $op          = $input->param('op') || '';
34
my $op          = $input->param('op') || '';
35
my $source_code = $input->param('class_source');
35
my $source_code = $input->param('class_source');
36
my $rule_code   = $input->param('sort_rule');
36
my $rule_code   = $input->param('sort_rule');
37
37
my $sort_routine = $input->param('sort_routine');
38
my ($template, $loggedinuser, $cookie)
38
my ($template, $loggedinuser, $cookie)
39
    = get_template_and_user({template_name => "admin/classsources.tt",
39
    = get_template_and_user({template_name => "admin/classsources.tt",
40
                 query => $input,
40
                 query => $input,
Lines 46-60 my ($template, $loggedinuser, $cookie) Link Here
46
46
47
$template->param(script_name => $script_name);
47
$template->param(script_name => $script_name);
48
$template->param($op => 1) if $op;
48
$template->param($op => 1) if $op;
49
49
my $description = $input->param('description');
50
my $used = $input->param('used');
50
my $display_lists = 0;
51
my $display_lists = 0;
51
if ($op eq "add_source") {
52
if ($op eq "add_source") {
52
    add_class_source_form($template);
53
    add_class_source_form($template);
53
} elsif ($op eq "add_source_confirmed") {
54
} elsif ($op eq "add_source_confirmed") {
54
    add_class_source($template,
55
    add_class_source($template,
55
                     $source_code,
56
                     $source_code,
56
                     $input->param('description'),
57
                     $description,
57
                     $input->param('used') eq "used" ? 1 : 0,
58
                     $used eq "used" ? 1 : 0,
58
                     $rule_code);
59
                     $rule_code);
59
    $display_lists = 1;
60
    $display_lists = 1;
60
} elsif ($op eq "delete_source") {
61
} elsif ($op eq "delete_source") {
Lines 67-74 if ($op eq "add_source") { Link Here
67
} elsif ($op eq "edit_source_confirmed") {
68
} elsif ($op eq "edit_source_confirmed") {
68
    edit_class_source($template,
69
    edit_class_source($template,
69
                     $source_code,
70
                     $source_code,
70
                     $input->param('description'),
71
                     $description,
71
                     $input->param('used') eq "used" ? 1 : 0,
72
                     $used eq "used" ? 1 : 0,
72
                     $rule_code);
73
                     $rule_code);
73
    $display_lists = 1;
74
    $display_lists = 1;
74
} elsif ($op eq "add_sort_rule") {
75
} elsif ($op eq "add_sort_rule") {
Lines 76-83 if ($op eq "add_source") { Link Here
76
} elsif ($op eq "add_sort_rule_confirmed") {
77
} elsif ($op eq "add_sort_rule_confirmed") {
77
    add_class_sort_rule($template,
78
    add_class_sort_rule($template,
78
                        $rule_code,
79
                        $rule_code,
79
                        $input->param('description'),
80
                        $description,
80
                        $input->param('sort_routine'));
81
                        $sort_routine);
81
    $display_lists = 1;
82
    $display_lists = 1;
82
} elsif ($op eq "delete_sort_rule") {
83
} elsif ($op eq "delete_sort_rule") {
83
    delete_sort_rule_form($template, $rule_code);
84
    delete_sort_rule_form($template, $rule_code);
Lines 89-96 if ($op eq "add_source") { Link Here
89
} elsif ($op eq "edit_sort_rule_confirmed") {
90
} elsif ($op eq "edit_sort_rule_confirmed") {
90
    edit_class_sort_rule($template,
91
    edit_class_sort_rule($template,
91
                         $rule_code,
92
                         $rule_code,
92
                         $input->param('description'),
93
                         $description,
93
                         $input->param('sort_routine'));
94
                         $sort_routine);
94
    $display_lists = 1;
95
    $display_lists = 1;
95
} else {
96
} else {
96
    $display_lists = 1;
97
    $display_lists = 1;
(-)a/admin/edi_accounts.pl (-12 / +12 lines)
Lines 73-94 else { Link Here
73
        # validate & display
73
        # validate & display
74
        my $id     = $input->param('id');
74
        my $id     = $input->param('id');
75
        my $fields = {
75
        my $fields = {
76
            description        => $input->param('description'),
76
            description        => scalar $input->param('description'),
77
            host               => $input->param('host'),
77
            host               => scalar $input->param('host'),
78
            username           => $input->param('username'),
78
            username           => scalar $input->param('username'),
79
            password           => $input->param('password'),
79
            password           => scalar $input->param('password'),
80
            vendor_id          => $input->param('vendor_id'),
80
            vendor_id          => scalar $input->param('vendor_id'),
81
            upload_directory   => $input->param('upload_directory'),
81
            upload_directory   => scalar $input->param('upload_directory'),
82
            download_directory => $input->param('download_directory'),
82
            download_directory => scalar $input->param('download_directory'),
83
            san                => $input->param('san'),
83
            san                => scalar $input->param('san'),
84
            transport          => $input->param('transport'),
84
            transport          => scalar $input->param('transport'),
85
            quotes_enabled     => defined $input->param('quotes_enabled'),
85
            quotes_enabled     => defined $input->param('quotes_enabled'),
86
            invoices_enabled   => defined $input->param('invoices_enabled'),
86
            invoices_enabled   => defined $input->param('invoices_enabled'),
87
            orders_enabled     => defined $input->param('orders_enabled'),
87
            orders_enabled     => defined $input->param('orders_enabled'),
88
            responses_enabled  => defined $input->param('responses_enabled'),
88
            responses_enabled  => defined $input->param('responses_enabled'),
89
            auto_orders        => defined $input->param('auto_orders'),
89
            auto_orders        => defined $input->param('auto_orders'),
90
            id_code_qualifier  => $input->param('id_code_qualifier'),
90
            id_code_qualifier  => scalar $input->param('id_code_qualifier'),
91
            plugin             => $input->param('plugin'),
91
            plugin             => scalar $input->param('plugin'),
92
        };
92
        };
93
93
94
        if ($id) {
94
        if ($id) {
Lines 105-111 else { Link Here
105
    elsif ( $op eq 'delete_confirmed' ) {
105
    elsif ( $op eq 'delete_confirmed' ) {
106
106
107
        $schema->resultset('VendorEdiAccount')
107
        $schema->resultset('VendorEdiAccount')
108
          ->search( { id => $input->param('id'), } )->delete_all;
108
          ->search( { id => scalar $input->param('id'), } )->delete_all;
109
    }
109
    }
110
110
111
    # we do a default dispaly after deletes and saves
111
    # we do a default dispaly after deletes and saves
(-)a/admin/import_export_framework.pl (-1 / +1 lines)
Lines 84-90 if ($action eq 'export' && $input->request_method() eq 'GET') { Link Here
84
        my $extension = $1;
84
        my $extension = $1;
85
        my $uploadFd = $input->upload($fieldname);
85
        my $uploadFd = $input->upload($fieldname);
86
        if ($uploadFd && !$input->cgi_error) {
86
        if ($uploadFd && !$input->cgi_error) {
87
            my $tmpfilename = $input->tmpFileName($input->param($fieldname));
87
            my $tmpfilename = $input->tmpFileName(scalar $input->param($fieldname));
88
            $filename = $tmpfilename . '.' . $extension; # rename the tmp file with the extension
88
            $filename = $tmpfilename . '.' . $extension; # rename the tmp file with the extension
89
            $ok = ImportFramework($filename, $frameworkcode, 1) if (rename($tmpfilename, $filename));
89
            $ok = ImportFramework($filename, $frameworkcode, 1) if (rename($tmpfilename, $filename));
90
        }
90
        }
(-)a/admin/patron-attr-types.pl (-1 / +1 lines)
Lines 135-141 sub error_add_attribute_type_form { Link Here
135
    $template->param(
135
    $template->param(
136
        attribute_type_form => 1,
136
        attribute_type_form => 1,
137
        confirm_op => 'add_attribute_type_confirmed',
137
        confirm_op => 'add_attribute_type_confirmed',
138
        authorised_value_category => $input->param('authorised_value_category'),
138
        authorised_value_category => scalar $input->param('authorised_value_category'),
139
    );
139
    );
140
}
140
}
141
141
(-)a/clubs/clubs-add-modify.pl (-4 / +4 lines)
Lines 64-73 $date_end = $date_end ? dt_from_string($date_end) : undef; Link Here
64
if ( $cgi->param('name') ) {    # Update or create club
64
if ( $cgi->param('name') ) {    # Update or create club
65
    $club->set(
65
    $club->set(
66
        {
66
        {
67
            club_template_id => $cgi->param('club_template_id') || undef,
67
            club_template_id => scalar $cgi->param('club_template_id') || undef,
68
            name             => $cgi->param('name')             || undef,
68
            name             => scalar $cgi->param('name')             || undef,
69
            description      => $cgi->param('description')      || undef,
69
            description      => scalar $cgi->param('description')      || undef,
70
            branchcode       => $cgi->param('branchcode')       || undef,
70
            branchcode       => scalar $cgi->param('branchcode')       || undef,
71
            date_start       => $date_start,
71
            date_start       => $date_start,
72
            date_end         => $date_end,
72
            date_end         => $date_end,
73
            date_updated     => dt_from_string(),
73
            date_updated     => dt_from_string(),
(-)a/clubs/templates-add-modify.pl (-5 / +5 lines)
Lines 62-73 if ( $cgi->param('name') ) { # Update or create club Link Here
62
    $club_template->set(
62
    $club_template->set(
63
        {
63
        {
64
            id          => $id                        || undef,
64
            id          => $id                        || undef,
65
            name        => $cgi->param('name')        || undef,
65
            name        => scalar $cgi->param('name')        || undef,
66
            description => $cgi->param('description') || undef,
66
            description => scalar $cgi->param('description') || undef,
67
            branchcode  => $cgi->param('branchcode')  || undef,
67
            branchcode  => scalar $cgi->param('branchcode')  || undef,
68
            date_updated            => dt_from_string(),
68
            date_updated            => dt_from_string(),
69
            is_email_required       => $cgi->param('is_email_required') ? 1 : 0,
69
            is_email_required       => scalar $cgi->param('is_email_required') ? 1 : 0,
70
            is_enrollable_from_opac => $cgi->param('is_enrollable_from_opac') ? 1 : 0,
70
            is_enrollable_from_opac => scalar $cgi->param('is_enrollable_from_opac') ? 1 : 0,
71
        }
71
        }
72
    )->store();
72
    )->store();
73
73
(-)a/installer/install.pl (-1 / +1 lines)
Lines 245-251 elsif ( $step && $step == 3 ) { Link Here
245
245
246
        my ( $fwk_language, $list ) =
246
        my ( $fwk_language, $list ) =
247
          $installer->load_sql_in_order( $all_languages,
247
          $installer->load_sql_in_order( $all_languages,
248
            $query->param('framework') );
248
            scalar $query->param('framework') );
249
        $template->param(
249
        $template->param(
250
            "fwklanguage" => $fwk_language,
250
            "fwklanguage" => $fwk_language,
251
            "list"        => $list
251
            "list"        => $list
(-)a/members/housebound.pl (-22 / +22 lines)
Lines 86-98 if ( $method eq 'updateconfirm' and $houseboundprofile ) { Link Here
86
    # We have received the input from the profile edit form.  We must save the
86
    # We have received the input from the profile edit form.  We must save the
87
    # changes, and return to simple display.
87
    # changes, and return to simple display.
88
    $houseboundprofile->set({
88
    $houseboundprofile->set({
89
        day           => $input->param('day')           // q{},
89
        day           => scalar $input->param('day')           // q{},
90
        frequency     => $input->param('frequency')     // q{},
90
        frequency     => scalar $input->param('frequency')     // q{},
91
        fav_itemtypes => $input->param('fav_itemtypes') // q{},
91
        fav_itemtypes => scalar $input->param('fav_itemtypes') // q{},
92
        fav_subjects  => $input->param('fav_subjects')  // q{},
92
        fav_subjects  => scalar $input->param('fav_subjects')  // q{},
93
        fav_authors   => $input->param('fav_authors')   // q{},
93
        fav_authors   => scalar $input->param('fav_authors')   // q{},
94
        referral      => $input->param('referral')      // q{},
94
        referral      => scalar $input->param('referral')      // q{},
95
        notes         => $input->param('notes')         // q{},
95
        notes         => scalar $input->param('notes')         // q{},
96
    });
96
    });
97
    my $success = eval { return $houseboundprofile->store };
97
    my $success = eval { return $houseboundprofile->store };
98
    push @messages, { type => 'error', code => 'error_on_profile_store' }
98
    push @messages, { type => 'error', code => 'error_on_profile_store' }
Lines 103-115 if ( $method eq 'updateconfirm' and $houseboundprofile ) { Link Here
103
    # save it, and return to simple display.
103
    # save it, and return to simple display.
104
    $houseboundprofile = Koha::Patron::HouseboundProfile->new({
104
    $houseboundprofile = Koha::Patron::HouseboundProfile->new({
105
        borrowernumber => $patron->borrowernumber,
105
        borrowernumber => $patron->borrowernumber,
106
        day            => $input->param('day')           // q{},
106
        day            => scalar $input->param('day')           // q{},
107
        frequency      => $input->param('frequency')     // q{},
107
        frequency      => scalar $input->param('frequency')     // q{},
108
        fav_itemtypes  => $input->param('fav_itemtypes') // q{},
108
        fav_itemtypes  => scalar $input->param('fav_itemtypes') // q{},
109
        fav_subjects   => $input->param('fav_subjects')  // q{},
109
        fav_subjects   => scalar $input->param('fav_subjects')  // q{},
110
        fav_authors    => $input->param('fav_authors')   // q{},
110
        fav_authors    => scalar $input->param('fav_authors')   // q{},
111
        referral       => $input->param('referral')      // q{},
111
        referral       => scalar $input->param('referral')      // q{},
112
        notes          => $input->param('notes')         // q{},
112
        notes          => scalar $input->param('notes')         // q{},
113
    });
113
    });
114
    my $success = eval { return $houseboundprofile->store };
114
    my $success = eval { return $houseboundprofile->store };
115
    push @messages, { type => 'error', code => 'error_on_profile_create' }
115
    push @messages, { type => 'error', code => 'error_on_profile_create' }
Lines 130-140 if ( $method eq 'updateconfirm' and $houseboundprofile ) { Link Here
130
    # We have received input for editing a visit.  We must store and return to
130
    # We have received input for editing a visit.  We must store and return to
131
    # simple display.
131
    # simple display.
132
    $visit->set({
132
    $visit->set({
133
        borrowernumber      => $input->param('borrowernumber')      // q{},
133
        borrowernumber      => scalar $input->param('borrowernumber')      // q{},
134
        appointment_date    => dt_from_string($input->param('date') // q{}),
134
        appointment_date    => dt_from_string($input->param('date') // q{}),
135
        day_segment         => $input->param('segment')             // q{},
135
        day_segment         => scalar $input->param('segment')             // q{},
136
        chooser_brwnumber   => $input->param('chooser')             // q{},
136
        chooser_brwnumber   => scalar $input->param('chooser')             // q{},
137
        deliverer_brwnumber => $input->param('deliverer')           // q{},
137
        deliverer_brwnumber => scalar $input->param('deliverer')           // q{},
138
    });
138
    });
139
    my $success = eval { return $visit->store };
139
    my $success = eval { return $visit->store };
140
    push @messages, { type => 'error', code => 'error_on_visit_store' }
140
    push @messages, { type => 'error', code => 'error_on_visit_store' }
Lines 144-154 if ( $method eq 'updateconfirm' and $houseboundprofile ) { Link Here
144
    # We have received input for creating a visit.  We must store and return
144
    # We have received input for creating a visit.  We must store and return
145
    # to simple display.
145
    # to simple display.
146
    my $visit = Koha::Patron::HouseboundVisit->new({
146
    my $visit = Koha::Patron::HouseboundVisit->new({
147
        borrowernumber      => $input->param('borrowernumber')      // q{},
147
        borrowernumber      => scalar $input->param('borrowernumber')      // q{},
148
        appointment_date    => dt_from_string($input->param('date') // q{}),
148
        appointment_date    => dt_from_string($input->param('date') // q{}),
149
        day_segment         => $input->param('segment')             // q{},
149
        day_segment         => scalar $input->param('segment')             // q{},
150
        chooser_brwnumber   => $input->param('chooser')             // q{},
150
        chooser_brwnumber   => scalar $input->param('chooser')             // q{},
151
        deliverer_brwnumber => $input->param('deliverer')           // q{},
151
        deliverer_brwnumber => scalar $input->param('deliverer')           // q{},
152
    });
152
    });
153
    my $success = eval { return $visit->store };
153
    my $success = eval { return $visit->store };
154
    push @messages, { type => 'error', code => 'error_on_visit_create' }
154
    push @messages, { type => 'error', code => 'error_on_visit_create' }
(-)a/opac/opac-overdrive-search.pl (-1 / +1 lines)
Lines 41-46 $template->{'VARS'}->{'q'} = $cgi->param('q'); Link Here
41
$template->{'VARS'}->{'limit'} = C4::Context->preference('OPACnumSearchResults') || 20;
41
$template->{'VARS'}->{'limit'} = C4::Context->preference('OPACnumSearchResults') || 20;
42
$template->{'VARS'}->{'OPACnumSearchResults'} = C4::Context->preference('OPACnumSearchResults') || 20;
42
$template->{'VARS'}->{'OPACnumSearchResults'} = C4::Context->preference('OPACnumSearchResults') || 20;
43
$template->{'VARS'}->{'OverDriveLibraryID'} = C4::Context->preference('OverDriveLibraryID');
43
$template->{'VARS'}->{'OverDriveLibraryID'} = C4::Context->preference('OverDriveLibraryID');
44
$template->param(overdrive_error => $cgi->param('overdrive_error'));
44
$template->param(overdrive_error => scalar $cgi->param('overdrive_error'));
45
45
46
output_html_with_http_headers $cgi, $cookie, $template->output;
46
output_html_with_http_headers $cgi, $cookie, $template->output;
(-)a/opac/opac-user.pl (-3 / +2 lines)
Lines 318-325 if (C4::Context->preference("OPACAmazonCoverImages") or Link Here
318
318
319
$template->param(
319
$template->param(
320
    OverDriveCirculation => C4::Context->preference('OverDriveCirculation') || 0,
320
    OverDriveCirculation => C4::Context->preference('OverDriveCirculation') || 0,
321
    overdrive_error      => $query->param('overdrive_error') || undef,
321
    overdrive_error      => scalar $query->param('overdrive_error') || undef,
322
    overdrive_tab        => $query->param('overdrive_tab') || 0,
322
    overdrive_tab        => scalar $query->param('overdrive_tab') || 0,
323
);
323
);
324
324
325
my $patron_messages = Koha::Patron::Messages->search(
325
my $patron_messages = Koha::Patron::Messages->search(
326
- 

Return to bug 18632