I am trying to pull NeedByDate into our JMDemand grid within Job Manager. Since Job Manager is a prebuilt app, we are unable to simply place it within the view.
I am trying to write a BPM within Erp.BO.JobManager.GetMatrix that cross checks with the OrderRel/JobProd table and pulls in the matching NeedByDate.
The following is the custom code widget being used.
My original logic was was doing this taking the JobNum from the current JMDemand row, searching JobProd for that job, joining JobProd to OrderRel, and returning the FIRST matching OrderRel.
I think this was casuing problems since a single job can have multiple sales orders, multiple lines, and multiple releases in the JobProd table
This new solution looked at just the OrderRel since JMDemand contains OrderNum, OrderLine, and OrderRelNum.