Problem with Updating the data in a dataview with events in Kinetic

In the kinetic ‘Purchase Order Entry’ screen I have created a field (Text box) in the Line > Details page for a drawing number. I have it ep-binded to the field in the dataview that I have created that pulls data from the PartRev table which has the Drawing number. (see image below)

I have created a event which first clears the dataview, then runs a rest-erp through Erp.BO.PartSvc (GetByID) that passes through the part number for ‘PODetail.PartNum’ and returns the data into the dataview. I also noticed theres different events that the PODetail.PartNum changes like ‘RowChanging_PODetail’, ‘OnClick_grdPODetail’, ‘ColumnChanging_PODetail_PartNum’ and a few more.

My problem is for tying it to the ‘OnClick_grdPODetail’ and the ‘ColumnChanging_PartNum’ event it works fine, clearing the dataview, then the rest-erp populates it based on the part number saved to PODetail.PartNum. But the event ‘OnClick_grdPODetail’ only runs when you first click the the line through the POHeader screen, and the ‘ColumnChanging_PartNum’ event only runs when you change the text box value manually. I need it to work the same when you change the part number by switching lines from the arrows above (Event: ‘ColumnChanging_PODetail_PartNum’). The events are setup the same but for some reason it’s acting like the data isn’t clearing properly or else its grabbing the ‘PODetail.PartNum’ before it changes in PODetail so it grabs the information from the previously selected PartNum (See imagess below)
I’ve also added a field called ‘View Part Number’ under ‘Drawing Number’ for reference that pulls the part number from the ‘DT_PartRev’ dataview. The 'Drawing number is always be the right one for the ‘View Part Number’ (because they are pulling from the same dataview) but I’m trying to get the View Part Number to match the PODetail.PartNum (basically I need the View part number to update upon changing the ‘PODetail.PartNum’). If I can get those 2 to match then the drawing number will also be correct.

Any ideas on what I should try?

Here’s the Video

Hi Elden, you ever figure this one out? I’m fighting the same issue.

Yes, I was able to figure somewhat of a solution that seems to be working.

I created a data view from the PartRev table (the table that shows the drawnum).
Then I created an event that basically goes like this:


(I had to tie the same event to 3 different triggers which means there were 3 different events)

  1. Trigger
    image First trigger

image Second trigger

image Third trigger

  1. Clear the data view (for some reason I couldn’t get it to refresh without clearing the data view)
  2. Check if part exists (using the Part.PartExists rest-erp service passing PartNumber from PODetail.PartNum) (this value is automatically stored inside a variable called actionresult.returnObj)
    image

image

  1. If the output was true, then I would run the Part.GetByID service (step 5)
    image

  2. Run the rest-erp for Part.GetByID and push the results to the dataview (also you have to create this through the condition or it doesn’t work, meaning you click the “true” box on the parameter and add the rest-erp through there.
    image

image

Sorry for the long post, trying to explain in as much detail as possible because I wish I had these details when creating it the first time.

Also, there might be a faster or more efficient way to do this. I couldn’t find a single event that triggered for every time I wanted it to update so I used three.

Also, for the RowChanged_SysPages event trigger, it likes to not fill in the PODetail data view yet so when I created that event it just has an extra condition that checks to make sure the PartNum is not “undefined” which is Epicor’s way of saying null. Then the event is created through the “false” option and its the same from there.


image

Hope this helps, lmk if you have questions. :slight_smile:

Forgot to mention this one last event which is tied to the Row Changed for PODetail


its setup the same as the others

I think before it was updating on “Row Changing” and not “Row Changed”

Wonderful! Thank you so much. I think the Data Clear is where I was stumbling.