Projekt

Allgemein

Profil

« Zurück | Weiter » 

Revision 653ae9ea

Von Philip Reetz vor mehr als 16 Jahren hinzugefügt

  • ID 653ae9ea701b5c88f2ed720931c8e864a97aeaa4
  • Vorgänger 30a3e786
  • Nachfolger 56ed6467

Eingrenzung nach Datum bei offene Forderungen und Verbindlichkeiten

Unterschiede anzeigen:

SL/RP.pm
1303 1303

  
1304 1304
  $form->{todate} = $form->current_date($myconfig) unless ($form->{todate});
1305 1305
  my $todate = conv_dateq($form->{todate});
1306
  my $fromdate = conv_dateq($form->{fromdate});
1307

  
1308
  my $fromwhere = ($form->{fromdate} ne "") ? " AND (transdate >= (date $fromdate)) " : "";
1306 1309

  
1307 1310
  my $where = " 1 = 1 ";
1308 1311
  my ($name, $null);
......
1338 1341
      AND (${arap}.storno IS FALSE)
1339 1342
      AND (${arap}.${ct}_id = ${ct}.id)
1340 1343
      AND (${ct}.id = ?)
1341
      AND (transdate <= (date $todate))
1344
      AND (transdate <= (date $todate) $fromwhere )
1342 1345

  
1343 1346
    ORDER BY ctid, transdate, invnumber |;
1344 1347

  
......
1352 1355
       WHERE $where
1353 1356
         AND (a.${ct_id} = ct.id)
1354 1357
         AND ((a.paid != a.amount) OR ((a.datepaid > $todate) AND (datepaid is NOT NULL)))
1355
         AND (a.transdate <= $todate)
1358
         AND (a.transdate <= $todate $fromwhere)
1356 1359
       ORDER BY ct.name|;
1357 1360

  
1358 1361
  my $sth = prepare_execute_query($form, $dbh, $query);

Auch abrufbar als: Unified diff