Revision f2af9def
Von Moritz Bunkus vor fast 14 Jahren hinzugefügt
bin/mozilla/admin.pl | ||
---|---|---|
845 | 845 |
|
846 | 846 |
$form->{title} = "Lx-Office ERP " . $locale->text('Database Administration') . " / " . $locale->text('Backup Dataset'); |
847 | 847 |
|
848 |
if ("$main::pg_dump_exe" eq "DISABLED") {
|
|
848 |
if ($::lx_office_conf{applications}->{pg_dump} eq "DISABLED") {
|
|
849 | 849 |
$form->error($locale->text('Database backups and restorations are disabled in lx-erp.conf.')); |
850 | 850 |
} |
851 | 851 |
|
... | ... | |
867 | 867 |
|
868 | 868 |
$form->{title} = "Lx-Office ERP " . $locale->text('Database Administration') . " / " . $locale->text('Backup Dataset'); |
869 | 869 |
|
870 |
$main::pg_dump_exe ||= "pg_dump";
|
|
870 |
my $pg_dump_exe = $::lx_office_conf{applications}->{pg_dump} || "pg_dump";
|
|
871 | 871 |
|
872 |
if ("$main::pg_dump_exe" eq "DISABLED") {
|
|
872 |
if ("$pg_dump_exe" eq "DISABLED") { |
|
873 | 873 |
$form->error($locale->text('Database backups and restorations are disabled in lx-erp.conf.')); |
874 | 874 |
} |
875 | 875 |
|
... | ... | |
895 | 895 |
push @args, ("-p", $form->{dbport}) if ($form->{dbport}); |
896 | 896 |
push @args, $form->{dbname}; |
897 | 897 |
|
898 |
my $cmd = "$main::pg_dump_exe " . join(" ", map { s/\\/\\\\/g; s/\"/\\\"/g; $_ } @args);
|
|
898 |
my $cmd = "$pg_dump_exe " . join(" ", map { s/\\/\\\\/g; s/\"/\\\"/g; $_ } @args); |
|
899 | 899 |
my $name = "dataset_backup_$form->{dbname}_" . strftime("%Y%m%d", localtime()) . ".tar"; |
900 | 900 |
|
901 | 901 |
if ($form->{destination} ne "email") { |
... | ... | |
954 | 954 |
|
955 | 955 |
$form->{title} = "Lx-Office ERP " . $locale->text('Database Administration') . " / " . $locale->text('Restore Dataset'); |
956 | 956 |
|
957 |
if ("$main::pg_restore_exe" eq "DISABLED") {
|
|
957 |
if ($::lx_office_conf{applications}->{pg_restore} eq "DISABLED") {
|
|
958 | 958 |
$form->error($locale->text('Database backups and restorations are disabled in lx-erp.conf.')); |
959 | 959 |
} |
960 | 960 |
|
... | ... | |
979 | 979 |
|
980 | 980 |
$form->{title} = "Lx-Office ERP " . $locale->text('Database Administration') . " / " . $locale->text('Restore Dataset'); |
981 | 981 |
|
982 |
$main::pg_restore_exe ||= "pg_restore";
|
|
982 |
my $pg_restore_exe = $::lx_office_conf{applications}->{pg_restore} || "pg_restore";
|
|
983 | 983 |
|
984 |
if ("$main::pg_restore_exe" eq "DISABLED") {
|
|
984 |
if ("$pg_restore_exe" eq "DISABLED") { |
|
985 | 985 |
$form->error($locale->text('Database backups and restorations are disabled in lx-erp.conf.')); |
986 | 986 |
} |
987 | 987 |
|
... | ... | |
1068 | 1068 |
push @args, ("-p", $form->{dbport}) if ($form->{dbport}); |
1069 | 1069 |
push @args, $tmp; |
1070 | 1070 |
|
1071 |
my $cmd = "$main::pg_restore_exe " . join(" ", map { s/\\/\\\\/g; s/\"/\\\"/g; $_ } @args);
|
|
1071 |
my $cmd = "$pg_restore_exe " . join(" ", map { s/\\/\\\\/g; s/\"/\\\"/g; $_ } @args); |
|
1072 | 1072 |
|
1073 | 1073 |
my $in = IO::File->new("$cmd 2>&1 |"); |
1074 | 1074 |
|
Auch abrufbar als: Unified diff
Globale Variablen nach %::lx_office_conf verschoben
Betroffen sind:
$sendmail
$openofficeorg_writer_bin
$xvfb_bin
$html2ps_bin
$ghostscript_bin
$latex_bin
$pg_dump_exe
$pg_restore_exe