Skip to content

Preload values should only be set during first load #642

@garethbowen

Description

@garethbowen

Expected Behaviour

If a form has a preload attribute this gets executed and set during first load. However when editing the submission the value should not get set again.

Observed Behaviour

Editing updates the preload bindings.

Reproduction Steps

Form (XML or XLSX file):

form.xml

Steps:

  1. Load the form above. Note the start date is set to now.
  2. Submit the form.
  3. Edit the form. The start date should be unchanged, but actually gets updated to now.

Additional Context

There is a special case to be aware of, which is instanceID and deprecatedID. These should be updated on edit to track the updates. These are hardcoded attributes which currently go through the same code as the configured preloads so it's important to verify that any changes don't regress those.

Metadata

Metadata

Assignees

Labels

xforms-engineTasks for Web Forms xforms-engine package

Type

Projects

Status

Done

Relationships

None yet

Development

No branches or pull requests

Issue actions