Send questionnaire after an investigation: domain model
I am working on a short demo app. Where the customer can send a questionnaire to the patient. I have a question about the domain model. - I want a patient who can participate in multiple examinations. - There are several studies that a patient can take part in - Each study has its own questions that can be asked to the patients. In addition, I have made this domain model. My question is this the most useful model. And I also have a question about how you can best view multiple questions in a questionnaire.
Seeing as the association between patient and onderzoek is a many to many, i assume multiple patients will take the same questionnaire.
With this domain model a questionnaire will always only have just 1 answer for a question. But you want multiple patients to answer on this? You will have no idea which patient answered that question. Also, should a patient be able to change his answer? And if so, do you want to keep an audit trail?
You're going to have to detail your domain model a bit. Best to think about possible scenarios and functionality you'd need for them.