Skip to content

Instantly share code, notes, and snippets.

Created February 17, 2023 20:22
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
Star You must be signed in to star a gist
What would you like to do?
public abstract class SOOrderEntry_Extension : PXGraphExtension<SOOrderEntry>
//declare the abstract protected access property as public
public abstract bool IsCopyOrder { get; set; }
//custom copy order class that is called from a process/action that is different than the standard copy order process
public virtual void CopyAutoOrder(SOOrder sourceOrder, CopyParamFilter copyFilter, HWAutoOrder autoOrder)
SOOrder order = PXCache<SOOrder>.CreateCopy(sourceOrder);
//set the copy order flag to true
IsCopyOrder = true;
//set our auto order flag
IsAutoOrder = true;
//call base copy order proc that the action calls.
Base.CopyOrderProc(sourceOrder, copyFilter);
//set additional properties from other fields on the SO Order to their proper fields
//save the order
catch { }
IsCopyOrder = false;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment