SORMAS-Project icon indicating copy to clipboard operation
SORMAS-Project copied to clipboard

Sample can not be edited, deleted or saved

Open KernB opened this issue 3 years ago • 5 comments

Bug Description

Samples cannot be edited, saved or deleted. The fields are not accessible and the buttons are inactive.

The behavior is observed in diverse automatic test since September 15th.

A further check has shown: By adding the appropriate user rights the bottons are shown. But they are inactive.

Steps to Reproduce

  1. Select or create a user who has all the rights in the Sample Testing section.
  2. Create a Case
  3. Add a "New Sample"
  4. Open this Sample and try to work with it

Expected Behavior

The fields should be editable and the buttons should be active.

Screenshots

Admin image image BeKe image image

image

System Details

  • Device: Laptop
  • SORMAS version: 1.76.0
  • Android version/Browser: Chrom and automated tests
  • Server URL: test-de and test-auto
  • User Role: Admin

Additional Information

The behavior was confirmed on test-de with the user BeKe and changed user rights.

KernB avatar Sep 19 '22 09:09 KernB

This issue was discovered last week and at first it was thought that it might have been caused by ticket #9693, that's why we didn't open a new issue for this yet.

LE: I talked to @JonasCir and the issue is probably not caused by #9693, so the new ticket is in order.

roxanamlendea avatar Sep 19 '22 10:09 roxanamlendea

Have the samples been created by the user you're using? Are they in the same jurisdiction as the user jurisdiction, if the user has a jurisdiction at all (I guess not since it's got the Admin user role)? Does the user have the user rights to see personal/sensitive data?

MateStrysewske avatar Sep 21 '22 08:09 MateStrysewske

@roxanamlendea Please recheck wether this can be closed because it's covered by https://github.com/hzi-braunschweig/SORMAS-Project/issues/9693

markusmann-vg avatar Sep 22 '22 09:09 markusmann-vg

The samples were each created with the same user. I repeated the test with my user. For this purpose he got the right "Create new sample". The behavior in still present. I did not change the case or the user between saving and editing. The Admin has the Rolls Administrator and National User. At the National Use and me individuell roll "See personal / sensitive date in jurisdiction" are active.

KernB avatar Sep 22 '22 09:09 KernB

Hey I take a look at this issue myself: https://github.com/hzi-braunschweig/SORMAS-Project/issues/9693 did not change any logic and was re-reviewed twice now, so I would suggest we keep it closed and I investigate this issue on its own.

JonasCir avatar Sep 22 '22 10:09 JonasCir

can reproduce, I'm investigating

JonasCir avatar Sep 22 '22 11:09 JonasCir

PR is up

JonasCir avatar Sep 22 '22 11:09 JonasCir

Validated on test.sormas on Version: 1.76.0-SNAPSHOT (cfb8bd9) Samples can be created/deleted/edited with any user with rights.

  • checked users with/without Sample testing rights
  • checked behavior with user having a custom user role with different configurations (checking various access restrictions).

image

dragosb-vg avatar Sep 27 '22 10:09 dragosb-vg