This the context and the problem I am facing( I am using Dynamics 365 CE v9.x 2021 wave 1 release update)
To save the sales order data and close the sales order I am going to do it via JavaScript Xrm.WebApi.UpdateRecord.
Then I am going to look at the audit history and I see the user who did the change is not the user that performed the WebApi update request :O
Do you have any idea why? Could be some user or system setting? A bug by Microsoft?
Hi everyone one thanks a lot for your answer.
I fixed the problem. It was more complicated then excepted.
The JavaScript failed to change the status of the sales order.
To close as completed a sales order an other message request should be executed.
In the mean time a workflow was triggered on the business process flow entity related to that sales order when the bpf status is changed.
So I changed the workflow and I changed the JavaScript.
I am testing this change I will go to show it to our global super user to see if any use cases are missing in the bug fix Thank you Guido thank you chrwhal