push_pin
lock
Function openCrmDocument not working in service.
Hello, we have a customer that uses the openCrmDocument function (which uses webtools) in order to open and edit S&M documents in the old service, but it seems like it stopped working after the latest update. Now when i try to edit the document, the call succeeds but the document won´t open, the document becomes locked for editing in S&M aswell. I tried this function in a onsite enviroment (Version 10.1.6) and it works as intended there.(The document is opening after pressing the button.) This is the function i have been using to test. openCrmDocument("Insert documentId here", "https://online4.superoffice.com/CustXXXXX"); function openCrmDocument(p_documentId, p_soUrl) { var postData = { "method": "SuperOffice.CRM.Web.AjaxMethods.Document.CheckoutAndOpenDocumentWithTrayApp", "arguments": [p_documentId] }; $.ajax({ type: "POST", dataType: "json", contentType: "application/json", data: JSON.stringify(postData), url: p_soUrl + "/clientapi/sessionrequiredmethods/method?ajaxmethod=SuperOffice.CRM.Web.AjaxMethods.Document.CheckoutAndOpenDocumentWithTrayApp" }) .done(function (result) { // Success console.log(result); console.log("Api call success") }) .fail(function (e) { console.log(e); alert( "Failed to open document, This is most likley because you havent installed SuperOffice Webtools." ); }); } Let me know if ii can provide any more information. Regards Fredrik
Fredrik.larsson@i-centrum.se
22. des. 2023 | 09:20 a.m.