hpi-sam / digital-fuesim-manv

A German simulation system for training emergency medical services leadership personnel on how to manage Mass Casualty Incidents.
https://fuesim-manv.de/
GNU Affero General Public License v3.0
16 stars 8 forks source link

Feature/1022 add identity to patients #1028

Closed lukasrad02 closed 1 year ago

lukasrad02 commented 1 year ago

PR Checklist

Please make sure to fulfill the following conditions before marking this PR ready for review:

lukasrad02 commented 1 year ago

It might be useful to add the identifier to the HospitalPatient, too, so patients can be tracked even when they're not longer on the map.

lukasrad02 commented 1 year ago
  1. It would be nice to Inform the user that once a patient is created the change in prefix does not apply to that patient.

Good idea, I've added a notice for this.

  1. It would be nice to limit the length of the prefix so that a user can not mess up the UI accidentally

I've added a warning that shows up for prefixes with a length > 3 (since I think two letters and the dash will occur frequently). I do not want to enforce a specific limit as the number of letters causing layout problems could differ from user to user (different fonts etc) and there are legitimate reasons to choose longer prefixes (e.g. realism).

  1. When using a prefix like Berlin- In the Patient Tab, the UI converts to a scrollbar even in the modal. I would suggest either making it bigger or talk to Christian whether it is acceptable to leave one of the 4 displayed information points out.

I've slightly increased the size so that prefixes with up to 3 characters (the soft limit from above) should fit into the table (with enough space left if people have a larger monospace font than me).

  1. When using this prefix again, the patient popup does weird things like displaying a white border. Maybe make the top of the popup higher or remove one of the information points.

This happens since the max-width rule was only applied to the popup content and not the header. I've tried limiting the header length and cutting off long names with an ellipsis (), but I didn't manage to get this running, since there are too many other elements in the header that should not be truncated.

What I've finally done was to remove the name from the header entirely. It is now displayed in the popup body instead. I think this should be fine since the name was only used to identify patients (which can now be done trough the identifier).