Projekt

Allgemein

Profil

« Zurück | Weiter » 

Revision 3af5e2e0

Von Niclas Zimmermann vor mehr als 11 Jahren hinzugefügt

  • ID 3af5e2e0647403c1e6ee9b860d6a56d393e6e6f5
  • Vorgänger d1408ca1
  • Nachfolger dceb9f20

chart.link in der acc_trans

Enthält noch einige Ergänzungen zu commit
d1408ca13458a782cbde2b768cdd7abdbdcb9348. Es werden jetzt auch
periodisch erzeugte Rechnungen berücksichtigt und SEPA-Überweisungen
funktionieren wieder.

Weiterhin werden noch einige Syntax-Fehler behoben.

Unterschiede anzeigen:

SL/SEPA.pm
357 357
                               AND ((c.link LIKE '%:${ARAP}') OR (c.link LIKE '${ARAP}:%') OR (c.link = '${ARAP}'))
358 358
                             LIMIT 1| ],
359 359

  
360
    'add_acc_trans'  => [ qq|INSERT INTO acc_trans (trans_id, chart_id, amount, transdate, gldate,       source, memo, taxkey, tax_id)
361
                             VALUES                (?,        ?,        ?,      ?,         current_date, ?,      '',   0,      (SELECT id FROM tax WHERE taxkey=0 LIMIT 1))| ],
360
    'add_acc_trans'  => [ qq|INSERT INTO acc_trans (trans_id, chart_id, amount, transdate, gldate,       source, memo, taxkey, tax_id ,                                     chart_link)
361
                             VALUES                (?,        ?,        ?,      ?,         current_date, ?,      '',   0,      (SELECT id FROM tax WHERE taxkey=0 LIMIT 1), (SELECT link FROM chart WHERE id=?))| ],
362 362

  
363 363
    'update_arap'    => [ qq|UPDATE ${arap}
364 364
                             SET paid = paid + ?
......
397 397
    my ($arap_chart_id) = $handles{get_arap}->[0]->fetchrow_array();
398 398

  
399 399
    # Record the payment in acc_trans offsetting AR/AP.
400
    do_statement($form, @{ $handles{add_acc_trans} }, $orig_item->{"${arap}_id"}, $arap_chart_id,         -1 * $mult * $orig_item->{amount}, $item->{execution_date}, '');
401
    do_statement($form, @{ $handles{add_acc_trans} }, $orig_item->{"${arap}_id"}, $orig_item->{chart_id},      $mult * $orig_item->{amount}, $item->{execution_date}, $orig_item->{reference});
400
    do_statement($form, @{ $handles{add_acc_trans} }, $orig_item->{"${arap}_id"}, $arap_chart_id,         -1 * $mult * $orig_item->{amount}, $item->{execution_date}, '', $arap_chart_id);
401
    do_statement($form, @{ $handles{add_acc_trans} }, $orig_item->{"${arap}_id"}, $orig_item->{chart_id},      $mult * $orig_item->{amount}, $item->{execution_date}, $orig_item->{reference}, 
402
                                                      $orig_item->{chart_id});
402 403

  
403 404
    # Update the invoice to reflect the new paid amount.
404 405
    do_statement($form, @{ $handles{update_arap} }, $orig_item->{amount}, $orig_item->{"${arap}_id"});

Auch abrufbar als: Unified diff