Projekt

Allgemein

Profil

« Zurück | Weiter » 

Revision 891fe11e

Von Jan Büren vor fast 14 Jahren hinzugefügt

  • ID 891fe11e0c8386b11920ddd3d14947e6e4dfb7a6
  • Vorgänger 597846d8
  • Nachfolger 9978980b

FiBu -> Bericht -> Offene Forderung | Offene Verbindlichkeiten um Altersstrukturliste (30, 60, 90, 120) erweitert

Unterschiede anzeigen:

SL/RP.pm
1182 1182
    $dpt_join = qq| JOIN department d ON (a.department_id = d.id) |;
1183 1183
    $where .= qq| AND (a.department_id = | . conv_i($department_id, 'NULL') . qq|)|;
1184 1184
  }
1185
  my $review_of_aging_list;
1186
  if ($form->{review_of_aging_list}) {
1187
    if ($form->{review_of_aging_list} =~ m "-"){
1188
      my @period = split(/-/, $form->{review_of_aging_list});
1189
      $review_of_aging_list = " AND $period[0] < date_part('days', now() - duedate) 
1190
                                AND date_part('days', now() - duedate)  < $period[1]";
1191
    } else {
1192
      $form->{review_of_aging_list} =~ s/[^0-9]//g;
1193
      $review_of_aging_list = " AND $form->{review_of_aging_list} < date_part('days', now() - duedate)"; 
1194
    }
1195
  }
1185 1196

  
1186 1197
  my $q_details = qq|
1187
    -- between 0-30 days
1188 1198

  
1189 1199
    SELECT ${ct}.id AS ctid, ${ct}.name,
1190 1200
      street, zipcode, city, country, contact, email,
......
1202 1212
      AND (${arap}.${ct}_id = ${ct}.id)
1203 1213
      AND (${ct}.id = ?)
1204 1214
      AND (transdate <= (date $todate) $fromwhere )
1205

  
1215
      $review_of_aging_list
1206 1216
    ORDER BY ctid, transdate, invnumber |;
1207 1217

  
1208 1218
  my $sth_details = prepare_query($form, $dbh, $q_details);

Auch abrufbar als: Unified diff