Revision 8c7e4493
Von Moritz Bunkus vor fast 17 Jahren hinzugefügt
bin/mozilla/licenses.pl | ||
---|---|---|
46 | 46 |
|
47 | 47 |
sub form_header { |
48 | 48 |
$lxdebug->enter_sub(); |
49 |
|
|
50 |
$auth->assert('license_edit'); |
|
51 |
|
|
49 | 52 |
$form->{jsscript} = 1; |
50 | 53 |
$form->header(); |
51 | 54 |
|
... | ... | |
58 | 61 |
|
59 | 62 |
sub form_footer { |
60 | 63 |
$lxdebug->enter_sub(); |
61 |
my @items = qw(login password old_callback previousform); |
|
64 |
|
|
65 |
$auth->assert('license_edit'); |
|
66 |
|
|
67 |
my @items = qw(old_callback previousform); |
|
62 | 68 |
push(@items, @{ $form->{"hidden"} }); |
63 | 69 |
map({ |
64 | 70 |
print("<input type=hidden name=$_ value=\"" . quot($form->{$_}) . "\">\n" |
... | ... | |
81 | 87 |
|
82 | 88 |
sub print_part_selection { |
83 | 89 |
$lxdebug->enter_sub(); |
90 |
|
|
91 |
$auth->assert('license_edit'); |
|
92 |
|
|
84 | 93 |
form_header(); |
85 | 94 |
set_std_hidden("business"); |
86 | 95 |
|
... | ... | |
135 | 144 |
|
136 | 145 |
sub print_customer_selection { |
137 | 146 |
$lxdebug->enter_sub(); |
147 |
|
|
148 |
$auth->assert('license_edit'); |
|
149 |
|
|
138 | 150 |
form_header(); |
139 | 151 |
set_std_hidden("parts_id", "partnumber", "description"); |
140 | 152 |
|
... | ... | |
195 | 207 |
|
196 | 208 |
sub print_license_form { |
197 | 209 |
$lxdebug->enter_sub(); |
210 |
|
|
211 |
$auth->assert('license_edit'); |
|
212 |
|
|
198 | 213 |
print( |
199 | 214 |
qq| |
200 | 215 |
<table width=100%> |
... | ... | |
281 | 296 |
|
282 | 297 |
sub add { |
283 | 298 |
$lxdebug->enter_sub(); |
299 |
|
|
300 |
$auth->assert('license_edit'); |
|
301 |
|
|
284 | 302 |
if (!$lizenzen) { |
285 | 303 |
$form->error( |
286 | 304 |
$locale->text( |
... | ... | |
296 | 314 |
|
297 | 315 |
sub do_add { |
298 | 316 |
$lxdebug->enter_sub(); |
317 |
|
|
318 |
$auth->assert('license_edit'); |
|
319 |
|
|
299 | 320 |
$form->{"hidden"} = ["parts_id"]; |
300 | 321 |
form_header(); |
301 | 322 |
|
... | ... | |
360 | 381 |
|
361 | 382 |
sub update { |
362 | 383 |
$lxdebug->enter_sub(); |
384 |
|
|
385 |
$auth->assert('license_edit'); |
|
386 |
|
|
363 | 387 |
do_add(); |
388 |
|
|
364 | 389 |
$lxdebug->leave_sub(); |
365 | 390 |
} |
366 | 391 |
|
... | ... | |
373 | 398 |
sub save { |
374 | 399 |
$lxdebug->enter_sub(); |
375 | 400 |
|
401 |
$auth->assert('license_edit'); |
|
402 |
|
|
376 | 403 |
($form->{customername}, $form->{customer_id}) = split /--/, |
377 | 404 |
$form->{customer}; |
378 | 405 |
|
... | ... | |
421 | 448 |
|
422 | 449 |
# put callback together |
423 | 450 |
foreach $key (keys %$form) { |
451 |
next if (($key eq 'login') || ($key eq 'password') || ('' ne ref $form->{$key})); |
|
424 | 452 |
|
425 | 453 |
# do single escape for Apache 2.0 |
426 | 454 |
$value = $form->escape($form->{$key}, 1); |
... | ... | |
443 | 471 |
|
444 | 472 |
sub search { |
445 | 473 |
$lxdebug->enter_sub(); |
474 |
|
|
475 |
$auth->assert('license_edit'); |
|
476 |
|
|
446 | 477 |
if (!$lizenzen) { |
447 | 478 |
$form->error( |
448 | 479 |
$locale->text( |
... | ... | |
498 | 529 |
|
499 | 530 |
sub do_search { |
500 | 531 |
$lxdebug->enter_sub(); |
532 |
|
|
533 |
$auth->assert('license_edit'); |
|
534 |
|
|
501 | 535 |
LICENSES->search(\%myconfig, $form); |
502 | 536 |
|
503 | 537 |
$callback = ""; |
504 | 538 |
map { $callback .= "\&${_}=" . $form->escape($form->{$_}, 1) } |
505 |
qw(db login password partnumber description customer_name all expiring_in show_expired);
|
|
539 |
qw(db partnumber description customer_name all expiring_in show_expired); |
|
506 | 540 |
$details = $form->{"script"} . "?action=details" . $callback . "\&id="; |
507 | 541 |
$invdetails = "is.pl?action=edit" . $callback . "\&id="; |
508 | 542 |
$callback = $form->{"script"} . "?action=do_search" . $callback; |
... | ... | |
606 | 640 |
|
607 | 641 |
sub details { |
608 | 642 |
$lxdebug->enter_sub(); |
643 |
|
|
644 |
$auth->assert('license_edit'); |
|
645 |
|
|
609 | 646 |
LICENSES->get_license(\%myconfig, $form); |
610 | 647 |
map( |
611 | 648 |
{ $form->{$_} = $form->{"license"}->{$_}; } keys(%{ $form->{"license"} })); |
Auch abrufbar als: Unified diff
Umstellung der Benutzerverwaltung von Dateien im Verzeichnis "users" auf die Verwendung einer Authentifizierungsdatenbank.
Es ist erforderlich, die Dateien doc/UPGRADE und doc/INSTALL/index.html zu lesen und die angesprochenen Punkte auszuführen, um nach einem Upgrade weiter arbeiten zu können.