Projekt

Allgemein

Profil

« Zurück | Weiter » 

Revision b56c0cd7

Von Bernd Blessmann vor etwa 13 Jahren hinzugefügt

  • ID b56c0cd76508a8d39e080f316285db1c52c17255
  • Vorgänger 80913703
  • Nachfolger c79db65d

Änderbarkeit bei Zahlungen f. Einkaufsrechnungen konfigurierbar.

Nie, immer oder am selben Tag, einstellbar in der lx_office.conf

Unterschiede anzeigen:

bin/mozilla/ir.pl
181 181
        $form->{"AP_paid_$i"} =
182 182
          "$form->{acc_trans}{$key}->[$i-1]->{accno}--$form->{acc_trans}{$key}->[$i-1]->{description}";
183 183

  
184
        $form->{"acc_trans_id_$i"} = $form->{acc_trans}{$key}->[$i - 1]->{acc_trans_id};
184 185
        # reverse paid
185 186
        $form->{"paid_$i"}     = $form->{acc_trans}{$key}->[$i - 1]->{amount};
186 187
        $form->{"datepaid_$i"} =
187 188
          $form->{acc_trans}{$key}->[$i - 1]->{transdate};
189
        $form->{"gldate_$i"}   = $form->{acc_trans}{$key}->[$i - 1]->{gldate};
188 190
        $form->{"forex_$i"} = $form->{"exchangerate_$i"} =
189 191
          $form->{acc_trans}{$key}->[$i - 1]->{exchangerate};
190 192
        $form->{"source_$i"} = $form->{acc_trans}{$key}->[$i - 1]->{source};
......
403 405
  my $accno_arap = IS->get_standard_accno_current_assets(\%myconfig, \%$form);
404 406

  
405 407
  for my $i (1 .. $form->{paidaccounts}) {
408
    $form->{"changeable_$i"} = 1;
409
    if ($::lx_office_conf{features}->{payments_changeable} == 0) {
410
      # never
411
      $form->{"changeable_$i"} = ($form->{"acc_trans_id_$i"})? 0 : 1;
412
    } elsif ($::lx_office_conf{features}->{payments_changeable} == 2) {
413
      # on the same day
414
      $form->{"changeable_$i"} = (($form->{"gldate_$i"} eq '') || 
415
                                  ($form->current_date(\%myconfig) eq $form->{"gldate_$i"}));
416
    }
417

  
406 418
    $form->{"selectAP_paid_$i"} = $form->{selectAP_paid};
407 419
    if (!$form->{"AP_paid_$i"}) {
408 420
      $form->{"selectAP_paid_$i"} =~ s/option>$accno_arap--(.*?)>/option selected>$accno_arap--$1>/;
......
560 572

  
561 573
  # Payments must not be recorded for the new storno invoice.
562 574
  $form->{paidaccounts} = 0;
563
  map { my $key = $_; delete $form->{$key} if grep { $key =~ /^$_/ } qw(datepaid_ source_ memo_ paid_ exchangerate_ AR_paid_) } keys %{ $form };
575
  map { my $key = $_; delete $form->{$key} if grep { $key =~ /^$_/ } qw(datepaid_ gldate_ acc_trans_id_ source_ memo_ paid_ exchangerate_ AR_paid_) } keys %{ $form };
564 576

  
565 577
  # saving the history
566 578
  if(!exists $form->{addition} && $form->{id} ne "") {
......
589 601

  
590 602
  $main::auth->assert('vendor_invoice_edit');
591 603

  
592
  map { delete $form->{$_} } qw(printed emailed queued invnumber invdate deliverydate id datepaid_1 source_1 memo_1 paid_1 exchangerate_1 AP_paid_1 storno);
604
  map { delete $form->{$_} } qw(printed emailed queued invnumber invdate deliverydate id datepaid_1 gldate_1 acc_trans_id_1 source_1 memo_1 paid_1 exchangerate_1 AP_paid_1 storno);
593 605
  $form->{paidaccounts} = 1;
594 606
  $form->{rowcount}--;
595 607
  $form->{invdate} = $form->current_date(\%myconfig);

Auch abrufbar als: Unified diff