TheJacksonLaboratory / PhenopacketLab

An Angular/Springboot web application for the loading, editing, saving of data that follows the Phenopacket Schema
BSD 3-Clause "New" or "Revised" License
7 stars 1 forks source link

Problem with adding interpretations #206

Closed BethSundberg closed 1 year ago

BethSundberg commented 1 year ago

I want to add two interpretations to the disease heart disorder. I put the first one in and clicked Save interpretation. I added the second row, but when I clicked Save interpretation it told me there already exists an interpretation with the name "new interpretation 10".

---The problem is that I don't need to do a Save at this point, it automatically adds my second row. Only I thought that did not happen because of the message.--------- So I changed the interpretation name to "new interpretation 12". Then I clicked save interpretation again.

Now I have two identical interpretations that look like this:

Image

Here is how they look if I open up the accordion. The json also has both sets in it.

Image

Image

It makes sense to me that there can be multiple genomic interpretations for one disease, i.e. several rows.

Does it also make sense to be able to add multiple genomic interpretations for a second disease diagnosis? If yes, then I think the error message needs to convey somehow that I don't need to do a save again for disease diagnosis 1. Also it should clear everything if I decide to add a disease diagnosis 2.

BethSundberg commented 1 year ago

@belkassaby @ielis In thinking more about this, I believe you need an "update" option. Once a "Save Interpretation" has been done for an interpretation ID the user may need to make changes or additions to it. If you can select by the interpretation ID that would avoid the duplication that occurred for me in this example. The selection option should be at the bottom(?) where the list of "Created Interpretations" is shown. Or, perhaps the list of created interpretations should be at the top? I did not even notice that list at first. Any new interpretation ID the user creates should clear out the form so they start fresh (unless they did not save the current interpretation ID - that should be a warning so they don't accidentally lose work).

ielis commented 1 year ago

Hi @BethSundberg @belkassaby, Beth, thanks for pointing this out.

It makes sense to me that there can be multiple genomic interpretations for one disease, i.e. several rows.

Yes, we must be able to add >1 interpretations.

Does it also make sense to be able to add multiple genomic interpretations for a second disease diagnosis? ...

Yes, each interpretation must support >1 genomic interpretations. Also, I also find it confusing having the list of the created interpretations at the bottom of the UI. This is one of things that definitely need to be updated when we do our UI enhancement run.

... Or, perhaps the list of created interpretations should be at the top?

Yes, I think it should be at the top.

Any new interpretation ID the user creates should clear out the form so they start fresh (unless they did not save the current interpretation ID - that should be a warning so they don't accidentally lose work).

Regarding the saving current data. @belkassaby do we need a separate button for that? Also, I think it would be nice to be able to work on multiple interpretations at once, including incremental validation (e.g. to point out using the same IDs for separate entities, or submitting the identical information twice). @belkassaby do you think this can be done or is it too complicated to implement for now?

belkassaby commented 1 year ago

What about putting the list of created interpretations on the side (the same as for the diseases and phenotypic features, and selecting an interpretation, the user can then edit it by changing the form accordingly?

BethSundberg commented 1 year ago

@belkassaby I think that is a good idea

ielis commented 1 year ago

In principle, I think it's OK, as long as we keep the workflow similar to the diseases and phenotypic features, hence no Save interpretation button.

However, it would be great to also get input from UI/UX people.

BethSundberg commented 1 year ago

I think this is much easier to use now!!