We are trying to implement a connector for our document management platform which allows users to create versions.
We are currently using the onRequestClose event to detect when the user selects the ‘save and close’ command so that we can ask about the document version details, before saving it to the DMS.
When the onRequestClose event is triggered, how can we determine if the document has been modified since opening or since last saved by another user ? This will avoid an unnecessary popup since the document is already saved.
Hello,
Thank you for the reply.
The popup is from our document management app. Here’s what the sequence of operations looks like :
the user selects a document in the DMS, then clicks on the ‘edit’ icon
a new tab is opened with the onlyoffice document editor (much like in the example app from the development version)
the user makes changes and clicks the ‘save and close’ icon the upper-right corner
when onRequestClose event is triggered we display a popup asking the user what kind of version he wants saved to the DMS
the version is saved
Our problem happens if step (3) does not happen. So the user opens the document, but makes no changes to it, then closes.
When the onRequestClose event is triggered we would like to check if the user (or any other user) modified the document, and if not, do not display our popup from step (4), since it is not necessary.
Of course, if there’s another way of doing this or if we’re using the editor the wrong way, please let us know.
Hello @stefanu
If you don’t mind, I will step to this thread.
When the onRequestClose event is triggered we would like to check if the user (or any other user) modified the document, and if not, do not display our popup from step (4), since it is not necessary.