Projekt

Allgemein

Profil

« Zurück | Weiter » 

Revision 8cd05ad6

Von Moritz Bunkus vor mehr als 13 Jahren hinzugefügt

  • ID 8cd05ad64866ce200f888a35723ae4b7e24a2012
  • Vorgänger bd74780c
  • Nachfolger 61352a49

Globale Variablen $::userspath, $::templates, $::membersfile nach %::lx_office_conf verschoben

Unterschiede anzeigen:

SL/AM.pm
1434 1434
    $myconfig->{$item} = $form->{$item};
1435 1435
  }
1436 1436

  
1437
  $myconfig->save_member($main::memberfile);
1437
  $myconfig->save_member;
1438 1438

  
1439 1439
  my $auth = $main::auth;
1440 1440

  
SL/AP.pm
360 360
sub delete_transaction {
361 361
  $main::lxdebug->enter_sub();
362 362

  
363
  my ($self, $myconfig, $form, $spool) = @_;
363
  my ($self, $myconfig, $form) = @_;
364 364

  
365 365
  # connect to database
366 366
  my $dbh = $form->dbconnect_noauto($myconfig);
SL/BP.pm
221 221
sub delete_spool {
222 222
  $main::lxdebug->enter_sub();
223 223

  
224
  my ($self, $myconfig, $form, $spool) = @_;
224
  my ($self, $myconfig, $form) = @_;
225

  
226
  my $spool = $::lx_office_conf{paths}->{spool};
225 227

  
226 228
  # connect to database, turn AutoCommit off
227 229
  my $dbh = $form->dbconnect_noauto($myconfig);
......
264 266
sub print_spool {
265 267
  $main::lxdebug->enter_sub();
266 268

  
267
  my ($self, $myconfig, $form, $spool, $output) = @_;
269
  my ($self, $myconfig, $form, $output) = @_;
270

  
271
  my $spool = $::lx_office_conf{paths}->{spool};
268 272

  
269 273
  # connect to database
270 274
  my $dbh = $form->dbconnect($myconfig);
SL/BackgroundJob/CreatePeriodicInvoices.pm
238 238

  
239 239
  $form->throw_on_error(sub {
240 240
    eval {
241
      $form->parse_template(\%::myconfig, $::userspath);
241
      $form->parse_template(\%::myconfig);
242 242
      1;
243 243
    } || die $EVAL_ERROR->{error};
244 244
  });
SL/CT.pm
1156 1156

  
1157 1157
  delete $form->{OUT};
1158 1158

  
1159
  $form->parse_template($myconfig, $main::userspath);
1159
  $form->parse_template($myconfig);
1160 1160

  
1161 1161
  $main::lxdebug->leave_sub();
1162 1162
}
SL/Controller/Base.pm
179 179
                    PLUGIN_BASE  => 'SL::Template::Plugin',
180 180
                    INCLUDE_PATH => '.:templates/webpages',
181 181
                    COMPILE_EXT  => '.tcc',
182
                    COMPILE_DIR  => $::userspath . '/templates-cache',
182
                    COMPILE_DIR  => $::lx_office_conf{paths}->{userspath} . '/templates-cache',
183 183
                  }) || croak;
184 184

  
185 185
  return $self->{__basepriv_template_obj};
SL/DATEV.pm
58 58
  my $path;
59 59

  
60 60
  if ($token =~ m|^(\d+)-(\d+)-(\d+)$|) {
61
    $path = "${main::userspath}/datev-export-${1}-${2}-${3}";
61
    $path = $::lx_office_conf{paths}->{userspath} . "/datev-export-${1}-${2}-${3}";
62 62
  }
63 63

  
64 64
  $main::lxdebug->leave_sub();
