." AND trans.trans_no BETWEEN ".db_escape($from)." AND ".db_escape($to);
if ($currency !== false)
- " AND cust.curr_code=".db_escape($currency);
+ $sql .= " AND cust.curr_code=".db_escape($currency);
$sql .= " ORDER BY trans.tran_date, trans.$ref";
$rep->Font();
if ($email == 1)
{
- $rep->End($email);
+ $rep->End($email, sprintf(_("Invoice %d from %s"), $myrow['reference'], get_company_pref('coy_name')));
}
}
if ($email == 0)