Projekt

Allgemein

Profil

« Zurück | Weiter » 

Revision 3fcf64fc

Von Bernd Bleßmann vor fast 11 Jahren hinzugefügt

  • ID 3fcf64fc989a816e02251ea66fdc2bb0552cd3bb
  • Vorgänger 9ed4151c
  • Nachfolger 30645d2c

Versandort und Steuersatz (Zone) im Auftragsbericht filter- und anzeigbar

Unterschiede anzeigen:

SL/OE.pm
88 88
    qq|  ex.$rate AS exchangerate, | .
89 89
    qq|  pr.projectnumber AS globalprojectnumber, | .
90 90
    qq|  e.name AS employee, s.name AS salesman, | .
91
    qq|  ct.${vc}number AS vcnumber, ct.country, ct.ustid, ct.business_id  | .
91
    qq|  ct.${vc}number AS vcnumber, ct.country, ct.ustid, ct.business_id,  | .
92
    qq|  tz.description AS taxzone | .
92 93
    $periodic_invoices_columns .
93 94
    qq|FROM oe o | .
94 95
    qq|JOIN $vc ct ON (o.${vc}_id = ct.id) | .
......
97 98
    qq|LEFT JOIN exchangerate ex ON (ex.currency_id = o.currency_id | .
98 99
    qq|  AND ex.transdate = o.transdate) | .
99 100
    qq|LEFT JOIN project pr ON (o.globalproject_id = pr.id) | .
101
    qq|LEFT JOIN tax_zones tz ON (o.taxzone_id = tz.id) | .
100 102
    qq|$periodic_invoices_joins | .
101 103
    qq|WHERE (o.quotation = ?) |;
102 104
  push(@values, $quotation);
......
192 194
    push(@values, conv_date($form->{reqdateto}));
193 195
  }
194 196

  
197
  if ($form->{shippingpoint}) {
198
    $query .= qq| AND o.shippingpoint ILIKE ?|;
199
    push(@values, '%' . $form->{shippingpoint} . '%');
200
  }
201

  
202
  if ($form->{taxzone_id} ne '') { # taxzone_id could be 0
203
    $query .= qq| AND tz.id = ?|;
204
    push(@values, $form->{taxzone_id});
205
  }
206

  
195 207
  if ($form->{transaction_description}) {
196 208
    $query .= qq| AND o.transaction_description ILIKE ?|;
197 209
    push(@values, '%' . $form->{transaction_description} . '%');
......
214 226
    "employee"                => "e.name",
215 227
    "salesman"                => "s.name",
216 228
    "shipvia"                 => "o.shipvia",
217
    "transaction_description" => "o.transaction_description"
229
    "transaction_description" => "o.transaction_description",
230
    "shippingpoint"           => "o.shippingpoint",
231
    "taxzone"                 => "tz.description",
218 232
  );
219 233
  if ($form->{sort} && grep($form->{sort}, keys(%allowed_sort_columns))) {
220 234
    $sortorder = $allowed_sort_columns{$form->{sort}} . " ${sortdir}";

Auch abrufbar als: Unified diff