Please check if the PR fulfills these requirements
[ ] Tests for the changes have been added (for bug fixes / features)
[ ] Docs have been added / updated (for bug fixes / features)
What kind of change does this PR introduce? (Bug fix, feature, docs update, ...)
Fix saving functionality of remaining fields in PatientViewCard where possible.
What is the current behavior? (You can also link to an open issue here)
Some fields can not be saved due to backend validations, missing input options or some other small errors such as "0" is sent when backend expects integer.
Breakthrough of the fields that can not be edited can be seen from the other information section.
What is the new behavior (if this is a feature change)?
Fields where reason was "When choosing default option, "0" is sent and backend expects 0" can not be updated correctly.
Laskutustiedot section (Katuosoite, postinumero, kaupunki, kunta, maa) can be changed, but not directly updated. No way to update a single attribute, all of them must be changed in order to save. There's something happening in the backend which prevets _update patch command, so _create must be used instead.
There are still few fields that can not be updated but that is not fixable in our end, at least currently. Fields that can not be edited are listed in the other information section
Does this PR introduce a breaking change? (What changes might users need to make in their application due to this PR?)
No
Add screenshot if possible. (Add screenshot of the change)
Other information:
Form section
Field
Error
Fixed
General patient info
Kuva
No options to choose from, no way to upload a new image
[ ]
Henkilötunnus
Backend prevents update of this field. Validation for patient failed. The legal SSN cannot be cleared or changed via the REST interface. The change must be made using the AssisDent client.
[ ]
Sukupuoli
When choosing default option, "0" is sent and backend expects 0
[ x ]
Sisäinen tunniste
Can not be edited in windows client either
[ ]
Asiakastiedot
Kutsulupa
When choosing default option, "0" is sent and backend expects 0
[ x ]
Toivotut yhteydenottotavat
No options to choose from
[ ]
Ajanvarausten muistutusviestit
When choosing default option, "0" is sent and backend expects 0
[ x ]
Potilaskohtaiset muistutukset
No options to choose from
[ ]
Laskutustiedot
Katuosoite, postinumero, kaupunki, kunta, maa
This is a entity which has a composition association to the patient, it can not be updated due to some backend logic.
[partially]
Alennus
No options to choose from
[ ]
Etukortin tyyppi
Can not be changed to K-plussa kortti, backend prevents change
[ ]
Etukortin numero
Can not be updated if etukortin tyyppi is "K-plussa kortti", backend prevents change
[ ]
Kelakorvaus
When choosing default option, "0" is sent and backend expects 0
[ x ]
Luvat ja suostumukset
Terveystietojen jako organisaation sisällä
When choosing default option, "0" is sent and backend expects 0
[ x ]
Asiakkuus
When choosing default option, "0" is sent and backend expects 0
Please check if the PR fulfills these requirements
[ ] Tests for the changes have been added (for bug fixes / features)
[ ] Docs have been added / updated (for bug fixes / features)
What kind of change does this PR introduce? (Bug fix, feature, docs update, ...)
What is the current behavior? (You can also link to an open issue here)
What is the new behavior (if this is a feature change)?
_update
patch command, so_create
must be used instead.Does this PR introduce a breaking change? (What changes might users need to make in their application due to this PR?)
Add screenshot if possible. (Add screenshot of the change)
Other information:
closes #51