SORMAS-Foundation / SORMAS-Project

SORMAS (Surveillance, Outbreak Response Management and Analysis System) is an early warning and management system to fight the spread of infectious diseases.
https://sormas.org
GNU General Public License v3.0
292 stars 140 forks source link

Remove wrong info "creating a new sample will discard all unsaved changes made to this case" [0.5] #7350

Closed MartinWahnschaffe closed 6 months ago

MartinWahnschaffe commented 2 years ago

Feature Description

The main view of a case currently displays this info below the sample list. grafik

Problem Description

When creating a new sample here, the system will automatically open the created sample, but before it does so, the system checks for unsaved changes made to the case and asks the user whether to save, discard or cancel. Thus the info is no longer correct and needed.

Proposed Change

@kwa20 Please double check whether I'm missing something here.

kwa20 commented 2 years ago

@MartinWahnschaffe Good idea, I agree that the info message is obsolete and removing it also makes the right column look nicer. I just tried it and a problem I encountered is similar to what is described here https://github.com/hzi-braunschweig/SORMAS-Project/issues/6746.

The unsaved changes problem gets triggered but saving does not work. This seems to only happen in cases but works for contacts and event participants

sampleCreationUnsavedChanges

I think we should make sure that the unsaved changes prompt gets triggered correctly. It might also be confusing that it appears after the sample has been saved. I think we should go with the following flow:

  1. User enters data on the (case) form without saving
  2. User clicks on "New Sample"
  3. Unsaved changes prompt appears 4.1 When user presses 'save', data gets saved and the sample creation form opened 4.2 When user presses 'discard', data does not get saved and the sample creation form opens 4.3 When user presses 'cancel navigation', the pop-up closes but nothing gets changed
kwa20 commented 2 years ago

https://github.com/hzi-braunschweig/SORMAS-Project/issues/7350#issuecomment-976902813 This issue might already be addressed in PR #7441 and is mentioned in https://github.com/hzi-braunschweig/SORMAS-Project/issues/7425#issuecomment-986089010

AndyBakcsy-she commented 2 years ago

The issue with the unsaved changes prompt that gets triggered after the sample is created has been fixed on the last 1.66.1 branch.

adinaflorea9 commented 6 months ago

Verified ticket on the local machine using the latest version of SORMAS from the development branch - 1.95.0-SBAPSHOT(0799a1f).