Skip to content

Problem with synchronisation with spreadsheet #2941

@AIlkiv

Description

@AIlkiv

Please use the 👍 reaction to show that you are affected by the same issue. Please don't comment if you have no relevant information to add!

Describe the bug

Continuation of the story #2165. I noticed that this does not always work.

To Reproduce

Steps:

  1. Open the file via richdocuments.
  2. Fill out the form.
  3. After completing the form, make changes to the open file and save.

Result: The last submission will be overwritten by the version from richdocuments.

Expected behavior

It will not allow saving in richdocuments. It will ask to download the updated version first.

Additional context

The solution I found:
In richdocuments, listen to PostWriteListener and if it is CLI, invalidate (delete) all tokens for this file.

Result: All users of the file will receive a message that they need to reload the page. They reload and get the latest version.

Disadvantage: If users had unsaved changes, they will be lost. In my opinion, this is less critical because the user will see that their connection has been lost and will understand that they need to check if all changes are there (plus richdocuments has auto-save, so the impact is minimal). Because now, when richdocuments overwrites Submission, there is no way to track it, and it causes a lot of problems.

Metadata

Metadata

Assignees

No one assigned

    Labels

    0. Needs triagePending approval or rejection. This issue is pending approval.bugSomething isn't working

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions