Document cooperation method and device, electronic equipment and storage medium
By responding to the editing side switching operation on the online document editing side, adjusting the local document editing side and loading the latest collaboration status, the problem of users stopping online collaboration when switching to the local client to edit documents is solved, seamless switching and continuing collaboration are achieved, and document collaboration experience is improved.
Patent Information
- Application Number
- CN202311739382.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2023-12-15
- Publication Date
- 2025-06-17
AI Technical Summary
In the prior art, during the document collaboration process, if a user wants to use a local client to edit a document, he needs to stop collaborating online, resulting in other collaborators being unable to continue accessing the document, affecting the collaboration experience.
When online collaboration is carried out on the online document editing end, the local document editing end is called in response to the editing end switch operation, and the target document in the latest collaborative editing state is loaded on the local document editing end, seamless switching and continuing collaboration are achieved.
It realizes that when switching from the online document editing end to the local document editing end, there is no need to stop online collaboration, which meets users' needs to use local clients to edit documents, and does not interrupt the online collaboration experience of other collaborators, improving the document collaboration experience.
Smart Images

Figure CN120163133A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of computers, and in particular, to a document collaboration method, apparatus, electronic device, and storage medium. Background Art
[0002] With the development of Internet and computer technologies, users increasingly use the collaboration functions provided by office software to complete collaborative editing or maintenance of documents.
[0003] However, in current office software, users perform document collaboration on the Web side. If, during the document collaboration process, a user wants to use a local client to edit the document, they need to first stop the online collaboration for the document, and then use the local client to open the document for editing. This makes it impossible for other collaborators to access the document when the document creator uses the client to edit the document, thus greatly affecting the document collaboration experience of other collaborators. Summary of the Invention
[0004] The present application provides a document collaboration method, apparatus, electronic device, and storage medium to solve the technical problem in the prior art that during the process of collaborating on a document, if a user wants to use a local client to edit the document, they need to stop the online collaboration for the document, resulting in other collaborators being unable to continue accessing the document and greatly affecting the document collaboration experience of other collaborators.
[0005] In a first aspect, the present application provides a document collaboration method, which includes:
[0006] When performing online collaboration on a target document on an online document editing end, in response to a first editing end switching operation, invoke a local document editing end and load the target document in the latest collaborative editing state on the local document editing end.
[0007] In a possible implementation manner, the step of, in response to a first editing end switching operation, invoking a local document editing end and loading the target document in the latest collaborative editing state includes:
[0008] In response to a first editing end switching operation, generate a document copy of the target document in the current collaborative editing state;
[0009] Invoke a local document editing end and load the document copy on the local document editing end.
[0010] In a possible implementation manner, the step of, in response to a first editing end switching operation, invoking a local document editing end includes:
[0011] In response to a first editing terminal switching operation, obtain the collaboration permission of the target collaborator for the target document, where the target collaborator is the collaborator logged in on the online document editing terminal;
[0012] When it is determined that the target collaborator has the collaboration permission to edit the target document using the local document editing terminal, invoke the local document editing terminal.
[0013] In a possible implementation manner, the method further includes:
[0014] When it is determined that the target collaborator does not have the collaboration permission to edit the target document using the local document editing terminal, send a permission opening request to the collaboration initiator of the target document;
[0015] When it is determined that the collaboration initiator opens the collaboration permission for the target collaborator to edit the target document using the local document editing terminal based on the permission opening request, invoke the local document editing terminal.
[0016] In a possible implementation manner, the method further includes:
[0017] When the local document editing terminal is invoked, synchronize the browsing process and user operation information of the target document on the online document editing terminal on the local document editing terminal.
[0018] In a possible implementation manner, after the local document editing terminal is invoked and the target document is loaded on the local document editing terminal, the method further includes:
[0019] In response to a second editing terminal switching operation, invoke the online document editing terminal and load one of the version documents of the target document on the online document editing terminal.
[0020] In a possible implementation manner, the step of in response to a second editing terminal switching operation, invoking the online document editing terminal and loading one of the version documents of the target document on the online document editing terminal includes:
[0021] In response to a second editing terminal switching operation, form the latest version document of the target document from the target document in the current offline editing state on the local document editing terminal;
[0022] Invoke the online document editing terminal and load the latest version document of the target document on the online document editing terminal.
[0023] In a possible implementation manner, in response to a first editing end switching operation, invoking a local document editing end and loading a target document in the latest collaborative editing state on the local document editing end includes:
[0024] In response to the first editing end switching operation, switching the target document in the collaborative state to the local document editing end for local editing; the editing operation of the target document in the collaborative state does not affect the target document in the local editing state.
[0025] In a possible implementation manner, after switching the target document in the collaborative state to the local document editing end for local editing in response to the first editing end switching operation, it further includes:
[0026] In response to the operation of switching the target document in the local editing state to the target document in the collaborative state, detecting whether there is a version conflict;
[0027] In the case of a version conflict, in response to the selection operation of the target document in the collaborative state, invoking the online document editing end to load the target document in the collaborative state; or, in response to the continued editing operation of the target document in the local editing state, taking the target document in the local editing state as a new version of the target document and invoking the online document editing end to load the new version of the target document;
[0028] In the case of no version conflict, invoking the online document editing end to load the target document in the local editing state as the target document in the collaborative state.
[0029] In a possible implementation manner, the method further includes:
[0030] In the case of a version conflict, in response to the processing operation of the target document in the local editing state, backing up the target document in the local editing state as a local version of the target document;
[0031] In response to the open operation of the local version of the target document, opening the local version of the target document on the local document editing end.
[0032] In a second aspect, the present application provides a document collaboration device, and the device includes:
[0033] A first end switching module, configured to, when performing online collaboration on a target document on an online document editing end, in response to a first editing end switching operation, invoke a local document editing end and load a target document in the latest collaborative editing state on the local document editing end.
[0034] In a possible implementation, the first end switching module includes:
[0035] A copy generation unit, configured to generate a document copy of the target document in the current collaborative editing state in response to a first editing end switching operation;
[0036] A client invocation unit, configured to invoke a local document editing end and load the document copy on the local document editing end.
[0037] In a possible implementation, the first end switching module includes:
[0038] A permission acquisition unit, configured to acquire the collaboration permission of a target collaborator for the target document in response to a first editing end switching operation, where the target collaborator is a collaborator logged in on the online document editing end;
[0039] A client invocation unit, configured to invoke the local document editing end when it is determined that the target collaborator has the collaboration permission to edit the target document using the local document editing end.
[0040] In a possible implementation, the device further includes:
[0041] A permission application module, configured to send a permission opening request to the collaboration initiator of the target document when it is determined that the target collaborator does not have the collaboration permission to edit the target document using the local document editing end;
[0042] The first end switching module is further configured to invoke the local document editing end when it is determined that the collaboration initiator opens the collaboration permission for the target collaborator to edit the target document using the local document editing end based on the permission opening request.
[0043] In a possible implementation, the device further includes:
[0044] A synchronization module, configured to synchronize the browsing process and user operation information of the target document on the online document editing end on the local document editing end when the local document editing end is invoked.
[0045] In a possible implementation, the device further includes:
[0046] A second end switching module, configured to, after invoking the local document editing end and loading the target document on the local document editing end, in response to a second editing end switching operation, invoke the online document editing end and load one of the version documents of the target document on the online document editing end.
[0047] In a possible implementation, the second end switching module includes:
[0048] A version update unit, configured to, in response to a second editing end switching operation, form a latest version document of the target document from the target document in the current offline editing state on the local document editing end;
[0049] An online document editing end invocation unit, configured to invoke the online document editing end and load the latest version document of the target document on the online document editing end.
[0050] In a possible implementation, the first end switching module is specifically configured to:
[0051] In response to a first editing end switching operation, switch the target document in the collaborative state to the local document editing end for local editing; the editing operation of the target document in the collaborative state does not affect the target document in the local editing state.
[0052] In a possible implementation, the device further includes:
[0053] A conflict detection module, configured to, after switching the target document in the collaborative state to the local document editing end for local editing in response to the first editing end switching operation, detect whether there is a version conflict in response to the operation of switching the target document in the local editing state to the target document in the collaborative state;
[0054] A first conflict handling module, configured to, in the case of a version conflict, in response to a selection operation on the target document in the collaborative state, invoke the online document editing end to load the target document in the collaborative state; or, in response to a continued editing operation on the target document in the local editing state, use the target document in the local editing state as a new version target document and invoke the online document editing end to load the new version target document;
[0055] A loading module, configured to, in the case of no version conflict, invoke the online document editing end to load the target document in the local editing state as the target document in the collaborative state.
[0056] In a possible implementation, the device further includes:
[0057] A second conflict handling module, configured to, in the case of a version conflict, in response to a processing operation on the target document in the local editing state, back up the target document in the local editing state as a local version target document; in response to an open operation on the local version target document, open the local version target document on the local document editing end.
[0058] In a third aspect, the present application provides an electronic device, including: a processor and a memory, where the processor is configured to execute a document collaboration program stored in the memory to implement the document collaboration method according to any one of the first aspect.
[0059] In a fourth aspect, the present application provides a storage medium storing one or more programs, where the one or more programs can be executed by one or more processors to implement the document collaboration method according to any one of the first aspect.
[0060] The above technical solutions provided by the embodiments of the present application have the following advantages compared with the prior art: In the method provided by the embodiments of the present application, when performing online collaboration on a target document on an online document editing end, in response to a first editing end switching operation, a local document editing end is invoked, and the target document in the latest collaborative editing state is loaded on the local document editing end. It can be realized that when switching from the online document editing end to the local document editing end to edit the target document, it is not necessary to stop the online collaboration on the target document. This not only meets the user's need to edit the target document using the local document editing end, but also does not interrupt other collaborators from continuing to access the target document, thus not affecting the online collaboration experience of other collaborators. Moreover, during the process of any collaborator collaborating on the target document, the method provided by the embodiments of the present application can be applied to realize editing the target document using the local document editing end, thereby meeting the needs of any collaborator and greatly improving the document collaboration experience of any collaborator. Furthermore, by loading the target document in the latest collaborative editing state on the local document editing end, it realizes continuing the online collaborative editing state of the target document on the local document editing end, which can meet the user's need to continue editing the target document based on the latest collaborative editing state and improves the user experience. BRIEF DESCRIPTION OF THE DRAWINGS
[0061] The accompanying drawings herein are incorporated into the specification and constitute a part of this specification, showing embodiments consistent with the present application and used together with the specification to explain the principles of the present application.
[0062] In order to more clearly illustrate the technical solutions in the embodiments of the present application or the prior art, the following will briefly introduce the accompanying drawings required for describing the embodiments or the prior art. Obviously, for those of ordinary skill in the art, other drawings can be obtained based on these drawings without creative efforts.
[0063] One or more embodiments are exemplarily illustrated by the pictures in the corresponding drawings. These exemplary illustrations do not constitute a limitation on the embodiments. Elements with the same reference numerals in the drawings represent similar elements. Unless otherwise stated, the drawings in the figures do not constitute a scale limitation.
[0064] Figure 1 FIG.
[0065] Figure 2 FIG.
[0066] Figure 3 FIG.
[0067] Figure 4 FIG.
[0068] Figure 5 Schematic diagram for enabling online collaboration for a target document on a local document editing terminal.
[0069] Figure 6 Schematic diagram for enabling online collaboration for a target document on an online document editing terminal.
[0070] Figure 7 Schematic diagram for setting collaborators and collaboration permissions in an online collaboration mode.
[0071] Figure 8 FIG.
[0072] Figure 9 Block diagram of an embodiment of a document collaboration device provided by an embodiment of the present application.
[0073] Figure 10 Schematic structural diagram of an electronic device provided by an embodiment of the present application. Detailed implementation manners
[0074] To make the objectives, technical solutions, and advantages of the embodiments of the present application clearer, the technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the accompanying drawings in the embodiments of the present application. Obviously, the described embodiments are some, but not all, of the embodiments of the present application. All other embodiments obtained by those of ordinary skill in the art based on the embodiments of the present application without creative efforts shall fall within the scope of protection of the present application.
[0075] The following disclosure provides many different embodiments or examples for implementing different structures of the present application. To simplify the disclosure of the present application, components and settings of specific examples are described below. Of course, they are only examples and are not intended to limit the present application. In addition, the present application may repeat reference numerals and / or letters in different examples. This repetition is for the purpose of simplicity and clarity, and does not itself indicate the relationship between various embodiments and / or settings discussed.
[0076] In order to solve the technical problem in the prior art that in the process of collaborating on a document, if a user wants to use a local client to edit the document, the online collaboration on the document needs to be stopped, which causes other collaborators to be unable to continue accessing the document and greatly affects the document collaboration experience of other collaborators, the present application provides a document collaboration method to enable any collaborator to use a local document editing terminal to edit the target document during the collaboration on the target document without interrupting other collaborators from continuing to access the target document, thereby meeting the needs of any collaborator and greatly improving the document collaboration experience of any collaborator.
[0077] Figure 1 FIG. is a flowchart of an embodiment of a document collaboration method provided by an embodiment of the present application. As Figure 1 shown, the method includes the following steps:
[0078] Step 101, in the case of online collaboration on a target document on an online document editing terminal, in response to a first editing terminal switching operation, invoke the local document editing terminal and load the target document in the latest collaborative editing state on the local document editing terminal.
[0079] First, it should be noted that the execution subject of the embodiment of the present application may be a document application, which includes an online document editing terminal and a local document editing terminal. Among them, the online document editing terminal may be a Web browser, which can display and edit document content through a browser window. The local document editing terminal refers to software installed in an electronic device and having document editing functions. Here, the online document editing terminal and the local document editing terminal may be integrated in the same application program; or, the online document editing terminal and the local document editing terminal may also be two different software installed on the same device; or, the online document editing terminal and the local document editing terminal may also be two different software installed on two different devices. When the user switches the terminal, based on the two software associated with the account on the two devices, the user can select the device to be used to open the switched document.
[0080] As can be seen from the description of step 101, in the case of online collaboration on a target document on an online document editing terminal, that is, when the target document is in an online collaboration mode, if any collaborator of the target document (the collaborators mentioned here include the creator of the target document) wants to use a local document editing terminal to edit the target document, there is no need to stop the online collaboration on the target document. Instead, a first editing terminal switching operation can be directly triggered on this end. This enables the document application to, in response to this first editing terminal switching operation, launch the local document editing terminal and load the target document in the latest collaborative editing state on the local document editing terminal, so as to switch the target document in the collaborative state to the local document editing terminal for local editing. At this time, any of the above-mentioned collaborators can edit the target document on the local document editing terminal, and other collaborators can continue with the online collaboration on the target document on their respective online document editing terminals. Moreover, the editing operations on the target document in the collaborative state do not affect the target document in the local editing state.
[0081] It should be noted here that in the case of online collaboration on a target document on an online document editing terminal, when switching from the online document editing terminal to the local document editing terminal, the target document loaded on the local document editing terminal is in the latest collaborative editing state.
[0082] For example, the original target document is AAAA. After the creator of the target document starts online collaboration on the target document, one of the collaborators modifies the target document to AAAABC. Then, when any collaborator switches from the online document editing terminal to the local document editing terminal, the target document loaded on the local document editing terminal is AAAABC.
[0083] For another example, the original target document is AAAA. After the creator of the target document starts online collaboration on the target document, one of the collaborators and the creator of the target document successively modify the target document to AAAABC and AAAABCD. Then, when any collaborator switches from the online document editing terminal to the local document editing terminal, the target document loaded on the local document editing terminal is AAAABCD.
[0084] Thus, it can be seen that in the case of online collaboration on a target document on an online document editing terminal, when switching from the online document editing terminal to the local document editing terminal, it is also possible to continue the online collaboration editing state of the target document on the local document editing terminal.
[0085] Here, one more point needs to be supplemented. In the above example, only the addition of content to the target document is taken as an example. In actual applications, in the case of online collaboration on the target document, editing operations such as content deletion, content modification, content format modification, and content comments (such as annotations) can also be performed on the target document. The embodiments of the present application do not limit the specific operation types.
[0086] As for the specific implementation of the above first editor switching operation, and the specific implementation of loading the target document in the latest collaborative editing state on the local document editor, detailed explanations will be given in the following embodiments through examples, and will not be elaborated here first.
[0087] The method provided by the embodiments of the present application, in the case of online collaboration on the target document through an online document editor, in response to the first editor switching operation, invokes the local document editor and loads the target document in the latest collaborative editing state on the local document editor, so that when switching from the online document editor to the local document editor to edit the target document, it is not necessary to stop the online collaboration on the target document. This not only meets the user's need to edit the target document using the local document editor, but also does not interrupt other collaborators from continuing to access the target document, thus not affecting the online collaboration experience of other collaborators. And during the process of any collaborator collaborating on the target document, the method provided by the embodiments of the present application can be applied to realize editing the target document using the local document editor, thereby meeting the needs of any collaborator and greatly improving the document collaboration experience of any collaborator. Furthermore, by loading the target document in the latest collaborative editing state on the local document editor, the online collaborative editing state of the target document is continued on the local document editor, which can meet the user's need to continue editing the target document based on the latest collaborative editing state and improve the user experience.
[0088] Figure 2 It is a flowchart of the implementation of another document collaboration method provided by the embodiments of the present application.
[0089] This Figure 2 The process shown Figure 1 On the basis of the process shown above, includes the following steps:
[0090] Step 201, in response to the first editor switching operation, generate a document copy of the target document in the current collaborative editing state.
[0091] Step 202, invoke the local document editor and load the document copy on the local document editor.
[0092] As can be seen from the descriptions of steps 201 and 202, in the case of online collaboration on a target document on an online document editing terminal, in response to a first editing terminal switching operation for indicating switching to a local document editing terminal, by generating a document copy of the target document in the current collaborative editing state and loading the document copy on the local document editing terminal, the target document in the latest collaborative editing state can be loaded on the local document editing terminal. This can achieve that when the target document is switched from the online document editing terminal to the local document editing terminal, the online collaborative editing state of the target document can be continued on the local document editing terminal.
[0093] In addition, in one embodiment, when the target document is switched from the online document editing terminal to the local document editing terminal, that is, when the local document editing terminal is invoked, the browsing process and user operation information of the target document on the online document editing terminal are synchronized on the local document editing terminal.
[0094] For example, user A collaboratively edits document 1 on the online document editing terminal. During this process, when user A browses to page 3 of document 1, user A triggers the switching of document 1 from the online document editing terminal to the local document editing terminal for editing. At this time, the local document editing terminal will be invoked, document 1 will be loaded on the local document editing terminal, and document 1 will be adjusted to page 3 thereof on the local document editing terminal, so as to synchronize the browsing process of the target document on the online document editing terminal on the local document editing terminal.
[0095] For another example, user A collaboratively edits document 1 on the online document editing terminal. During this process, when user A browses to page 3 of document 1 and performs a selection operation on content B on page 3, user A triggers the switching of document 1 from the online document editing terminal to the local document editing terminal for editing. At this time, the local document editing terminal will be invoked, document 1 will be loaded on the local document editing terminal, and document 1 will be adjusted to page 3 thereof on the local document editing terminal, and content B on page 3 will be selected on the local document editing terminal, so as to synchronize the browsing process and user operation information of the target document on the online document editing terminal on the local document editing terminal.
[0096] Through the above embodiments, it can be achieved that when the target document is switched from the online document editing terminal to the local document editing terminal, the online collaborative browsing process and user operations of the target document can be continued on the local document editing terminal, so as to achieve seamless continuation of the target document during terminal switching and not interrupt the user's editing experience of the target document.
[0097] Figure 3 It is a flowchart of the implementation of another document collaboration method provided by the embodiments of this application.
[0098] This Figure 3The process shown above Figure 1 is based on the process shown above and includes the following steps:
[0099] Step 301: In response to a first editor switching operation, obtain the collaboration permission of the target collaborator for the target document, where the target collaborator is a collaborator logged in to the online document editor; if it is determined that the target collaborator has the collaboration permission to edit the target document using the local document editor, execute Step 302; if it is determined that the target collaborator does not have the collaboration permission to edit the target document using the local document editor, execute Step 303.
[0100] Step 302: Invoke the local document editor and load the target document in the latest collaborative editing state on the local document editor; end the process.
[0101] From the descriptions of Step 301 and Step 302, it can be seen that in the case of online collaboration on the target document on the online document editor, if the target collaborator triggers a first editor switching operation for the target document, it does not directly switch to the local document editor. Instead, it first determines whether the target collaborator has the collaboration permission to edit the target document using the local document editor. If it is determined that the target collaborator has the collaboration permission to edit the target document using the local document editor, the local document editor can be invoked and the target document in the latest collaborative editing state can be loaded on the local document editor to achieve switching to the local document editor for editing the target document. Through this kind of processing, the security of the target document can be effectively guaranteed and risks can be avoided.
[0102] Among them, in the case where the above-mentioned target collaborator is the creator of the target document, the target collaborator usually has the collaboration permission to edit the target document using the local document editor. In the case where the above-mentioned target collaborator is not the creator of the target document, when the creator enables online collaboration for the target document, the creator can set the collaboration permission for the target collaborator.
[0103] Step 303: Send a permission opening request to the collaboration initiator of the target document.
[0104] Step 304: If it is determined that the collaboration initiator opens the collaboration permission for the target collaborator to edit the target document using the local document editor based on the permission opening request, invoke the local document editor and load the target document in the latest collaborative editing state on the local document editor.
[0105] As can be seen from the descriptions of steps 303 and 304, when it is determined that the target collaborator does not have the collaboration permission to edit the target document using the local document editor, it does not directly reject the target collaborator from invoking the local document editor. Instead, a permission application mechanism is provided, enabling the target collaborator to immediately send a permission opening request to the collaboration initiator of the target document, so that the collaboration initiator of the target document can decide whether to grant the target collaborator the collaboration permission to edit the target document using the local document editor.
[0106] Here, the collaboration initiator of the target document can be the creator of the target document or not. In the case where the collaboration initiator is not the creator of the target document, as an optional implementation, the target collaborator can also send a permission opening request to the creator of the target document, so that the creator of the target document can decide whether to grant the target collaborator the collaboration permission to edit the target document using the local document editor. As another optional implementation, the target collaborator can send a permission opening request to both the creator of the target document and the collaboration initiator, so that either the creator of the target document or the collaboration initiator can decide whether to grant the target collaborator the collaboration permission to edit the target document using the local document editor. Here, if either the creator of the target document or the collaboration initiator decides to grant the target collaborator the collaboration permission to edit the target document using the local document editor, then the collaboration permission to edit the target document using the local document editor is granted to the target collaborator.
[0107] After that, when it is determined that the collaboration initiator grants the target collaborator the collaboration permission to edit the target document using the local document editor based on the permission opening request, the local document editor can be invoked, and the target document in the latest collaborative editing state can be loaded on the local document editor. Through this kind of processing, it is possible to avoid affecting the normal editing of the target document by the target collaborator and improve the experience of the target collaborator.
[0108] Step 302: Invoke the local document editor and load the target document in the latest collaborative editing state on the local document editor; end the process.
[0109] Figure 3 In the shown process, when the target collaborator triggers the first editor switching operation for the target document, first judge the collaboration permission of the target collaborator, and perform corresponding processing according to the judgment result. On the one hand, it can effectively ensure the security of the target document and avoid risks. On the other hand, it can avoid affecting the normal editing of the target document by the target collaborator and improve the experience of the target collaborator.
[0110] Figure 4This is a flowchart of another embodiment of the document collaboration method provided by the embodiments of the present application. Figure 4 The process shown is based on the processes shown above Figure 1 , Figure 2 and Figure 3 to explain the technical solution provided by the embodiments of the present application as a whole. As Figure 4 shown, it includes the following steps:
[0111] Step 401, in response to a collaboration request for a target document, initiate online collaboration on the target document.
[0112] First, it should be noted that there are two cases in this step 401. One is to initiate online collaboration on a local document on the local document editing side, and the other is to initiate online collaboration on an online document on the online document editing side. The following will explain these two cases separately.
[0113] First, an explanation will be made for the case of initiating online collaboration on a local document on the local document editing side:
[0114] Generally speaking, in response to a collaboration request for a target document on the local document editing side, the online document editing side is launched, and the target document is loaded on the online document editing side to switch to the online collaboration mode for the target document.
[0115] Specifically, referring to Figure 5 , it is a schematic diagram of initiating online collaboration on a target document on the local document editing side. As Figure 5 shown, the target document is opened on the local document editing side. When the user wants to initiate online collaboration on the target document, the collaboration icon in the toolbar on the local document editing side can be set to the open state. The local document editing side detects that the collaboration icon is set to the open state and determines that a collaboration request for the target document has been detected.
[0116] Furthermore, in response to a collaboration request for a target document, the local document editing side uploads the target document to the cloud. After the upload to the cloud is successful, the local document editing side launches the online document editing side and loads the target document on the online document editing side to switch to the online collaboration mode for the target document.
[0117] Secondly, an explanation will be made for the case of initiating online collaboration on an online document on the online document editing side:
[0118] Generally speaking, in response to a collaboration request for a target document on the online document editing side, the online collaboration mode for the target document is initiated.
[0119] Specifically, referring to Figure 6 , it is a schematic diagram of initiating online collaboration on a target document on the online document editing side. AsFigure 6 As shown, when opening the target document on the online document editing terminal, when the user wants to initiate online collaboration for the target document, the collaboration icon in the toolbar on the online document editing terminal can be set to the open state. The online document editing terminal detects that the collaboration icon is set to the open state and determines that it has detected a response to the collaboration request for the target document. At this time, the online document editing terminal responds to the online collaboration request for the target document and enables the online collaboration mode for the target document.
[0120] Based on the above two situations, refer to Figure 7 , which is a schematic diagram of setting collaborators and collaboration permissions in the online collaboration mode. As Figure 7 can be seen, the collaboration initiator can set a designated person as a collaborator and set collaboration permissions for the collaborator. The collaboration permissions include but are not limited to: viewing permission, editing permission, advanced permissions (such as download permission, printing permission, copying permission, watermark permission, etc.). Here, the collaboration permissions can also include the permission to edit using the local document editing terminal ( Figure 7 is not shown in the figure). Among them, when the collaboration initiator sets a designated person as a collaborator, the collaborator can be specified by sending a collaboration link, that is, the party that receives the collaboration link is the designated collaborator.
[0121] Step 402: In the case of performing online collaboration on the target document on the online document editing terminal, in response to the first editor switching operation, obtain the collaboration permissions of the target collaborator for the target document. If it is determined that the target collaborator has the collaboration permission to edit the target document using the local document editing terminal, perform step 403; if it is determined that the target collaborator does not have the collaboration permission to edit the target document using the local document editing terminal, perform step 404.
[0122] Step 403: Invoke the local document editing terminal and load the target document in the latest collaborative editing state on the local document editing terminal; perform step 405.
[0123] Step 404: Send a permission opening request to the collaboration initiator of the target document. If it is determined that the collaboration initiator opens the collaboration permission for the target collaborator to edit the target document using the local document editing terminal based on the permission opening request, invoke the local document editing terminal.
[0124] For the detailed description of steps 402 to 404, refer to the explanatory notes in the above Figure 3 illustrated embodiments and will not be elaborated here.
[0125] Step 405: In response to the second editor switching operation, invoke the online document editing terminal and load one of the version documents of the target document on the online document editing terminal; return to perform step 402.
[0126] As can be seen from the description of step 405, the technical solution provided by the embodiments of the present application also supports switching back from the local document editing end to the online document editing end to perform collaborative editing on the target document. Here, when switching back from the local document editing end to the online document editing end to perform collaborative editing on the target document, one version document of the target document can be loaded on the online document editing end.
[0127] Among them, in one embodiment, in the case of switching back from the local document editing end to the online document editing end, the target document in the current offline editing state on the local document editing end is formed into the latest version document of the target document, and then the online document editing end is invoked, and the latest version document of the target document is loaded on the online document editing end. At this time, the target collaborator and other collaborators will continue to collaborate on this latest version document.
[0128] It should be noted here that in practical applications, it is not limited to loading the latest version document of the target document on the online document editing end. It can also be other version documents of the target document. For example, the version can be specified by the target collaborator, and the embodiments of the present application do not limit this.
[0129] To enable those skilled in the art to better understand the technical solution provided by the embodiments of the present application, the following further exemplifies an application scenario to assist in explaining the technical solution provided by the embodiments of the present application:
[0130] In an application scenario of one embodiment, user A creates document 1 (the document content at this time is AAA), enables online collaboration for document 1, and sets user B and user C as collaborators of document 1. Among them, user B has the viewing permission for document 1, and user C has the editing permission for document 1 and the permission to use the local document editing end for editing.
[0131] After that, assuming that during the online collaboration for document 1, user A and user B successively modify document 1 to AAAABC and AAAABCD, and assuming that user A triggers a first editing end switching operation on his / her end, then, on user A's end, the local document editing end will be invoked, and the latest collaboratively edited state of document 1, which is AAAABCD, will be loaded on the local document editing end. So far, user A can edit document 1:AAAABCD on the local document editing end, while user B can continue to view document 1:AAAABCD online, and user C can also continue to edit document 1:AAAABCD online.
[0132] After that, assume that user C modifies Document 1 to AAAABCDE online and saves the version, while user A modifies Document 1 to AAAABCDF on the text editing client without saving the version. At this time, when user A triggers the second editing client switching operation on their end, on user A's end, the online document editing client will be launched, and the latest version of Document 1, which is AAAABCDE, will be loaded on the online document editing client. Thus, user A and user C can continue to edit Document 1: AAAABCDE online, and user B can also continue to view Document 1: AAAABCDE online.
[0133] After that, assume that user B triggers the first editing client switching operation on their end. At this time, since user B does not have the permission to edit Document 1 using the local document editing client, user B can send a permission application request to user A. When user A grants user B the collaborative permission to edit Document 1 using the local document editing client based on this permission opening request, the local document editing client will be launched on user B's end.
[0134] Assume that user C triggers the first editing client switching operation on their end. Since user C has the permission to edit Document 1 using the local document editing client, on user C's end, the local document editing client will be launched, and the latest version of Document 1 in the collaborative editing state, which is AAAABCDE, will be loaded on the local document editing client. Thus, user C can edit Document 1: AAAABCDE on the local document editing client, while user B can continue to view Document 1: AAAABCDE online, and user A can also continue to edit Document 1: AAAABCDE online.
[0135] Through Figure 4 the process shown and the application scenarios of the above examples, it can be seen that the technical solution provided by the embodiments of this application can achieve that when switching from the online document editing client to the local document editing client to edit the target document, there is no need to stop the online collaboration for the target document. This not only meets the user's need to edit the target document using the local document editing client but also does not interrupt other collaborators from continuing to access the target document, thus not affecting the online collaboration experience of other collaborators for the target document. Moreover, during the collaboration process of any collaborator for the target document, this method provided by the embodiments of this application can be applied to achieve editing the target document using the local document editing client, thereby meeting the needs of any collaborator and greatly enhancing the document collaboration experience of any collaborator. Furthermore, by loading the target document in the latest collaborative editing state on the local document editing client, the online collaborative editing state of the target document is continued on the local document editing client, which can meet the user's need to continue editing the target document based on the latest collaborative editing state and improve the user experience.
[0136] Figure 8 This is a flowchart of an embodiment of another document collaboration method provided by an embodiment of the present application. Figure 8 Based on the above process, the process shown includes the following steps:
[0137] Step 801, in response to a collaboration request for a target document, initiate online collaboration on the target document.
[0138] Step 802, when performing online collaboration on the target document on an online document editing terminal, in response to a first editing terminal switching operation, invoke the local document editing terminal to switch the target document in the collaborative state to the local document editing terminal for local editing.
[0139] For a detailed description of Step 801 and Step 802, reference can be made to the relevant explanations in the above embodiments, which will not be elaborated here.
[0140] Step 803, in response to an operation of switching the target document in the local editing state to the target document in the collaborative state, detect whether there is a version conflict; in the case of a version conflict, execute Step 804, and in the case of no version conflict, execute Step 805.
[0141] Step 804, in response to a selection operation on the target document in the collaborative state, invoke the online document editing terminal to load the target document in the collaborative state; or, in response to a continued editing operation on the target document in the local editing state, use the target document in the local editing state as the new version of the target document, and invoke the online document editing terminal to load the new version of the target document.
[0142] Step 805, invoke the online document editing terminal to load the target document in the local editing state as the target document in the collaborative state.
[0143] For the convenience of description, the following provides a unified description of Steps 803 to 805:
[0144] In one embodiment, when local editing is performed on the target document on the local document editing terminal and an operation of switching the target document in the local editing state to the target document in the collaborative state is triggered, version conflict detection will be triggered. Here, the purpose of version conflict detection is to detect whether the target document to be saved on the local document editing terminal is consistent with the target document in the current collaborative state. If they are consistent, it is determined that there is no version conflict; if they are inconsistent, it is determined that there is a version conflict.
[0145] Among them, in the case of no version conflict, the online document editing terminal can be directly invoked to load the target document in the local editing state as the target document in the collaborative state.
[0146] For example, user A initiates collaboration on a target document and designates user B and user C as collaborators for the target document. In this example, assume that during the online collaboration on the target document by user A, user B, and user C, user A switches the target document from the online collaboration state to the local editing state and makes an editing operation on the target content in the local editing state. During this process, neither user B nor user C makes an editing operation on the target document in the online collaboration state. Then, when user A triggers the operation of switching the target document in the local editing state to the target document in the collaboration state, version conflict detection will be triggered, and the conflict detection result at this time is that there is no version conflict. Further, since there is no version conflict, the online document editing terminal can be directly called to load the target document in the local editing state that has been edited by user A as the target document in the collaboration state.
[0147] In the case of a version conflict, in one embodiment, two conflict handling strategies are provided for the user to choose from. These two conflict handling strategies are: continue editing the local version, load the cloud version. Among them, continuing to edit the local version means continuing to edit the target document in the local editing state. Therefore, when the user selects the conflict handling strategy of continuing to edit the local version, it means that the user triggers the operation of continuing to edit the target document in the local editing state. At this time, in response to this continue editing operation, the target document in the local editing state is used as the new target document, and the online document editing terminal is called to load this new target document.
[0148] Loading the cloud version means continuing to edit the target document in the collaboration state. Therefore, when the user selects the conflict handling strategy of loading the cloud version, it means that the user triggers the selection operation of the target document in the collaboration state. At this time, in response to this selection operation, the online document editing terminal is called to load the target document in the collaboration state.
[0149] For example, assume that during the online collaboration on document 1 (AAAA), user A triggers a first editing terminal switching operation on their end. Then, on user A's end, the local document editing terminal will be launched, and document 1 in the latest collaborative editing state will be loaded on the local document editing terminal, assumed to be AAAA. Continuing to assume that user A makes an editing operation on document 1 on the local document editing terminal, and the target document in the local editing state is assumed to be AAAAB. Also assume that during this period, user B also makes an editing operation on document 1 on the online document editing terminal, and document 1 in the collaboration state is assumed to be AAAABCD. According to the above description, when user A triggers the operation of switching the target document in the local editing state to the target document in the collaboration state, version conflict detection will be triggered, and the conflict detection result at this time is that there is a version conflict.
[0150] After that, when user A triggers a continue editing operation on document 1 in the local editing state, on one end of user A, document 1 in the local editing state is used as the new version of document 1, that is, AAAAB, and the online document editing end is called to load this new version of document 1. At this time, what user B sees online will also be this new version of document 1.
[0151] When user A triggers a selection operation on document 1 in the collaborative state, on one end of user A, the online document editing end is called to load document 1 in the collaborative state, that is, AAAABCD.
[0152] In addition, in one embodiment, in the case of a version conflict, there is also a third conflict handling strategy: backup the local version and open it. Specifically, backing up the local version and opening it means backing up the target document in the local editing state as the target document of the local version, and opening the target document of the local version on the local document editing end.
[0153] Based on this, when the user selects the strategy of backing up the local version and opening it, it means that the user triggers a processing operation on the target document in the local editing state. At this time, in response to this processing operation, the target document in the local editing state is backed up as the target document of the local version, and then in response to the opening operation of the target document of the local version, the target document of the local version is opened on the local document editing end.
[0154] Through this embodiment, it is possible to save the target document edited by the user locally and automatically open the target document on the local document editing end, so that the user can continue to edit the target document on the local editing end.
[0155] It should be added here that the conflict handling strategy of backing up the local version and opening it does not conflict with the other two conflict handling strategies, that is, the user can simultaneously select the conflict handling strategy of backing up the local version and opening it and one of the other two conflict handling strategies, which can achieve opening the local document editing end and the online document editing end simultaneously, and meet the user's local editing needs and online collaborative editing needs at the same time.
[0156] Figure 8 In the shown process, by detecting whether there is a version conflict when switching the target document in the local editing state to the target document in the collaborative state, and in the case of a version conflict, the user selects the document version to be retained according to their actual needs, so as to meet the user's editing needs and improve the user experience.
[0157] Figure 9 This is a block diagram of an embodiment of a document collaboration device provided by an embodiment of the present application. As Figure 9 shown, the device includes:
[0158] The first-end switching module 91 is configured to, when online collaboration is performed on a target document on an online document editing end, in response to a first editing-end switching operation, invoke a local document editing end and load the target document in the latest collaborative editing state on the local document editing end.
[0159] In a possible implementation manner, the first-end switching module 91 includes:
[0160] A copy generation unit, configured to generate a document copy of the target document in the current collaborative editing state in response to a first editing-end switching operation;
[0161] A client invocation unit, configured to invoke a local document editing end and load the document copy on the local document editing end.
[0162] In a possible implementation manner, the first-end switching module 91 includes:
[0163] A permission acquisition unit, configured to acquire the collaboration permission of a target collaborator for the target document in response to a first editing-end switching operation, where the target collaborator is a collaborator logged in on the online document editing end;
[0164] A client invocation unit, configured to invoke the local document editing end when it is determined that the target collaborator has the collaboration permission to edit the target document using the local document editing end.
[0165] In a possible implementation manner, the device further includes:
[0166] A permission application module, configured to send a permission opening request to the collaboration initiator of the target document when it is determined that the target collaborator does not have the collaboration permission to edit the target document using the local document editing end;
[0167] The first-end switching module is further configured to invoke the local document editing end when it is determined that the collaboration initiator opens the collaboration permission for the target collaborator to edit the target document using the local document editing end based on the permission opening request.
[0168] In a possible implementation manner, the device further includes:
[0169] A synchronization module, configured to synchronize the browsing process and user operation information of the target document on the online document editing end on the local document editing end when the local document editing end is invoked.
[0170] In a possible implementation manner, the device further includes:
[0171] A second - end switching module, configured to, after invoking the local document editing end and loading a target document on the local document editing end, in response to a second editing - end switching operation, invoke the online document editing end and load one of the version documents of the target document on the online document editing end.
[0172] In a possible implementation manner, the second - end switching module includes:
[0173] A version update unit, configured to, in response to a second editing - end switching operation, form the latest version document of the target document from the target document in the current offline editing state on the local document editing end;
[0174] An online document editing - end invoking unit, configured to invoke the online document editing end and load the latest version document of the target document on the online document editing end.
[0175] In a possible implementation manner, the first - end switching module is specifically configured to:
[0176] In response to a first editing - end switching operation, switch the target document in the collaborative state to the local document editing end for local editing; the editing operation of the target document in the collaborative state does not affect the target document in the local editing state.
[0177] In a possible implementation manner, the device further includes:
[0178] A conflict detection module, configured to, after switching the target document in the collaborative state to the local document editing end for local editing in response to the first editing - end switching operation, in response to the operation of switching the target document in the local editing state to the target document in the collaborative state, detect whether there is a version conflict;
[0179] A first conflict - handling module, configured to, in the case of a version conflict, in response to the selection operation of the target document in the collaborative state, invoke the online document editing end to load the target document in the collaborative state; or, in response to the continued editing operation of the target document in the local editing state, use the target document in the local editing state as a new version target document and invoke the online document editing end to load the new version target document;
[0180] A loading module, configured to, in the case of no version conflict, invoke the online document editing end to load the target document in the local editing state as the target document in the collaborative state.
[0181] In a possible implementation manner, the device further includes:
[0182] The second conflict handling module is configured to, in the case of version conflict, in response to a processing operation on the target document in the local editing state, back up the target document in the local editing state as a target document in the local version; and in response to an open operation on the target document in the local version, open the target document in the local version on the local document editing end.
[0183] As Figure 10 shown, an embodiment of the present application provides an electronic device, including a processor 111, a communication interface 112, a memory 113, and a communication bus 114. Among them, the processor 111, the communication interface 112, and the memory 113 complete mutual communication through the communication bus 114.
[0184] The memory 113 is used to store a computer program.
[0185] In an embodiment of the present application, when the processor 111 executes the program stored on the memory 113, it implements the document collaboration method provided in any one of the foregoing method embodiments, including:
[0186] In the case of online collaboration on a target document on an online document editing end, in response to a first editing end switching operation, the local document editing end is invoked, and the target document in the latest collaborative editing state is loaded on the local document editing end.
[0187] An embodiment of the present application also provides a computer-readable storage medium, on which a computer program is stored. When the computer program is executed by a processor, it implements the steps of the document collaboration method provided in any one of the foregoing method embodiments.
[0188] The device embodiments described above are merely illustrative. The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place, or may be distributed to multiple network units. Some or all of the modules can be selected according to actual needs to achieve the purpose of the solution of this embodiment.
[0189] Through the description of the above embodiments, those skilled in the art can clearly understand that each embodiment can be implemented by means of software plus a general hardware platform, and of course, it can also be implemented by hardware. Based on such an understanding, the essence of the above technical solution, or the part that contributes to the related technology, can be embodied in the form of a software product. The computer software product can be stored in a computer-readable storage medium, such as ROM / RAM, magnetic disk, optical disk, etc., including several instructions for causing a computer device (which can be a personal computer, a server, or a network device, etc.) to execute the methods described in each embodiment or some parts of the embodiments.
[0190] It should be understood that the terms used herein are for the purpose of describing particular example embodiments only and are not intended to be limiting. Unless the context clearly dictates otherwise, the singular forms "a", "an", and "the" as used herein may also include the plural forms. The terms "comprising", "including", "containing", and "having" are inclusive and thus specify the presence of the stated features, steps, operations, elements, and / or components, but do not preclude the presence or addition of one or more other features, steps, operations, elements, components, and / or combinations thereof. The method steps, processes, and operations described herein are not to be construed as necessarily requiring their performance in the particular order described or illustrated, unless an execution order is explicitly stated. It should also be understood that additional or alternative steps may be used.
[0191] The foregoing are only specific embodiments of the present application, which enable those skilled in the art to understand or implement the present application. Various modifications to these embodiments will be readily apparent to those skilled in the art, and the general principles defined herein may be implemented in other embodiments without departing from the spirit or scope of the present application. Therefore, the present application will not be limited to the embodiments shown herein, but rather is to be accorded the widest scope consistent with the principles and novel features claimed herein.
Claims
1. A document collaboration method, characterized in that, The method includes: When performing online collaboration on a target document at an online document editing end, in response to a first editing end switching operation, invoking a local document editing end and loading the target document in the latest collaborative editing state on the local document editing end.
2. The method according to claim 1, characterized in that, The step of, in response to a first editing end switching operation, invoking a local document editing end and loading the target document in the latest collaborative editing state on the local document editing end includes: In response to a first editing end switching operation, generating a document copy of the target document in the current collaborative editing state; Invoking a local document editing end and loading the document copy on the local document editing end.
3. The method according to claim 1, characterized in that, The step of, in response to a first editing end switching operation, invoking a local document editing end includes: In response to a first editing end switching operation, obtaining the collaboration permission of a target collaborator for the target document, where the target collaborator is a collaborator logged in on the online document editing end; Invoking the local document editing end when it is determined that the target collaborator has the collaboration permission to edit the target document using the local document editing end.
4. The method according to claim 3, characterized in that, The method further includes: When it is determined that the target collaborator does not have the collaboration permission to edit the target document using the local document editing end, sending a permission opening request to the collaboration initiator of the target document; Invoking the local document editing end when it is determined that the collaboration initiator has opened the collaboration permission for the target collaborator to edit the target document using the local document editing end based on the permission opening request.
5. The method according to claim 1, characterized in that, The method further includes: When the local document editing end is invoked, synchronizing the browsing process and user operation information of the target document on the online document editing end on the local document editing end.
6. The method according to claim 1, characterized in that, After invoking the local document editing end and loading the target document on the local document editing end, the method further includes: In response to a second editing end switching operation, invoking the online document editing end and loading one of the version documents of the target document on the online document editing end.
7. The method according to claim 6, characterized in that, The step of, in response to a second editing end switching operation, invoking the online document editing end and loading one of the version documents of the target document on the online document editing end includes: In response to a second editing end switching operation, forming the latest version document of the target document from the target document in the current offline editing state on the local document editing end; Invoking the online document editing end and loading the latest version document of the target document on the online document editing end.
8. The method according to claim 1, characterized in that, The step of, in response to a first editing end switching operation, invoking a local document editing end and loading the target document in the latest collaborative editing state on the local document editing end includes: In response to a first editing end switching operation, switching the target document in the collaborative state to the local document editing end for local editing; the editing operations on the target document in the collaborative state do not affect the target document in the local editing state.
9. The method according to claim 8, characterized in that, After performing local editing on the local document editing end to which the target document in the collaborative state is switched in response to the first editing end switching operation, it further includes: In response to the operation of switching the target document in the local editing state to the target document in the collaborative state, detecting whether there is a version conflict; In the case of a version conflict, in response to the selection operation on the target document in the collaborative state, invoking the online document editing end to load the target document in the collaborative state; or, in response to the continued editing operation on the target document in the local editing state, taking the target document in the local editing state as the new version of the target document and invoking the online document editing end to load the new version of the target document; In the case of no version conflict, invoking the online document editing end to load the target document in the local editing state as the target document in the collaborative state.
10. The method according to claim 9, characterized in that, The method further includes: In the case of a version conflict, in response to the processing operation on the target document in the local editing state, backing up the target document in the local editing state as the target document in the local version; In response to the open operation on the target document in the local version, opening the target document in the local version on the local document editing end.
11. A document collaboration device, characterized in that, The device includes: A first end switching module, configured to, in the case of online collaboration on a target document on an online document editing end, in response to a first editing end switching operation, invoke the local document editing end and load the target document in the latest collaborative editing state on the local document editing end.
12. An electronic device, characterized in that,It includes: A processor and a memory, where the processor is configured to execute the document collaboration program stored in the memory to implement the document collaboration method according to any one of claims 1 to 10.
13. A storage medium, characterized in that, The storage medium stores one or more programs, and the one or more programs can be executed by one or more processors to implement the document collaboration method according to any one of claims 1 to 10.