I have been working on an updatable dashboard for open POs that you can update dates and unit price. I use a BPM to unapprove, make the changes, and reapprove the PO.
Some problems arise because this is not set up to do for multiple rows. Instead, I thought an ok work around would be to have the dashboard save after changing each row. Through a customization form event this somewhat works but errors still arise when other rows are not refreshed to show the real data so it thinks it is changing again if you were to click the save button.
To fix this, I thought I could save and refresh the dashboard after a row is changed. The customization will compile and save without and errors. When I restart the dashboard and make a change to a row, it crashes and Epicor is not responding no matter how long I leave it.
Here is the code that I added to save and refresh after a row change:
This does help similar to saving after every row change. The issue I am having though is when other rows are not refreshed so it attempts to save different results.
For example, I approve a PO on one line/release. If I click off the row it saves. If I do not refresh the dashboard the other lines of the same PO are still appearing as unapproved, so when I go to approve a different PO it throws an error.
But if I were to approve a PO on one line/release, click off the row, and then refresh the dashboard, then I can approve the other PO just fine.
To fix this I thought I could just get rid of the line in the customization that uses the MainController to save, but keep the RefreshTool line. This still causes Epicor to Not Respond. I actually just noticed that it could possibly come back after several minutes but no changes in the dashboard are made at all, so I do not think it is going through. Am I doing the refresh part right or is there a better way?
In the BAQ Designer, it ‘refreshes’ almost immediately when I click Get List in Analyze if that is what you mean. When I click Update for a particular row, it brings a Null Exception error but that is a different problem I believe because it does not occur in the Dashboard and was happening before I attempted any customization on the dashboard assembly and the update is made successfully after closing the error message.
Ok so we have quick in BAQ Designer, and slow in deployed dashboard. How quickly does the dashboard refresh in the dashboard designer (non deployed copy?)
The non-deployed version in dashboard designer refreshes instantly. More interesting when I use Test Application before deploying it instantly refreshes and updates so the crashing has to be because of the customization in the deployed dashboard assembly. Many issues are still occurring when I use the test application which I am trying to solve with the customization.
If I click approve on a PO and then approve on a different PO without refreshing first it gives an error.
The table ttResults has more than one record
The table ttResults has more than one record
The table ttResults has more than one record
The table ttResults has more than one record
POHeader is not available.
The table ttResults has more than one record
I have multiple dirty row turned off in the BAQ designer. Using the base only version of the dashboard it performs the same as in Test Application. It can function and refresh for single row use but messing with multiple rows causes some errors.
So I think we have narrowed down that for sure it’s the customization causing it to lock up, that’s a good start. Can you format and post the entire customization code?
I think you are right Chris. When I am refreshing, that changes a row which then causes it to refresh again and so on. What would be a better approach? My goal is to have the user avoid having to hit the save and refresh button after changing every single row.
If you can get ahold of AfterAdapterMethod for update, then you can call your refresh from there. As far as auto save, simply turn Multiple Dirty Rows off, then Epicor will auto save when you move to a new row.
Sorry I am pretty new to customizations and epicor in general. Thanks for your help. The Adapter list in the Form Event wizard doesn’t show anything. Do you know the specific adapter I should use?
I actually figured out I had quite bigger issues. In my BAQ directive, I was using GetByID and Update incorrectly which was throwing the Null exception in the BAQ Designer. It is also why I never saw any of the message boxes pop up that I had put in the directive. Once I fixed that, It works much better and does not throw any errors. I also got rid of the infinite loop customization issue. Thanks for all your help troubleshooting this!