Hello,
I got question on how to set checkbox value for a custom field in gridview on Sales Order screen? Here is my DAC
public class SOLineExt : PXCacheExtension<PX.Objects.SO.SOLine>
{
[PXBool]
[PXUIField(DisplayName= "Is Restricted")]
public virtual bool? UsrIsRestrictedField { get; set; }
public abstract class usrIsRestrictedField : PX.Data.BQL.BqlString.Field<usrIsRestrictedField> { }
}
and here is my graph extension
public class SOOrderEntry_Extension : PXGraphExtension<PX.Objects.SO.SOOrderEntry>
{
#region Event Handlers
protected void SOLine_RowSelected(PXCache cache, PXRowSelectedEventArgs e)
{
var row = (SOLine)e.Row;
if(row != null)
{
ClaLimitInv.SOLineExt itemExt = PXCache<SOLine>.GetExtension<ClaLimitInv.SOLineExt>(row);
itemExt.UsrIsRestrictedField = true;
cache.SetStatus(row, PXEntryStatus.Updated);
}
}
}
in Customization Studio I set chebox like
and here is how my grid looks:
The problem “IsRestricted” checkbox is never set to checked