Rollback ignore unlinked answers

This commit is contained in:
2026-05-06 05:22:44 +01:00
parent c679182707
commit 123e9d3338

View File

@@ -1238,9 +1238,9 @@ def get_all_questionnaires_by_patient(patient_id, record_data):
# patient_id, the questionnaire is considered unlinked → clear answers
# to prevent use of orphaned data.
# (disable: comment out the block below)
answers_patient = answers.get("subject") if isinstance(answers, dict) else None
if not answers_patient or answers_patient != patient_id:
answers = {}
#answers_patient = answers.get("subject") if isinstance(answers, dict) else None
#if not answers_patient or answers_patient != patient_id:
# answers = {}
# ────────────────────────────────────────────────────────────────────────
if q_id: