I would like to code some actions that I can do manually:
- I have a sales order with two line items
- for one item a shipment was created.
- for the other item a production order was created
- the production order was completed and a move transaction was created
- Upon the “release” of the move transaction, I would like the below to occur via code:
- shipment screen; existing shipment for SO; “add order” dialog; select InventoryID that was just released from the “release”; click “add button”
I’ve been able to override the move/release button (below) but have no idea what code to write for the actual functionality.
public IEnumerable Release(PXAdapter adapter, ReleaseDelegate baseMethod)
{
var baseReturn = baseMethod(adapter);
var prodLines = Base.transactions.Select().RowCast<AMMTran>();
foreach (var prodLine in prodLines)
{
// TODO: code to add to shipment
}
return baseReturn;
}