Solved

Not able to load data into custom field in Customer Details(AR402000) screen

  • 16 February 2022
  • 5 replies
  • 212 views

Userlevel 2

Hello,

We have to load project id into customer details inquiry screen using custom field.

We have added a new custom field on customer details screen and not able to assign the project id value of the invoice. It is always returning an empty value even it is assigned in the code.

→ Extended the graph and overided the Document() view delegate.

→ In the debug, the value is assinging but it is not showing in the screen and I tried to add hardcoded value but still it is not working

 

→ I have used another method from view delegate to assign the value but still same issue.

 

I have attached the cusotmization package with the above code. Can anyone let me know the issue in this code or how can we load project id to customer details grid section.

Thanks in advance.

icon

Best answer by Naveen Boga 16 February 2022, 13:45

View original

5 replies

Userlevel 7
Badge +17

Hi @ssamboju12  Have you tried with Row_Updated event instead of view delegate?

According to me it should work with Row_Updated event. Please verify.

 

Userlevel 2

@Naveen B  Thanks for the response.

Row_Updated event is also not working.

 

public class ARDocumentEnq_Extension : PXGraphExtension<ARDocumentEnq>
{

public virtual void ARDocumentResult_RowUpdated(PXCache cache, PXRowUpdatedEventArgs e)
{
ARDocumentResult header = e.Row as ARDocumentResult;
if (header == null) return;
ARDocumentResultExt resext = header.GetExtension<ARDocumentResultExt>();
ARInvoice projobj = PXSelect<ARInvoice,
Where<ARInvoice.docType, Equal<Required<ARInvoice.docType>>,
And<ARInvoice.refNbr, Equal<Required<ARInvoice.refNbr>>>>>.Select(Base, header.DocType, header.RefNbr);
if (projobj != null)
{
resext.UsrASGProjectID = projobj.ProjectID;
}

}
}

 

Userlevel 7
Badge +17

Hi @ssamboju12  I’m not sure why it is not working, can you please check with ARDocumentResult_UsrASGProjectID_FieldSelecting event and confirm?

Userlevel 2

Hello @Naveen B 

Fieldselecting event worked finally. 

Thanks for the suggestion.

 

Userlevel 7
Badge +17

@ssamboju12  Great :) Thanks for the update. 

Reply


About Acumatica ERP system
Acumatica Cloud ERP provides the best business management solution for transforming your company to thrive in the new digital economy. Built on a future-proof platform with open architecture for rapid integrations, scalability, and ease of use, Acumatica delivers unparalleled value to small and midmarket organizations. Connected Business. Delivered.
© 2008 — 2024  Acumatica, Inc. All rights reserved