Hi Community,
I am facing a small issue while working on a customization.
I have added a custom field on the Branches (CS102000) screen, which uses the LocationStand DAC. However, I am unable to enable this field.
Here’s what I have tried so far
protected void Location_RowSelected(PXCache cache, PXRowSelectedEventArgs e)
{
var row = (Location)e.Row;
if (row == null) return;
// Enable custom fields
PXUIFieldAttribute.SetEnabled<LocationStand.usrCustomField>(cache, row, true);
;
}
I set the Enabled property of the field to True from Customization editor
Despite this, the field remains disabled.
public class LocationStand : PXCacheExtension<PX.Objects.CR.Standalone.Location>
{
public static bool IsActive()
{
return true;
}
#region UsrCustomField
[PXDBDecimal(2)]
[PXUIField(DisplayName = "Custom Field")]
[PXDefault(TypeCode.Decimal, "0.0", PersistingCheck = PXPersistingCheck.Nothing)]
public virtual Decimal? UsrCustomField { get; set; }
public abstract class usrCustomField : PX.Data.BQL.BqlDecimal.Field<usrCustomField> { }
#endregion
}
Is there any base functionality or system restriction preventing this field from being enabled? Or am I missing something in the customization ?
Any insights or suggestions would be greatly appreciated.
Thank you!