Lines 49-55
use C4::Context;
Link Here
|
49 |
use C4::Koha qw( getallthemes ); |
49 |
use C4::Koha qw( getallthemes ); |
50 |
use C4::Languages qw( getTranslatedLanguages ); |
50 |
use C4::Languages qw( getTranslatedLanguages ); |
51 |
use C4::ClassSource qw( GetClassSources GetClassSource ); |
51 |
use C4::ClassSource qw( GetClassSources GetClassSource ); |
52 |
use C4::Output qw( output_html_with_http_headers ); |
52 |
use C4::Output qw( output_html_with_http_headers output_and_exit_if_error ); |
53 |
use YAML::XS; |
53 |
use YAML::XS; |
54 |
|
54 |
|
55 |
my %tabsysprefs; #we do no longer need to keep track of a tab per pref (yaml) |
55 |
my %tabsysprefs; #we do no longer need to keep track of a tab per pref (yaml) |
Lines 235-240
if ($op) {
Link Here
|
235 |
} |
235 |
} |
236 |
|
236 |
|
237 |
if ( $op eq 'update_and_reedit' ) { |
237 |
if ( $op eq 'update_and_reedit' ) { |
|
|
238 |
output_and_exit_if_error($input, $cookie, $template, { check => 'csrf_token' }); |
238 |
foreach ( $input->param ) { |
239 |
foreach ( $input->param ) { |
239 |
} |
240 |
} |
240 |
my $value = ''; |
241 |
my $value = ''; |
Lines 302-307
if ( $op eq 'add_form' ) {
Link Here
|
302 |
################## ADD_VALIDATE ################################## |
303 |
################## ADD_VALIDATE ################################## |
303 |
# called by add_form, used to insert/modify data in DB |
304 |
# called by add_form, used to insert/modify data in DB |
304 |
} elsif ( $op eq 'add_validate' ) { |
305 |
} elsif ( $op eq 'add_validate' ) { |
|
|
306 |
output_and_exit_if_error($input, $cookie, $template, { check => 'csrf_token' }); |
305 |
# to handle multiple values |
307 |
# to handle multiple values |
306 |
my $value; |
308 |
my $value; |
307 |
|
309 |
|
Lines 348-353
if ( $op eq 'add_form' ) {
Link Here
|
348 |
################## DELETE_CONFIRMED ################################## |
350 |
################## DELETE_CONFIRMED ################################## |
349 |
# called by delete_confirm, used to effectively confirm deletion of data in DB |
351 |
# called by delete_confirm, used to effectively confirm deletion of data in DB |
350 |
} elsif ( $op eq 'delete_confirmed' ) { |
352 |
} elsif ( $op eq 'delete_confirmed' ) { |
|
|
353 |
output_and_exit_if_error($input, $cookie, $template, { check => 'csrf_token' }); |
351 |
C4::Context->delete_preference($searchfield); |
354 |
C4::Context->delete_preference($searchfield); |
352 |
# END $OP eq DELETE_CONFIRMED |
355 |
# END $OP eq DELETE_CONFIRMED |
353 |
################## DEFAULT ################################## |
356 |
################## DEFAULT ################################## |