[ 2023927 ] Receivables Write-Off do not work
http://sourceforge.net/tracker/index.php?func=detail&aid=2023927&group_id=176962&atid=879332
This commit is contained in:
parent
02d5aa5645
commit
f5984501b4
|
@ -146,15 +146,15 @@ public class InvoiceWriteOff extends SvrProcess
|
||||||
sql.append(" AND IsSOTrx='N'");
|
sql.append(" AND IsSOTrx='N'");
|
||||||
//
|
//
|
||||||
if (p_DateInvoiced_From != null && p_DateInvoiced_To != null)
|
if (p_DateInvoiced_From != null && p_DateInvoiced_To != null)
|
||||||
sql.append(" AND TRIM(DateInvoiced) BETWEEN ")
|
sql.append(" AND TRUNC(DateInvoiced) BETWEEN ")
|
||||||
.append(DB.TO_DATE(p_DateInvoiced_From, true))
|
.append(DB.TO_DATE(p_DateInvoiced_From, true))
|
||||||
.append(" AND ")
|
.append(" AND ")
|
||||||
.append(DB.TO_DATE(p_DateInvoiced_To, true));
|
.append(DB.TO_DATE(p_DateInvoiced_To, true));
|
||||||
else if (p_DateInvoiced_From != null)
|
else if (p_DateInvoiced_From != null)
|
||||||
sql.append(" AND TRIM(DateInvoiced) >= ")
|
sql.append(" AND TRUNC(DateInvoiced) >= ")
|
||||||
.append(DB.TO_DATE(p_DateInvoiced_From, true));
|
.append(DB.TO_DATE(p_DateInvoiced_From, true));
|
||||||
else if (p_DateInvoiced_To != null)
|
else if (p_DateInvoiced_To != null)
|
||||||
sql.append(" AND TRIM(DateInvoiced) <= ")
|
sql.append(" AND TRUNC(DateInvoiced) <= ")
|
||||||
.append(DB.TO_DATE(p_DateInvoiced_To, true));
|
.append(DB.TO_DATE(p_DateInvoiced_To, true));
|
||||||
}
|
}
|
||||||
sql.append(" AND IsPaid='N' ORDER BY C_Currency_ID, C_BPartner_ID, DateInvoiced");
|
sql.append(" AND IsPaid='N' ORDER BY C_Currency_ID, C_BPartner_ID, DateInvoiced");
|
||||||
|
|
Loading…
Reference in New Issue