Hello--
Was wondering if anyone can give me a hand with this… We essentially want an exact duplicate of the Description (OrderDesc) field that is already on sales order/invoices.
I have created a new field on each entry screen, but am stuck trying to pass the value from the SO to the invoice.
I assume I should override the PrepareInvoice action, but not sure how to actually reference the fields I have created?
I.e. This is as far as I got but i know “ ThisNewInvoice.CustomerSubject = row.CustomerSubject; “ is obviously wrong
Any help is appreciated!!
public class SOOrderEntryExt : PXGraphExtension<SOOrderEntry>
{
>PXOverride]
public IEnumerable PrepareInvoice(PXAdapter adapter, Func<PXAdapter, IEnumerable> baseMethod)
{
if(InvokeBaseHandler != null)
InvokeBaseHandler(cache, e);
var row = (SOOrder)e.Row;
ThisNewInvoice.CustomerSubject = row.CustomerSubject;
return baseMethod(adapter); // and then return
}