......
84 84
sub clean_temporary_directories {
85 85
  $main::lxdebug->enter_sub();
86 86

  
87
  foreach my $path (glob "${main::userspath}/datev-export-*") {
87
  foreach my $path (glob($::lx_office_conf{paths}->{userspath} . "/datev-export-*")) {
88 88
    next unless (-d $path);
89 89

  
90 90
    my $mtime = (stat($path))[9];
SL/DN.pm
269 269
sub save_dunning {
270 270
  $main::lxdebug->enter_sub();
271 271

  
272
  my ($self, $myconfig, $form, $rows, $userspath, $spool) = @_;
272
  my ($self, $myconfig, $form, $rows) = @_;
273 273
  # connect to database
274 274
  my $dbh = $form->dbconnect_noauto($myconfig);
275 275

  
......
661 661

  
662 662
  $copies        *= 1;
663 663
  $copies         = 1 unless $copies;
664
  my $inputfiles  = join " ", map { "${main::spool}/$_ " x $copies } @{ $form->{DUNNING_PDFS} };
664
  my $spool       = $::lx_office_conf{paths}->{spool};
665
  my $inputfiles  = join " ", map { "$spool/$_ " x $copies } @{ $form->{DUNNING_PDFS} };
665 666
  my $dunning_id  = $form->{dunning_id};
666 667

  
667 668
  $dunning_id     =~ s|[^\d]||g;
......
690 691

  
691 692
  $in->close();
692 693

  
693
  map { unlink("${main::spool}/$_") } @{ $form->{DUNNING_PDFS} };
694
  map { unlink("$spool/$_") } @{ $form->{DUNNING_PDFS} };
694 695

  
695 696
  $main::lxdebug->leave_sub();
696 697
}
......
792 793
  $self->set_template_options($myconfig, $form);
793 794

  
794 795
  my $filename          = "dunning_${dunning_id}_" . Common::unique_id() . ".pdf";
795
  $form->{OUT}          = ">${main::spool}/$filename";
796
  my $spool             = $::lx_office_conf{paths}->{spool};
797
  $form->{OUT}          = ">${spool}/$filename";
796 798
  $form->{keep_tmpfile} = 1;
797 799

  
798 800
  delete $form->{tmpfile};
799 801

  
800 802
  push @{ $form->{DUNNING_PDFS} }, $filename;
801
  push @{ $form->{DUNNING_PDFS_EMAIL} }, { 'filename' => "${main::spool}/$filename",
803
  push @{ $form->{DUNNING_PDFS_EMAIL} }, { 'filename' => "${spool}/$filename",
802 804
                                           'name'     => "dunning_${dunning_id}.pdf" };
803 805

  
804
  $form->parse_template($myconfig, $main::userspath);
806
  $form->parse_template($myconfig);
805 807

  
806 808
  $dbh->disconnect() unless $provided_dbh;
807 809

  
......
885 887

  
886 888
  my $filename = Common::unique_id() . "dunning_invoice_${dunning_id}.pdf";
887 889

  
888
  $form->{OUT}          = ">$main::spool/$filename";
890
  my $spool             = $::lx_office_conf{paths}->{spool};
891
  $form->{OUT}          = ">$spool/$filename";
889 892
  $form->{keep_tmpfile} = 1;
890 893
  delete $form->{tmpfile};
891 894

  
892 895
  map { delete $form->{$_} } grep /^[a-z_]+_\d+$/, keys %{ $form };
893 896

  
894
  $form->parse_template($myconfig, $main::userspath);
897
  $form->parse_template($myconfig);
895 898

  
896 899
  restore_form($saved_form);
897 900

  
898 901
  push @{ $form->{DUNNING_PDFS} }, $filename;
899
  push @{ $form->{DUNNING_PDFS_EMAIL} }, { 'filename' => "${main::spool}/$filename",
902
  push @{ $form->{DUNNING_PDFS_EMAIL} }, { 'filename' => "${spool}/$filename",
900 903
                                           'name'     => "dunning_invoice_${dunning_id}.pdf" };
901 904

  
902 905
  $dbh->disconnect() unless $provided_dbh;
SL/DO.pm
491 491

  
492 492
  my $myconfig = \%main::myconfig;
493 493
  my $form     = $main::form;
494
  my $spool    = $main::spool;
494
  my $spool    = $::lx_office_conf{paths}->{spool};
495 495

  
496 496
  # connect to database
497 497
  my $dbh = $form->get_standard_dbh($myconfig);
SL/Dispatcher.pm
87 87
  # canonial globals. if it's not here, chances are it will get refactored someday.
88 88
  {
89 89
    no warnings 'once';
90
    $::userspath   = "users";
91
    $::templates   = "templates";
92
    $::memberfile  = "users/members";
93 90
    $::menufile    = "menu.ini";
94 91
    $::sendmail    = "| /usr/sbin/sendmail -t";
95 92
    $::lxdebug     = LXDebug->new;
......
193 190
    my $session_result = $::auth->restore_session;
194 191
    $::auth->create_or_refresh_session;
195 192

  
196
    $::form->error($::locale->text('System currently down for maintenance!')) if -e "$::userspath/nologin" && $script ne 'admin';
193
    $::form->error($::locale->text('System currently down for maintenance!')) if -e ($::lx_office_conf{paths}->{userspath} . "/nologin") && $script ne 'admin';
197 194

  
198 195
    if ($script eq 'login' or $script eq 'admin' or $script eq 'kopf') {
199 196
      $::form->{titlebar} = "Lx-Office " . $::locale->text('Version') . " $::form->{version}";
SL/Form.pm
861 861
     'PLUGIN_BASE'  => 'SL::Template::Plugin',
862 862
     'INCLUDE_PATH' => '.:templates/webpages',
863 863
     'COMPILE_EXT'  => '.tcc',
864
     'COMPILE_DIR'  => $::userspath . '/templates-cache',
864
     'COMPILE_DIR'  => $::lx_office_conf{paths}->{userspath} . '/templates-cache',
865 865
  })) || die;
866 866
}
867 867

  
......
1191 1191
sub parse_template {
1192 1192
  $main::lxdebug->enter_sub();
1193 1193

  
1194
  my ($self, $myconfig, $userspath) = @_;
1194
  my ($self, $myconfig) = @_;
1195 1195
  my $out;
1196 1196

  
1197 1197
  local (*IN, *OUT);
1198 1198

  
1199
  my $userspath = $::lx_office_conf{paths}->{userspath};
1200

  
1199 1201
  $self->{"cwd"} = getcwd();
1200 1202
  $self->{"tmpdir"} = $self->{cwd} . "/${userspath}";
1201 1203

  
SL/IS.pm
1362 1362
sub delete_invoice {
1363 1363
  $main::lxdebug->enter_sub();
1364 1364

  
1365
  my ($self, $myconfig, $form, $spool) = @_;
1365
  my ($self, $myconfig, $form) = @_;
1366 1366

  
1367 1367
  # connect to database
1368 1368
  my $dbh = $form->dbconnect_noauto($myconfig);
......
1398 1398
  $dbh->disconnect;
1399 1399

  
1400 1400
  if ($rc) {
1401
    my $spool = $::lx_office_conf{paths}->{spool};
1401 1402
    map { unlink "$spool/$_" if -f "$spool/$_"; } @spoolfiles;
1402 1403
  }
1403 1404

  
......
2080 2081
        # to distinguish case A and B the variable pricegroup_id_$i is used
2081 2082
        # for new articles this variable isn't defined, for loaded articles it is
2082 2083
        # sellprice can't be used, as it already has 0,00 set
2083
        
2084

  
2084 2085
        if ($pkr->{pricegroup_id} eq $form->{"pricegroup_id_$i"} and defined $form->{"pricegroup_id_$i"}) {
2085 2086
          # Case A
2086 2087
          $pkr->{selected}  = ' selected';
2087 2088

  
2088
        } elsif ($pkr->{pricegroup_id} eq $form->{customer_klass} 
2089
                 and not defined $form->{"pricegroup_id_$i"} 
2089
        } elsif ($pkr->{pricegroup_id} eq $form->{customer_klass}
2090
                 and not defined $form->{"pricegroup_id_$i"}
2090 2091
                 and $pkr->{price} != 0    # only use customer pricegroup price if it has a value, else use default_sellprice
2091 2092
                                           # for the case where pricegroup prices haven't been set
2092 2093
                ) {
SL/OE.pm
655 655
sub delete {
656 656
  $main::lxdebug->enter_sub();
657 657

  
658
  my ($self, $myconfig, $form, $spool) = @_;
658
  my ($self, $myconfig, $form) = @_;
659 659

  
660 660
  # connect to database
661 661
  my $dbh = $form->dbconnect_noauto($myconfig);
......
705 705
  $dbh->disconnect;
706 706

  
707 707
  if ($rc) {
708
    my $spool = $::lx_office_conf{paths}->{spool};
708 709
    foreach $spoolfile (@spoolfiles) {
709 710
      unlink "$spool/$spoolfile" if $spoolfile;
710 711
    }
SL/Template.pm
22 22
  my %params  = @_;
23 23
  my $package = "SL::Template::" . $params{type};
24 24

  
25
  $package->new($params{file_name}, $params{form}, $params{myconfig} || \%::myconfig, $params{userspath} || $::userspath);
25
  $package->new($params{file_name}, $params{form}, $params{myconfig} || \%::myconfig, $params{userspath} || $::lx_office_conf{paths}->{userspath});
26 26
}
27 27

  
28 28
1;
SL/User.pm
145 145
      }
146 146

  
147 147
      # update the tables
148
      if (!open(FH, ">$main::userspath/nologin")) {
148
      if (!open(FH, ">" . $::lx_office_conf{paths}->{userspath} . "/nologin")) {
149 149
        $form->show_generic_error($main::locale->text('A temporary file could not be created. ' .
150 150
                                                      'Please verify that the directory "#1" is writeable by the webserver.',
151
                                                      $main::userspath),
151
                                                      $::lx_office_conf{paths}->{userspath}),
152 152
                                  'back_button' => 1);
153 153
      }
154 154

  
......
166 166
      close(FH);
167 167

  
168 168
      # remove lock file
169
      unlink("$main::userspath/nologin");
169
      unlink($::lx_office_conf{paths}->{userspath} . "/nologin");
170 170

  
171 171
      my $menufile =
172 172
        $self->{"menustyle"} eq "v3" ? "menuv3.pl" :
bin/mozilla/admin.pl
144 144
    ::end_of_request();
145 145
  }
146 146

  
147
  if (-f $main::memberfile) {
147
  my $memberfile = $::lx_office_conf{paths}->{memberfile};
148
  if (-f $memberfile) {
148 149
    my $memberdir = "";
149 150

  
150
    if ($main::memberfile =~ m|^.*/|) {
151
    if ($memberfile =~ m|^.*/|) {
151 152
      $memberdir = $&;
152 153
    }
153 154

  
......
155 156

  
156 157
    $form->{title} = $locale->text('User data migration');
157 158
    $form->header();
158
    print $form->parse_html_template('admin/user_migration', { 'memberfile' => $main::memberfile,
159
    print $form->parse_html_template('admin/user_migration', { 'memberfile' => $memberfile,
159 160
                                                               'backupdir'  => $backupdir });
160 161

  
161 162
    ::end_of_request();
......
179 180
  $main::auth->set_session_value('rpw', $form->{rpw});
180 181
  $main::auth->create_or_refresh_session();
181 182

  
182
  if (!-f $main::memberfile) {
183
  my $memberfile = $::lx_office_conf{paths}->{memberfile};
184
  if (!-f $memberfile) {
183 185
    # New installation -- create a standard group with full access
184 186
    my %members;
185 187
    my $group = {
......
203 205

  
204 206
  my $memberdir = "";
205 207

  
206
  if ($main::memberfile =~ m|^.*/|) {
208
  my $memberfile = $::lx_office_conf{paths}->{memberfile};
209
  if ($memberfile =~ m|^.*/|) {
207 210
    $memberdir = $&;
208 211
  }
209 212

  
......
213 216
    $form->error(sprintf($locale->text('The directory "%s" could not be created:\n%s'), $backupdir, $!));
214 217
  }
215 218

  
216
  copy $main::memberfile, "users/member-file-migration/members";
219
  copy $memberfile, "users/member-file-migration/members";
217 220

  
218
  my $in = IO::File->new($main::memberfile, "r");
221
  my $in = IO::File->new($memberfile, "r");
219 222

  
220 223
  $form->error($locale->text('Could not open the old memberfile.')) if (!$in);
221 224

  
......
266 269
    }
267 270
  }
268 271

  
269
  unlink $main::memberfile;
272
  unlink $memberfile;
270 273

  
271 274
  my @member_list = sort { lc $a->{login} cmp lc $b->{login} } values %members;
272 275

  
......
341 344
  map { $_->{templates} =~ s|.*/||; } values %members;
342 345

  
343 346
  $form->{title}   = "Lx-Office ERP " . $locale->text('Administration');
344
  $form->{LOCKED}  = -e "$main::userspath/nologin";
347
  $form->{LOCKED}  = -e _nologin_file_name();
345 348
  $form->{MEMBERS} = [ @members{sort { lc $a cmp lc $b } keys %members} ];
346 349

  
347 350
  $form->header();
......
411 414
  }
412 415

  
413 416
  # is there a templates basedir
414
  if (!-d "$main::templates") {
415
    $form->error(sprintf($locale->text("The directory %s does not exist."), $main::templates));
417
  if (!-d $::lx_office_conf{paths}->{templates}) {
418
    $form->error(sprintf($locale->text("The directory %s does not exist."), $::lx_office_conf{paths}->{templates}));
416 419
  }
417 420

  
418
  opendir TEMPLATEDIR, "$main::templates/." or $form->error("$main::templates : $ERRNO");
421
  opendir TEMPLATEDIR, $::lx_office_conf{paths}->{templates} or $form->error($::lx_office_conf{paths}->{templates} . " : $ERRNO");
419 422
  my @all     = readdir(TEMPLATEDIR);
420
  my @alldir  = sort grep { -d "$main::templates/$_" && !/^\.\.?$/ } @all;
421
  my @allhtml = sort grep { -f "$main::templates/$_" && /\.html$/ } @all;
423
  my @alldir  = sort grep { -d ($::lx_office_conf{paths}->{templates} . "/$_") && !/^\.\.?$/ } @all;
424
  my @allhtml = sort grep { -f ($::lx_office_conf{paths}->{templates} . "/$_") &&  /\.html$/ } @all;
422 425
  closedir TEMPLATEDIR;
423 426

  
424 427
  @alldir = grep !/\.(html|tex|sty|odt|xml|txb)$/, @alldir;
......
497 500
  }
498 501

  
499 502
  # is there a basedir
500
  if (!-d "$main::templates") {
501
    $form->error(sprintf($locale->text("The directory %s does not exist."), $main::templates));
503
  if (!-d $::lx_office_conf{paths}->{templates}) {
504
    $form->error(sprintf($locale->text("The directory %s does not exist."), $::lx_office_conf{paths}->{templates}));
502 505
  }
503 506

  
504 507
  # add base directory to $form->{templates}
505 508
  $form->{templates} =~ s|.*/||;
506
  $form->{templates} =  "$main::templates/$form->{templates}";
509
  $form->{templates} =  $::lx_office_conf{paths}->{templates} . "/$form->{templates}";
507 510

  
508 511
  my $myconfig = new User($form->{login});
509 512

  
......
522 525
  $myconfig->save_member();
523 526

  
524 527
  $form->{templates}       =~ s|.*/||;
525
  $form->{templates}       =  "$main::templates/$form->{templates}";
528
  $form->{templates}       =  $::lx_office_conf{paths}->{templates} . "/$form->{templates}";
526 529
  $form->{mastertemplates} =~ s|.*/||;
527 530

  
528 531
  # create user template directory and copy master files
......
534 537
      umask(007);
535 538

  
536 539
      # copy templates to the directory
537
      opendir TEMPLATEDIR, "$main::templates/." or $form->error("$main::templates : $ERRNO");
540
      opendir TEMPLATEDIR, $::lx_office_conf{paths}->{templates} or $form->error($::lx_office_conf{paths}->{templates} . " : $ERRNO");
538 541
      my @templates = grep /$form->{mastertemplates}.*?\.(html|tex|sty|odt|xml|txb)$/,
539 542
        readdir TEMPLATEDIR;
540 543
      closedir TEMPLATEDIR;
541 544

  
542 545
      foreach my $file (@templates) {
543
        open(TEMP, "$main::templates/$file")
544
          or $form->error("$main::templates/$file : $ERRNO");
546
        open(TEMP, $::lx_office_conf{paths}->{templates} . "/$file")
547
          or $form->error($::lx_office_conf{paths}->{templates} . "/$file : $ERRNO");
545 548

  
546 549
        $file =~ s/\Q$form->{mastertemplates}\E-//;
547 550
        open(NEW, ">$form->{templates}/$file")
......
1097 1100
  my $form   = $main::form;
1098 1101
  my $locale = $main::locale;
1099 1102

  
1100
  unlink "$main::userspath/nologin";
1103
  unlink _nologin_file_name();;
1101 1104

  
1102 1105
  $form->{callback} = "admin.pl?action=list_users";
1103 1106

  
......
1109 1112
  my $form   = $main::form;
1110 1113
  my $locale = $main::locale;
1111 1114

  
1112
  open(FH, ">$main::userspath/nologin")
1115
  open(FH, ">" . _nologin_file_name())
1113 1116
    or $form->error($locale->text('Cannot create Lock!'));
1114 1117
  close(FH);
1115 1118

  
......
1180 1183
  ::end_of_request() if SL::DBUpgrade2->new(form => $::form, dbdriver => 'Pg', auth => 1)->apply_admin_dbupgrade_scripts(1);
1181 1184
}
1182 1185

  
1186
sub _nologin_file_name {
1187
  return $::lx_office_conf{paths}->{userspath} . '/nologin';
1188
}
1189

  
1183 1190
1;
bin/mozilla/ap.pl
1178 1178

  
1179 1179
  $main::auth->assert('general_ledger');
1180 1180

  
1181
  if (AP->delete_transaction(\%myconfig, \%$form, $main::spool)) {
1181
  if (AP->delete_transaction(\%myconfig, \%$form)) {
1182 1182
    # saving the history
1183 1183
    if(!exists $form->{addition}) {
1184 1184
      $form->{snumbers} = qq|invnumber_| . $form->{invnumber};
bin/mozilla/bp.pl
341 341
  $form->{callback} .= "&header=1" if $form->{callback};
342 342

  
343 343
  $form->redirect($locale->text('Removed spoolfiles!'))
344
    if (BP->delete_spool(\%myconfig, \%$form, $main::spool));
344
    if (BP->delete_spool(\%myconfig, \%$form));
345 345
  $form->error($locale->text('Cannot remove files!'));
346 346

  
347 347
  $main::lxdebug->leave_sub();
......
373 373
    if ($form->{"checked_$i"}) {
374 374
      $form->info($locale->text('Printing ... '));
375 375

  
376
      if (BP->print_spool(\%myconfig, \%$form, $main::spool, "| $selected_printer")) {
376
      if (BP->print_spool(\%myconfig, \%$form, "| $selected_printer")) {
377 377
        print $locale->text('done');
378 378
        $form->redirect($locale->text('Marked entries printed!'));
379 379
      }
......
537 537
  my $i = 0;
538 538
  my $j = 0;
539 539
  my $spoolfile;
540
  my $spool = $::lx_office_conf{paths}->{spool};
540 541

  
541 542
  foreach my $ref (@{ $form->{SPOOL} }) {
542 543

  
......
566 567
      "<td><a href=$module?action=edit&id=$ref->{id}&type=$form->{type}&callback=$callback>$ref->{quonumber}</a></td>";
567 568
    $column_data{name}      = "<td>$ref->{name}</td>";
568 569
    $column_data{spoolfile} =
569
      qq|<td><a href=$main::spool/$ref->{spoolfile}>$ref->{spoolfile}</a></td>
570
      qq|<td><a href=$spool/$ref->{spoolfile}>$ref->{spoolfile}</a></td>
570 571
<input type=hidden name="spoolfile_$i" value=$ref->{spoolfile}>
571 572
|;
572 573

  
bin/mozilla/dn.pl
222 222
      foreach my $level (values %{ $levels }) {
223 223
        next unless scalar @{ $level };
224 224

  
225
        DN->save_dunning(\%myconfig, $form, $level, $main::userspath, $main::spool);
225
        DN->save_dunning(\%myconfig, $form, $level);
226 226
      }
227 227
    }
228 228

  
......
235 235
                      "customer_id"            => $form->{"customer_id_$i"},
236 236
                      "next_dunning_config_id" => $form->{"next_dunning_config_id_$i"},
237 237
                      "email"                  => $form->{"email_$i"}, } ];
238
      DN->save_dunning(\%myconfig, $form, $level, $main::userspath, $main::spool);
238
      DN->save_dunning(\%myconfig, $form, $level);
239 239
    }
240 240
  }
241 241

  
bin/mozilla/io.pl
1611 1611
    my $filename;
1612 1612
    if ($filename = $queued{ $form->{formname} }) {
1613 1613
      $form->{queued} =~ s/\Q$form->{formname} $filename\E//;
1614
      unlink "$main::spool/$filename";
1614
      unlink $::lx_office_conf{paths}->{spool} . "/$filename";
1615 1615
      $filename =~ s/\..*$//g;
1616 1616
    } else {
1617 1617
      $filename = time;
......
1619 1619
    }
1620 1620

  
1621 1621
    $filename .= ($form->{postscript}) ? '.ps' : '.pdf';
1622
    $form->{OUT} = ">$main::spool/$filename";
1622
    $form->{OUT} = ">" . $::lx_office_conf{paths}->{spool} . "/$filename";
1623 1623

  
1624 1624
    # add type
1625 1625
    $form->{queued} .= " $form->{formname} $filename";
......
1647 1647
  }
1648 1648
  # /saving the history
1649 1649

  
1650
  $form->parse_template(\%myconfig, $main::userspath);
1650
  $form->parse_template(\%myconfig);
1651 1651

  
1652 1652
  $form->{callback} = "";
1653 1653

  
bin/mozilla/is.pl
964 964

  
965 965
  $main::auth->assert('invoice_edit');
966 966

  
967
  if (IS->delete_invoice(\%myconfig, \%$form, $main::spool)) {
967
  if (IS->delete_invoice(\%myconfig, \%$form)) {
968 968
    # saving the history
969 969
    if(!exists $form->{addition}) {
970 970
    $form->{snumbers} = qq|invnumber_| . $form->{invnumber};
bin/mozilla/oe.pl
1271 1271
    $msg = $locale->text('Quotation deleted!');
1272 1272
    $err = $locale->text('Cannot delete quotation!');
1273 1273
  }
1274
  if (OE->delete(\%myconfig, \%$form, $main::spool)){
1274
  if (OE->delete(\%myconfig, \%$form)){
1275 1275
    # saving the history
1276 1276
    if(!exists $form->{addition}) {
1277 1277
      $form->{snumbers} = qq|ordnumber_| . $form->{ordnumber};
bin/mozilla/rp.pl
2071 2071
        $form->{attachment_filename} =  $locale->quote_special_chars('filenames', $locale->text("Statement") . "_$form->{todate}.$attachment_suffix");
2072 2072
        $form->{attachment_filename} =~ s/\s+/_/g;
2073 2073

  
2074
        $form->parse_template(\%myconfig, $main::userspath);
2074
        $form->parse_template(\%myconfig);
2075 2075

  
2076 2076
      }
2077 2077
    }
config/lx-erp.conf
9 9
  $userspath, $vertreter, $webdav, $xvfb_bin
10 10
);
11 11

  
12
# path to user configuration files
13
$userspath = "users";
14

  
15
# spool directory for batch printing
16
$spool = "spool";
17

  
18
# templates base directory
19
$templates = "templates";
20

  
21
# member file
22
$memberfile = "users/members";
23

  
24 12
# Wenn Einnahmen-Überschussrechnung, dann auf 1 setzen
25 13
# Wenn Bilanzierung (z.B. GmbH), dann auf 0 setzen
26 14
$eur = 1;
config/lx-erp.conf.default
9 9
  $userspath, $vertreter, $webdav, $xvfb_bin
10 10
);
11 11

  
12
# path to user configuration files
13
$userspath = "users";
14

  
15
# spool directory for batch printing
16
$spool = "spool";
17

  
18
# templates base directory
19
$templates = "templates";
20

  
21
# member file
22
$memberfile = "users/members";
23

  
24 12
# Wenn Einnahmen-Überschussrechnung, dann auf 1 setzen
25 13
# Wenn Bilanzierung (z.B. GmbH), dann auf 0 setzen
26 14
$eur = 1;
config/lx_office.conf.default
1
[paths]
2
# path to temporary files (must be writeable by the web server)
3
userspath = users
4
# spool directory for batch printing
5
spool = spool
6
# templates base directory
7
templates = templates
8
# Path to the old memberfile (ignored on new installations)
9
memberfile = users/members
10

  
1 11
[task_server]
2 12
# User name to use for database access
3 13
login = mb
scripts/console
60 60
  package main;
61 61

  
62 62
  { no warnings 'once';
63
    $::userspath  = "users";
64
    $::templates  = "templates";
65 63
    $::sendmail   = "| /usr/sbin/sendmail -t";
66 64
  }
67 65

  
scripts/rose_auto_create_model.pl
42 42

  
43 43
  my $login     = shift @ARGV;
44 44

  
45
  $::userspath  = "users";
46
  $::templates  = "templates";
47 45
  $::sendmail   = "| /usr/sbin/sendmail -t";
48 46

  
49 47
  $::lxdebug    = LXDebug->new();
scripts/spawn_oo.pl
5 5
  push    @INC, "modules/fallback"; # Only use our own versions of modules if there's no system version.
6 6
}
7 7

  
8

  
8 9
use DBI;
9 10
use Data::Dumper;
10 11

  
......
13 14
use SL::Form;
14 15
use SL::Template;
15 16

  
16
$userspath  = "users";
17
$templates  = "templates";
18
$memberfile = "users/members";
19 17
$sendmail   = "| /usr/sbin/sendmail -t";
20 18

  
21 19
$| = 1;
scripts/task_server.pl
43 43
  package main;
44 44

  
45 45
  { no warnings 'once';
46
    $::userspath  = "users";
47
    $::templates  = "templates";
48 46
    $::sendmail   = "| /usr/sbin/sendmail -t";
49 47
  }
50 48

  

Auch abrufbar als: Unified diff