Skip to main content

Hi All,

 

I would like to ask regarding the stock warning. Is it possible to create a warning if the stock less than determined safety stock when creating Sales Order?

 

Thank you.

Hi @nadia02 

I believe we can do customization to trigger a yellow warning message when  stock is less than safety stock Just Like Acumatica showing available for shipping is zero thrown an error on hand qty goes negative

we can use the same logic but not sure t the result

 


Hi, @nadia02  Yes, you can show a warning message with the small piece of customization.

 

Here is the sample code for reference.

 public virtual void SOLine_InventoryID_FieldSelecting(PXCache sender, PXFieldSelectingEventArgs e, PXFieldSelecting InvokeBaseHandler)
{
InvokeBaseHandler?.Invoke(sender, e);
SOLine row = (SOLine)e.Row;
if (row == null) return;

if(ADD CONDITION)
{

PXUIFieldAttribute.SetWarning<SOLine.inventoryID>(sender, row, "Add Warning Message HERE!!");
}
}

 


Reply