
Issue:
Whenever I open an RMA form, the Sub-Staus field will change to the default Sub-Status of the RMA Status. This is broken since if I select a different sub-status and close the form, this value will be lost when I reopen the Form.
*This post is locked for comments
I have the same question (0)Thought I'd share the solution to this issue since anyone using field service's latest update on CRM Online should be facing the same issue.
Solution:
This is caused by the OnLoad out of the box plugin from Microsoft which obviously has a mistake in it.
Step 1: Open the Web Resource msdyn_/RMA/RMA.Library.js (check first that the same js is being used "OnLoad" by checking your RMA Form properties):
Step 2: Make a backup of the original code just in case something goes wrong.
Step 3: Beautify the code to be able to read it (I use http://jsbeautifier.org/ but you can use a different one).
Step 4: Look for the line with the code "RMAs.Lib.SetSubStatus();" for me it's line 37
Step 5: Comment the line.
Step 6 (optional): Compress the JS again, be careful with compression tools you use as some will change your code to optimize it even further and I don't know how the CRM will react to it. I did not compress it.
Step 7: Update the Web Resource and Publish.
The SetSubStaus function is called every time the form is loaded, this is incorrect since it will overwrite any sub status value with the default one linked to the Status. The Onchange trigger just below is correct since it will set the proper SubStatus if the Status field changed.
The issue should be fixed :).