Projekt

Allgemein

Profil

« Zurück | Weiter » 

Revision 203d1f43

Von Jan Büren vor mehr als 2 Jahren hinzugefügt

  • ID 203d1f43e40f5b831313c30854b75993a2e75576
  • Vorgänger 437c5cd4
  • Nachfolger 25a68a25

fx_loss doch erstmal ignorieren für invoice_amount

Unterschiede anzeigen:

SL/Controller/BankTransaction.pm
transdate => $bank_transaction->valutadate->to_kivitendo);
# First element is the booked amount for accno bank
my $booked_amount = shift @acc_ids;
# hotfix why
$booked_amount = $bank_transaction->amount if abs($booked_amount > $bank_transaction->invoice_amount);
$bank_transaction->invoice_amount($bank_transaction->invoice_amount + $booked_amount * $sign);
# ... and record the origin via BankTransactionAccTrans
if (scalar(@acc_ids) < 2) {
SL/DB/Helper/Payment.pm
my $fxloss_chart = SL::DB::Manager::Chart->find_by(id => $::instance_conf->get_fxloss_accno_id) || die "Can't determine fxloss chart";
$main::lxdebug->message(0, 'was sagt gain loss' . $fx_gain_loss_amount);
my $gain_loss_chart = $fx_gain_loss_amount > 0 ? $fxgain_chart : $fxloss_chart;
$paid_amount += abs($fx_gain_loss_amount); # if $fx_gain_loss_amount < 0; # only add if we have fx_loss
# $paid_amount += abs($fx_gain_loss_amount); # if $fx_gain_loss_amount < 0; # only add if we have fx_loss
$paid_amount += $fx_gain_loss_amount if $fx_gain_loss_amount < 0; # only add if we have fx_loss
$main::lxdebug->message(0, 'paid2 ' . $paid_amount);
$main::lxdebug->message(0, 'paid2chart ' . $fx_gain_loss_amount);
# $fx_gain_loss_amount = $gain_loss_amount;

Auch abrufbar als: Unified diff