Skip to main content

Generic Inquiry Redirect with Filters (Drilldown) From Code

  • September 19, 2021
  • 0 replies
  • 329 views

Forum|alt.badge.img

I wanted to redirect to a generic inquiry with a "Drilldown" tab similar to dashboard widget clicks.

After some research, I found the following method. 

string inqID = "cb567d54-187b-4466-a2e5-8776831ca6e9";
var url = new StringBuilder(PXGenericInqGrph.INQUIRY_URL).Append("?id=").Append(inqID).ToString();

List<PXFilterRow> filterRows = new List<PXFilterRow>();
filterRows.Add(new PXFilterRow("SOShipment_customerID", PXCondition.EQ, "AACUSTOMER"));
filterRows.Add(new PXFilterRow("SOShipment_siteID", PXCondition.EQ, "Retail"));

PXRedirectToUrlException ex = new PXRedirectToUrlException(url, PXBaseRedirectException.WindowMode.New, false, null);
ex.Filters.Add(new PXBaseRedirectException.Filter("Results", filterRows.ToArray(), "Drilldown"));

throw ex;

You have to add filter rows to the redirect exception.

 

You can learn more about GI redirects below.
https://asiablog.acumatica.com/2019/03/working-with-generic-inquiries-from-code.html

https://stackoverflow.com/questions/42537829/open-gi-on-button-click

 

I hope this is helpful!

Did this topic help you find an answer to your question?

0 replies

Be the first to reply!

Reply


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings