[schema] Add link between QuestionnaireRun and ExternalResource, e.g. for Behavioural questionnaries
authorVincent Michel <vincent.michel@logilab.fr>
Wed, 03 Jul 2013 16:03:39 +0200
changeset 154 63acf059a3fe
parent 153 d79a9d8c14f3
child 155 f2d3d2816f2d
[schema] Add link between QuestionnaireRun and ExternalResource, e.g. for Behavioural questionnaries
schema.py
--- a/schema.py	Wed Jul 03 16:00:35 2013 +0200
+++ b/schema.py	Wed Jul 03 16:03:39 2013 +0200
@@ -69,7 +69,10 @@
 GenomicMeasure.add_relation(SubjectRelation('Device', cardinality='?*', inlined=True), name='uses_device')
 
 # Measure -> ExternalResources
+# Questionnaire may have some specifications files
 Questionnaire.add_relation(SubjectRelation('ExternalResource', cardinality='*1'), name='external_resources')
+# Some questionnaire run could have specific results files (subject dependant)
+QuestionnaireRun.add_relation(SubjectRelation('ExternalResource', cardinality='*1'), name='external_resources')
 Scan.add_relation(SubjectRelation('ExternalResource', cardinality='*1'), name='external_resources')
 GenomicMeasure.add_relation(SubjectRelation('ExternalResource', cardinality='*1'), name='external_resources')