ONLYOFFICE / sdkjs-plugins

The add-ons for ONLYOFFICE Document Server and ONLYOFFICE Desktop Editors.
https://www.onlyoffice.com
Apache License 2.0
136 stars 134 forks source link

postMessage and onMessage is not work in onlyoffice 7.2.2 #177

Closed rill closed 1 year ago

rill commented 1 year ago

Do you want to request a feature or report a bug? bug.

What is the current behavior? postMessage and onMessage is not work in oo 7.2.2 is not work. oo 7.1.1 is ok.

If the current behavior is a bug, please provide the steps to reproduce and if possible a minimal demo of the problem.

  1. add th official plugin externallistener to my plugin path. The plugin code url is https://github.com/ONLYOFFICE/sdkjs-plugins/tree/master/externallistener

  2. send message to the plugins

let dataMessage = {
        frameEditorId : "test",
        guid : "asc.{A8705DEE-7544-4C33-B3D5-168406D92F72}",
        type : "onExternalPluginMessage",
        data : {
          type: "insertText",
          text: "123"
        }
      };
      let onlineOfficeEditorIframeList = document.getElementsByName("frameEditor");
      if(onlineOfficeEditorIframeList){
        let onlineOfficeEditorIframe = onlineOfficeEditorIframeList[0];
         iframeWin.postMessage(JSON.stringify(dataMessage), '*')
      }
  1. send onExternalPluginMessage to the plugins

    When use onlyoffice 7.1.1 ,it will insert 123 to the document. When use onlyoffice 7.2.2,it don't work. What is the expected behavior? What's the problem?Why 7.2.2 is not work,but 7.1.1 is OK. Which versions of sdkjs-plugins, and which browser / OS are affected by this issue? Did this work in previous versions of sdkjs-plugins?

The sdkjs-plugins version is 5.5.3.42. The browser is Chrome.

fr3fou commented 1 year ago

any updates on this?

askonev commented 1 year ago

@rill Thank you for your reference! I've documented the bug in our private bug tracker. #61097

K0R0L commented 1 year ago

Do you have "ONLYOFFICE Developer Edition" version? Now it works only with that license. Also see the new api for integration https://api.onlyoffice.com/editors/connector.

askonev commented 1 year ago

The use of the functionality is transferred to a paid license. Close Issue