Ernie
(Ernie Lowell)
May 9, 2019, 1:13pm
1
In the AR Invoice form, does anyone have the progression for filling the field “Calc_CustomerEmailAddress”? My guess would be:
Priimary Billing Contact email address
Customer email address
leave blank
but I can’t seem to find that anywhere (I’m starting testing now)
Thanks!
Ernie
(Ernie Lowell)
May 9, 2019, 1:35pm
2
In reality, it appears to skip the Primary Billing Contact email address altogether… and only uses the Customer email address.
Bummer!
This is how it gets its value in this order…ECC Customer Connect web order.
this.CustEMailAddress = this.ECCCnt.EMailAddress;
this.CustEMailAddress = this.Customer.EMailAddress;
Ernie
(Ernie Lowell)
May 9, 2019, 1:48pm
4
As per usual, you da MAN…
1 Like
ckrusen
(Calvin Krusen)
May 9, 2019, 2:06pm
5
Jose - How did you determine that? Do you have access to the source code run by the RDD? Or is this just from experience (i.e. testing / trial and error)?
Randy
(Randy Stulce)
May 9, 2019, 3:34pm
7
Interesting thread as I’m fighting a ARForm issue today too, but on how the RDD calculates the Calc_ExtPrice for the invoice line (InvcDtl). Specifically with Kits (KitPricing = “C”). Could you do another dive into the code?
For Kit
private void DoInvcKitsCalcparent(int PFactor)
{
if (this.FindFirstOrderDtl(base.Session.CompanyID, this.InvcDtl.OrderNum, this.InvcDtl.OrderLine, "P") != null)
{
foreach (InvcDtl binvcdtl in this.SelectInvcDtl(base.Session.CompanyID, this.InvcDtl.InvoiceNum, this.InvcDtl.InvoiceLine).ToList<InvcDtl>())
{
OrderDtl borderdtl = this.FindFirstOrderDtl(base.Session.CompanyID, binvcdtl.OrderNum, binvcdtl.OrderLine, "C");
if (borderdtl == null)
{
break;
}
int linePFactor = binvcdtl.PricePerCode.KeyEquals("M") ? 1000 : (binvcdtl.PricePerCode.KeyEquals("C") ? 100 : 1);
this.CalcExtPrice += this.LibRoundRulesEF.RoundRuleApply(binvcdtl.SellingShipQty * (binvcdtl.DocUnitPrice / linePFactor), this.LibRoundRulesEF.TypeAmt_ExtPrice, this.InvcHead.CurrencyCode);
this.DocLineTotalDisc += this.CalcExtPrice - binvcdtl.DocDiscount;
if (this.isMalaysiaLocalization)
{
if (string.IsNullOrEmpty(this.pCurrList) || string.IsNullOrEmpty(this.pRateList))
{
this.LibGetCurrencyRatesEF.FindCurrencyRates("InvcHead", Compatibility.Convert.ToString(this.InvoiceNum), "", "", "", "", "", "", "", out this.ttChainRows, out this.pCurrList, out this.pRateList, "");
}
this.CalcExtPriceBase = this.LibRoundAmountEF.ConvertAmtRoundDecimals(this.CalcExtPrice, this.InvcHead.CurrencyCode, this.sMYBaseCurrCode, this.ttChainRows, true, "InvcDtl", "ExtPrice");
}
this.CalcUnitPrice += this.LibRoundRulesEF.RoundRuleApply(binvcdtl.DocUnitPrice * borderdtl.KitQtyPer / linePFactor * PFactor, this.LibRoundRulesEF.TypeAmt_ExtPrice, this.InvcHead.CurrencyCode);
}
}
}
For not Kit
if (this.InvcDtl.ExtPrice != 0m)
{
this.CalcExtPrice = this.LibRoundRulesEF.RoundRuleApply(this.InvcDtl.DocExtPrice, this.LibRoundRulesEF.TypeAmt_ExtPrice, this.InvcHead.CurrencyCode);
}
else
{
this.CalcExtPrice = this.LibRoundRulesEF.RoundRuleApply(this.InvcDtl.SellingShipQty * (this.InvcDtl.DocUnitPrice / PFactor), this.LibRoundRulesEF.TypeAmt_ExtPrice, this.InvcHead.CurrencyCode);
}
1 Like
Randy
(Randy Stulce)
May 9, 2019, 4:03pm
9
Thanks @josecgomez , no wonder I was having problems reverse engineering this one.
1 Like