Skip to content

Entities from finalized registration and update forms after resetting "saved forms and entities" #6435

Closed
@dbemke

Description

@dbemke

ODK Collect version

the master version ce00913

Android version

10, 14

Device used

Redmi 9T, Pixel 7a

Problem description

I’m not sure what should happen with entities from finalized registration and update forms after resetting "saved forms and entities" in Collect setting.
After resetting saved forms there aren’t any entities/rows in the db files. Afterwards, if a user finalizes an update to an entity (in the update form), the finalized entity doesn’t appear on the list in the update form (I guess it isn’t created locally/offline – no new rows in db files). If a user finalizes the registration form, in the update form other entities are removed form the list and there’s only the new entity (registration form creates a row in db files). So there are 2 different scenarios what appears in the update form depending on what a user finalizes after resetting saved forms.
I guess it means that after resetting saved forms local entities are enabled again only after refreshing the list of blank forms (or downloading them manually).
Is it ok for the time being or finalizing an entity form should trigger local entities (after resetting) ?

Steps to reproduce the problem

  1. Download a project with entities registration form, follow-up form and update form with some existing entities (e.g. trees registration, follow- up, update with the new entity spec user "one" in https://staging.getodk.cloud/#/projects/101/app-users).
  2. Go to Settings- Project management- Reset, select "Saved forms and entities” and tap "Reset”.
  3. Go to Settings- Form management- Auto send and set "off”.
  4. Go to the update form, select an entity an finalize the form.
  5. Go to the update form and check with version of the entity updated in step 4 is on the list (there is the version without the update + other entities are on the list).
  6. Go to the registration form and create an entity.
  7. Go to the update form and check which entities are on the list (there’s only the new entity, other entities aren’t on the list).

Expected behavior

Instead of being able to reset Saved Forms and entities, users should only be able to reset Saved Forms (like before). Additionally, forms that create/update entities (determinable via Instance#canDeleteBeforeSend) should not be reset. This makes reset and manual delete consistent - users currently can't delete forms that create/update forms.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

Status

done

Relationships

None yet

Development

No branches or pull requests

Issue actions