Skip to content

In offlineable client, draft forms don't get updates to attached Entity Lists but they should #1407

@dbemke

Description

@dbemke

ODK Collect version

all

Problem description

From forum issue https://forum.getodk.org/t/draft-form-using-entities-in-collect-doesnt-retrieve-updated-entity-lists-after-first-sync/56901

After a user downloads a draft version of an entity update form to Collect, new entities created on the server or on a different device won’t be in the dataset after syncing the draft form.

It seems that the dataset (CSV) in drafts (of an entity update form) on Central gets updated - you can see entities created on the server in the Enketo preview and in the downloaded csv.

Steps to reproduce the problem

  1. On Central create a project with an entity registration form and entity update form.
  2. Create some entities.
  3. Navigate to the entity update form and create a draft.
  4. Scan the QR code for testing drafts to Collect.
  5. Go to Central to the entity registration form, Submissions tab and click "+New Submission".
  6. Fill and send the form to create a new entity.
  7. In Collect refresh the list of forms in "Start new form".
  8. Open the entity update form and check the list of entities.

Notes about weirdness of Entities and drafts in Collect

My first thought was that it would be nice to see new entities in the draft of an update form but then I wondered how other parts of ”life” of an entity would get resolved in drafts on Central/Collect e.g.

  • a user can update an entity locally (in Collect) and send the form - in Collect you can see the "updated" values while in Central the submission can’t make any changes in the dataset – 2 different versions of the same entity
  • at the same time another user can edit the same entity in Central – there isn’t the conflict resolution part in Central drafts

Metadata

Metadata

Assignees

Labels

backendRequires a change to the API serverbehavior verifiedBehavior has been manually verified

Type

Projects

Status

✅ done

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions