Skip to content

Pending json patch operations should be canceled when leaving the submission page #1217

@alemarte

Description

@alemarte

Describe the bug
JSON patch operations are queued inside the json/patch feature of the ngrx store.
When the user leaves the submission page without saving, this pending json patch operations are not removed and could be commited on behalf of the user during possible following submissions.

To Reproduce

  1. Start a new submission (ex. Publication)
  2. Edit the author field (dc.contributor.author metadata). (new store state is shown below)
    deletependingpatchscreenshot
  3. Navigate to a different page (ex. My Dspace)
  4. Start a new submission of the same kind
  5. Edit the title field (dc.title) (new store state is shown below)
    deletependingpatchscreenshot2
  6. Save
  7. The previous author value has been committed too.

Expected behavior
A submission shouldn't be affected by previous user's submission interactions.

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions