According to the DAC attribute on Ext Cost, the precision comes from the Companies ‘Price/Cost Decimal Places’ preference.
I believe the field is POLine.CuryLineAmt. This field is marked with the attribute PXDBCurrency which I believe looks up the precision from the currency (Currencies screen).
#region CuryLineAmt
public abstract class curyLineAmt : PX.Data.BQL.BqlDecimal.Field<curyLineAmt> { }
protected Decimal? _CuryLineAmt;
>PXDBCurrency(typeof(POLine.curyInfoID), typeof(POLine.lineAmt))]
>PXUIField(DisplayName = "Ext. Cost")]
>PXFormula(typeof(Mult<POLine.orderQty, POLine.curyUnitCost>))]
>PXDefault(TypeCode.Decimal, "0.0")]
>PXUIVerify(typeof(Where<curyLineAmt, GreaterEqual<decimal0>, Or<Not<POLineType.Goods.Contains<lineType>>>>), PXErrorLevel.Error, CS.Messages.FieldShouldNotBeNegative, typeof(curyLineAmt), MessageArgumentsAreFieldNames = true, CheckOnRowSelected = true)]
public virtual Decimal? CuryLineAmt
{
get
{
return this._CuryLineAmt;
}
set
{
this._CuryLineAmt = value;
}
}
#endregion
Unfortunately, to the best of my knowledge, this precision cannot be updated once the currency has been used. However, this isn’t a dead end! With a simple CacheAttached in a graph extension for the screen you want to modify, you can PXRemoveAttribute(PXDBCurrencyAttriubute) and then add PXDBDecimal(3) to make it display as 3 decimal places.
That code would looks something like this:
#region POLine_CuryLineAmt_CacheAttached
bPXMergeAttributes(Method = MergeMethod.Append)]
bPXRemoveBaseAttribute(typeof(PXDBCurrencyAttribute))]
bPXDBDecimal(3)]
protected virtual void POLine_CuryLineAmt_CacheAttached(PXCache sender) { }
#endregion
Do we have user interface preference to pre setup this. no need to customize. I setup setting in companies but it’s not effected in purchase
Do we have user interface preference to pre setup this. no need to customize. I setup setting in companies but it’s not effected in purchase
I believe the price/cost preference you marked is tied to the attribute uPXDBPriceCost]. (I think the quantity one is tied to PXDBQuantityAttribute.) Again, this would require a minor customization to change the instruction in the DAC (or override for a specific graph/screen) to use that preference over that of the currency for precision. The issue is that the field is currently defined with the attribute that instructs Acumatica to format the number of decimal places in accordance with the precision defined in the currency… and that precision cannot be updated once used at the currency level.
The level of difficulty of this sort of modification is minor, but I am not aware of any means of making such a change to this particular field without a customization.
Do we have user interface preference to pre setup this. no need to customize. I setup setting in companies but it’s not effected in purchase
I believe the PurchaseOrder.ExtCost (POLine.CuryLineAmt) precision can be changed on the currency screen however you can edit the precision in the currency if it is not yet used. The ExtCost field's precision can be changed to depend on the CommonSetup.decPlPrcCst in the company screen by creating a new custom attribute. This is possible because, according to the standard code, the ExtCost field uses the PXDBCurrency attribute, which depends on the currency's precision, while the UnitCost (POLine.CuryUnitCost) field uses the PXDBCurrencyPriceCost attribute, which depends on the Company by having an overridden function.
Hello,
To add to the above answers, the settings in Company screen are for Quantity and Unit Cost/Unit Price fields, and they are working correctly on your PO.
The Base Currency shown on your company is USD, a currency with only 2 Decimal places. How will you pay a vendor with less than a penny, if your PO extends the Dollars to 3 decimal places?
Therefore you may choose another currency, or accept the amounts rounded to the nearest penny, in addition to the customization options mentioned above.
Laura
Hi
You need to set the DisplayFormat
property to #0.000
for a decimal field.
Regards,
Sweta
#region POLine_CuryLineAmt_CacheAttached
PXMergeAttributes(Method = MergeMethod.Append)]
PXRemoveBaseAttribute(typeof(PXDBCurrencyAttribute))]
PXDBDecimal(3)]
protected virtual void POLine_CuryLineAmt_CacheAttached(PXCache sender) { }
#endregion
hi I have a same issue but on configuation entry screen- AM306000. any recommendations if this is only dev work and cannot be controlled from any settings in the system.
Reply
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.