tricc-oo 1.5.13__tar.gz → 1.5.15__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {tricc_oo-1.5.13 → tricc_oo-1.5.15}/PKG-INFO +1 -1
- {tricc_oo-1.5.13 → tricc_oo-1.5.15}/README.md +0 -0
- {tricc_oo-1.5.13 → tricc_oo-1.5.15}/pyproject.toml +1 -1
- {tricc_oo-1.5.13 → tricc_oo-1.5.15}/setup.cfg +0 -0
- {tricc_oo-1.5.13 → tricc_oo-1.5.15}/tests/build.py +0 -0
- {tricc_oo-1.5.13 → tricc_oo-1.5.15}/tests/test_cql.py +0 -0
- {tricc_oo-1.5.13 → tricc_oo-1.5.15}/tests/to_ocl.py +0 -0
- {tricc_oo-1.5.13 → tricc_oo-1.5.15}/tricc_oo/__init__.py +0 -0
- {tricc_oo-1.5.13 → tricc_oo-1.5.15}/tricc_oo/converters/__init__.py +0 -0
- {tricc_oo-1.5.13 → tricc_oo-1.5.15}/tricc_oo/converters/codesystem_to_ocl.py +0 -0
- {tricc_oo-1.5.13 → tricc_oo-1.5.15}/tricc_oo/converters/cql/cqlLexer.py +0 -0
- {tricc_oo-1.5.13 → tricc_oo-1.5.15}/tricc_oo/converters/cql/cqlListener.py +0 -0
- {tricc_oo-1.5.13 → tricc_oo-1.5.15}/tricc_oo/converters/cql/cqlParser.py +0 -0
- {tricc_oo-1.5.13 → tricc_oo-1.5.15}/tricc_oo/converters/cql/cqlVisitor.py +0 -0
- {tricc_oo-1.5.13 → tricc_oo-1.5.15}/tricc_oo/converters/cql_to_operation.py +1 -3
- {tricc_oo-1.5.13 → tricc_oo-1.5.15}/tricc_oo/converters/datadictionnary.py +0 -0
- {tricc_oo-1.5.13 → tricc_oo-1.5.15}/tricc_oo/converters/drawio_type_map.py +13 -13
- {tricc_oo-1.5.13 → tricc_oo-1.5.15}/tricc_oo/converters/tricc_to_xls_form.py +0 -0
- {tricc_oo-1.5.13 → tricc_oo-1.5.15}/tricc_oo/converters/utils.py +0 -0
- {tricc_oo-1.5.13 → tricc_oo-1.5.15}/tricc_oo/converters/xml_to_tricc.py +4 -0
- {tricc_oo-1.5.13 → tricc_oo-1.5.15}/tricc_oo/models/__init__.py +0 -0
- {tricc_oo-1.5.13 → tricc_oo-1.5.15}/tricc_oo/models/base.py +0 -0
- {tricc_oo-1.5.13 → tricc_oo-1.5.15}/tricc_oo/models/calculate.py +4 -3
- {tricc_oo-1.5.13 → tricc_oo-1.5.15}/tricc_oo/models/lang.py +0 -0
- {tricc_oo-1.5.13 → tricc_oo-1.5.15}/tricc_oo/models/ocl.py +0 -0
- {tricc_oo-1.5.13 → tricc_oo-1.5.15}/tricc_oo/models/ordered_set.py +0 -0
- {tricc_oo-1.5.13 → tricc_oo-1.5.15}/tricc_oo/models/tricc.py +2 -0
- {tricc_oo-1.5.13 → tricc_oo-1.5.15}/tricc_oo/parsers/__init__.py +0 -0
- {tricc_oo-1.5.13 → tricc_oo-1.5.15}/tricc_oo/parsers/xml.py +0 -0
- {tricc_oo-1.5.13 → tricc_oo-1.5.15}/tricc_oo/serializers/__init__.py +0 -0
- {tricc_oo-1.5.13 → tricc_oo-1.5.15}/tricc_oo/serializers/planuml.py +0 -0
- {tricc_oo-1.5.13 → tricc_oo-1.5.15}/tricc_oo/serializers/xls_form.py +3 -0
- {tricc_oo-1.5.13 → tricc_oo-1.5.15}/tricc_oo/strategies/__init__.py +0 -0
- {tricc_oo-1.5.13 → tricc_oo-1.5.15}/tricc_oo/strategies/input/__init__.py +0 -0
- {tricc_oo-1.5.13 → tricc_oo-1.5.15}/tricc_oo/strategies/input/base_input_strategy.py +0 -0
- {tricc_oo-1.5.13 → tricc_oo-1.5.15}/tricc_oo/strategies/input/drawio.py +0 -0
- {tricc_oo-1.5.13 → tricc_oo-1.5.15}/tricc_oo/strategies/output/base_output_strategy.py +0 -0
- {tricc_oo-1.5.13 → tricc_oo-1.5.15}/tricc_oo/strategies/output/spice.py +0 -0
- {tricc_oo-1.5.13 → tricc_oo-1.5.15}/tricc_oo/strategies/output/xls_form.py +0 -0
- {tricc_oo-1.5.13 → tricc_oo-1.5.15}/tricc_oo/strategies/output/xlsform_cdss.py +4 -0
- {tricc_oo-1.5.13 → tricc_oo-1.5.15}/tricc_oo/strategies/output/xlsform_cht.py +24 -0
- {tricc_oo-1.5.13 → tricc_oo-1.5.15}/tricc_oo/strategies/output/xlsform_cht_hf.py +0 -0
- {tricc_oo-1.5.13 → tricc_oo-1.5.15}/tricc_oo/visitors/__init__.py +0 -0
- {tricc_oo-1.5.13 → tricc_oo-1.5.15}/tricc_oo/visitors/tricc.py +17 -1
- {tricc_oo-1.5.13 → tricc_oo-1.5.15}/tricc_oo/visitors/utils.py +0 -0
- {tricc_oo-1.5.13 → tricc_oo-1.5.15}/tricc_oo/visitors/xform_pd.py +0 -0
- {tricc_oo-1.5.13 → tricc_oo-1.5.15}/tricc_oo.egg-info/PKG-INFO +1 -1
- {tricc_oo-1.5.13 → tricc_oo-1.5.15}/tricc_oo.egg-info/SOURCES.txt +0 -0
- {tricc_oo-1.5.13 → tricc_oo-1.5.15}/tricc_oo.egg-info/dependency_links.txt +0 -0
- {tricc_oo-1.5.13 → tricc_oo-1.5.15}/tricc_oo.egg-info/requires.txt +0 -0
- {tricc_oo-1.5.13 → tricc_oo-1.5.15}/tricc_oo.egg-info/top_level.txt +0 -2
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
@@ -305,9 +305,7 @@ class cqlToXlsFormVisitor(cqlVisitor):
|
|
|
305
305
|
def visitUnionExpression(self, ctx):
|
|
306
306
|
raise NotImplementedError('union not supported')
|
|
307
307
|
|
|
308
|
-
|
|
309
|
-
# TODO
|
|
310
|
-
raise NotImplementedError('Implies not supported')
|
|
308
|
+
|
|
311
309
|
|
|
312
310
|
def visitQuantity(self, ctx):
|
|
313
311
|
# TODO
|
|
File without changes
|
|
@@ -44,7 +44,7 @@ TYPE_MAP = {
|
|
|
44
44
|
"constraint",
|
|
45
45
|
"constraint_message",
|
|
46
46
|
"relevance",
|
|
47
|
-
"priority"
|
|
47
|
+
"priority", "trigger", "default"
|
|
48
48
|
|
|
49
49
|
],
|
|
50
50
|
"mandatory_attributes": ["label", "name", "list_name"],
|
|
@@ -60,7 +60,7 @@ TYPE_MAP = {
|
|
|
60
60
|
"constraint",
|
|
61
61
|
"constraint_message",
|
|
62
62
|
"relevance",
|
|
63
|
-
"priority"
|
|
63
|
+
"priority", "trigger", "default"
|
|
64
64
|
],
|
|
65
65
|
"mandatory_attributes": ["label", "name", "list_name"],
|
|
66
66
|
"model": TriccNodeSelectMultiple
|
|
@@ -75,7 +75,7 @@ TYPE_MAP = {
|
|
|
75
75
|
"constraint_message",
|
|
76
76
|
"required",
|
|
77
77
|
"relevance",
|
|
78
|
-
"priority"
|
|
78
|
+
"priority", "trigger", "default"
|
|
79
79
|
],
|
|
80
80
|
"mandatory_attributes": ["label", "name"],
|
|
81
81
|
"model": TriccNodeDecimal
|
|
@@ -90,7 +90,7 @@ TYPE_MAP = {
|
|
|
90
90
|
"constraint_message",
|
|
91
91
|
"required",
|
|
92
92
|
"relevance",
|
|
93
|
-
"priority"
|
|
93
|
+
"priority", "trigger", "default"
|
|
94
94
|
|
|
95
95
|
],
|
|
96
96
|
"mandatory_attributes": ["label", "name"],
|
|
@@ -99,43 +99,43 @@ TYPE_MAP = {
|
|
|
99
99
|
|
|
100
100
|
TriccNodeType.text: {
|
|
101
101
|
"objects": ["UserObject", "object"],
|
|
102
|
-
"attributes": ["save", "relevance","priority"],
|
|
102
|
+
"attributes": ["save", "relevance","priority", "trigger", "default"],
|
|
103
103
|
"mandatory_attributes": ["label", 'name'],
|
|
104
104
|
"model": TriccNodeText
|
|
105
105
|
},
|
|
106
106
|
TriccNodeType.date: {
|
|
107
107
|
"objects": ["UserObject", "object"],
|
|
108
|
-
"attributes": ["save", "relevance","priority"],
|
|
108
|
+
"attributes": ["save", "relevance","priority", "trigger", "default"],
|
|
109
109
|
"mandatory_attributes": ["label", "name"],
|
|
110
110
|
"model": TriccNodeDate
|
|
111
111
|
},
|
|
112
112
|
TriccNodeType.add: {
|
|
113
113
|
"objects": ["UserObject", "object"],
|
|
114
|
-
"attributes": ["save", "expression"],
|
|
114
|
+
"attributes": ["save", "expression", "trigger"],
|
|
115
115
|
"mandatory_attributes": ['label', "name"],
|
|
116
116
|
"model": TriccNodeAdd
|
|
117
117
|
},
|
|
118
118
|
TriccNodeType.count: {
|
|
119
119
|
"objects": ["UserObject", "object"],
|
|
120
|
-
"attributes": ["save", "expression"],
|
|
120
|
+
"attributes": ["save", "expression", "trigger"],
|
|
121
121
|
"mandatory_attributes": ['label', "name"],
|
|
122
122
|
"model": TriccNodeCount
|
|
123
123
|
},
|
|
124
124
|
TriccNodeType.calculate: {
|
|
125
125
|
"objects": ["UserObject", "object"],
|
|
126
|
-
"attributes": ["save", "reference"],
|
|
126
|
+
"attributes": ["save", "reference", "trigger"],
|
|
127
127
|
"mandatory_attributes": [ "name", 'label'],
|
|
128
128
|
"model": TriccNodeCalculate
|
|
129
129
|
},
|
|
130
130
|
TriccNodeType.rhombus: {
|
|
131
131
|
"objects": ["UserObject", "object"],
|
|
132
|
-
"attributes": ["save", "expression", 'label','priority'],
|
|
132
|
+
"attributes": ["save", "expression", 'label','priority', "trigger"],
|
|
133
133
|
"mandatory_attributes": ["reference"],
|
|
134
134
|
"model": TriccNodeRhombus
|
|
135
135
|
},
|
|
136
136
|
TriccNodeType.wait: {
|
|
137
137
|
"objects": ["UserObject", "object"],
|
|
138
|
-
"attributes": ["save", "expression"],
|
|
138
|
+
"attributes": ["save", "expression", "trigger"],
|
|
139
139
|
"mandatory_attributes": ["reference", "name", 'label'],
|
|
140
140
|
"model": TriccNodeWait
|
|
141
141
|
},
|
|
@@ -159,7 +159,7 @@ TYPE_MAP = {
|
|
|
159
159
|
"filter",
|
|
160
160
|
"constraint",
|
|
161
161
|
"constraint_message",
|
|
162
|
-
"relevance","priority"
|
|
162
|
+
"relevance","priority", "trigger", "default"
|
|
163
163
|
],
|
|
164
164
|
"mandatory_attributes": ["label", "name", "list_name"],
|
|
165
165
|
"model": TriccNodeSelectYesNo
|
|
@@ -208,7 +208,7 @@ TYPE_MAP = {
|
|
|
208
208
|
},
|
|
209
209
|
TriccNodeType.proposed_diagnosis: {
|
|
210
210
|
"objects": ["UserObject", "object"],
|
|
211
|
-
"attributes": ["save", "reference", "severity", "priority"],
|
|
211
|
+
"attributes": ["save", "reference", "severity", "priority", "trigger"],
|
|
212
212
|
"mandatory_attributes": [ "name", 'label'],
|
|
213
213
|
"model": TriccNodeProposedDiagnosis
|
|
214
214
|
},
|
|
File without changes
|
|
File without changes
|
|
@@ -644,10 +644,14 @@ def add_tricc_base_node(
|
|
|
644
644
|
|
|
645
645
|
|
|
646
646
|
def load_expressions(node):
|
|
647
|
+
if getattr(node, 'constraint', None):
|
|
648
|
+
node.constraint = parse_expression('', node.constraint)
|
|
647
649
|
if getattr(node, 'expression', None):
|
|
648
650
|
node.expression = parse_expression('', node.expression)
|
|
649
651
|
if getattr(node, 'relevance', None):
|
|
650
652
|
node.relevance = parse_expression('', node.relevance)
|
|
653
|
+
if getattr(node, 'trigger', None):
|
|
654
|
+
node.trigger = parse_expression('', node.trigger)
|
|
651
655
|
if getattr(node, 'default', None):
|
|
652
656
|
node.default = parse_expression('', node.default)
|
|
653
657
|
if getattr(node, 'reference', None):
|
|
File without changes
|
|
File without changes
|
|
@@ -20,7 +20,8 @@ class TriccNodeDisplayCalculateBase(TriccNodeCalculateBase):
|
|
|
20
20
|
save: Optional[str] = None # contribute to another calculate
|
|
21
21
|
hint: Optional[str] = None # for diagnostic display
|
|
22
22
|
help: Optional[str] = None # for diagnostic display
|
|
23
|
-
|
|
23
|
+
trigger: Optional[Union[Expression, TriccOperation, TriccReference]] = None
|
|
24
|
+
applicability: Optional[Union[Expression, TriccOperation, TriccReference]] = None
|
|
24
25
|
# no need to copy save
|
|
25
26
|
def to_fake(self):
|
|
26
27
|
data = vars(self)
|
|
@@ -75,10 +76,10 @@ class TriccRhombusMixIn():
|
|
|
75
76
|
reference = []
|
|
76
77
|
expression_reference = None
|
|
77
78
|
instance.path = None
|
|
78
|
-
if isinstance(self.expression_reference, (str, TriccOperation)):
|
|
79
|
+
if isinstance(self.expression_reference, (str, TriccOperation, TriccReference, TriccStatic)):
|
|
79
80
|
expression_reference = self.expression_reference.copy()
|
|
80
81
|
reference = list(expression_reference.get_references())
|
|
81
|
-
if isinstance(self.reference, (str, TriccOperation)):
|
|
82
|
+
if isinstance(self.reference, (str, TriccOperation, TriccReference, TriccStatic)):
|
|
82
83
|
expression_reference = self.reference.copy()
|
|
83
84
|
reference = list(expression_reference.get_references())
|
|
84
85
|
elif isinstance(self.reference, list):
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
@@ -237,6 +237,8 @@ class TriccNodeDisplayModel(TriccNodeBaseModel):
|
|
|
237
237
|
help: Optional[Union[str, TriccNodeBaseModel]] = None
|
|
238
238
|
group: Optional[Union[TriccGroup, TriccNodeActivity]] = None
|
|
239
239
|
relevance: Optional[Union[Expression, TriccOperation]] = None
|
|
240
|
+
default: Optional[Union[Expression, TriccOperation, TriccReference, TriccStatic]] = None
|
|
241
|
+
trigger: Optional[Union[Expression, TriccOperation, TriccReference]] = None
|
|
240
242
|
priority: Union[float, int, None] = None
|
|
241
243
|
|
|
242
244
|
# to use the enum value of the TriccNodeType
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
@@ -231,6 +231,7 @@ SURVEY_MAP = {
|
|
|
231
231
|
**langs.get_trads_map("required_message"),
|
|
232
232
|
"read only": "read only",
|
|
233
233
|
"calculation": "expression",
|
|
234
|
+
"trigger": "trigger",
|
|
234
235
|
"repeat_count": "repeat_count",
|
|
235
236
|
"media::image": "image",
|
|
236
237
|
"choice_filter": "",
|
|
@@ -602,6 +603,7 @@ def get_input_line(node, replace_dots=True):
|
|
|
602
603
|
"", #'required'
|
|
603
604
|
*list(empty.values()), #'required message'
|
|
604
605
|
"", #'read only'
|
|
606
|
+
"",
|
|
605
607
|
"", #'expression'
|
|
606
608
|
"", #'repeat_count'
|
|
607
609
|
"", #'image'
|
|
@@ -629,6 +631,7 @@ def get_input_calc_line(node, replace_dots=True):
|
|
|
629
631
|
"", #'read only'
|
|
630
632
|
"../inputs/contact/"
|
|
631
633
|
+ clean_name(node.name, replace_dots=replace_dots), #'expression'
|
|
634
|
+
"",
|
|
632
635
|
"", #'repeat_count'
|
|
633
636
|
"", #'image'
|
|
634
637
|
"", # choice filter
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
@@ -70,6 +70,7 @@ class XLSFormCDSSStrategy(XLSFormStrategy):
|
|
|
70
70
|
*list(empty.values()) ,#'required message'
|
|
71
71
|
'',#'read only'
|
|
72
72
|
'',#'expression'
|
|
73
|
+
"",
|
|
73
74
|
'',#'repeat_count'
|
|
74
75
|
'',#'image'
|
|
75
76
|
''
|
|
@@ -90,6 +91,7 @@ class XLSFormCDSSStrategy(XLSFormStrategy):
|
|
|
90
91
|
*list(empty.values()) ,#'required message'
|
|
91
92
|
'',#'read only'
|
|
92
93
|
'',#'expression'
|
|
94
|
+
"",
|
|
93
95
|
'',#'repeat_count'
|
|
94
96
|
'',#'image'
|
|
95
97
|
''
|
|
@@ -110,6 +112,7 @@ class XLSFormCDSSStrategy(XLSFormStrategy):
|
|
|
110
112
|
*list(empty.values()) ,#'required message'
|
|
111
113
|
'',#'read only'
|
|
112
114
|
'',#'expression'
|
|
115
|
+
"",
|
|
113
116
|
'',#'repeat_count'
|
|
114
117
|
'',#'image'
|
|
115
118
|
''
|
|
@@ -133,6 +136,7 @@ class XLSFormCDSSStrategy(XLSFormStrategy):
|
|
|
133
136
|
'1',#'required'
|
|
134
137
|
*list(empty.values()) ,#'required message'
|
|
135
138
|
'',#'read only'
|
|
139
|
+
"",
|
|
136
140
|
'',#'expression'
|
|
137
141
|
'',#'repeat_count'
|
|
138
142
|
'',#'image'
|
|
@@ -61,6 +61,7 @@ class XLSFormCHTStrategy(XLSFormCDSSStrategy):
|
|
|
61
61
|
"",
|
|
62
62
|
"",
|
|
63
63
|
"",
|
|
64
|
+
"",
|
|
64
65
|
]
|
|
65
66
|
df_input.loc[len(df_input)] = [
|
|
66
67
|
"hidden",
|
|
@@ -81,6 +82,7 @@ class XLSFormCHTStrategy(XLSFormCDSSStrategy):
|
|
|
81
82
|
"",
|
|
82
83
|
"",
|
|
83
84
|
"",
|
|
85
|
+
"",
|
|
84
86
|
]
|
|
85
87
|
df_input.loc[len(df_input)] = [
|
|
86
88
|
"hidden",
|
|
@@ -101,6 +103,7 @@ class XLSFormCHTStrategy(XLSFormCDSSStrategy):
|
|
|
101
103
|
"",
|
|
102
104
|
"",
|
|
103
105
|
"",
|
|
106
|
+
"",
|
|
104
107
|
]
|
|
105
108
|
|
|
106
109
|
df_input.loc[len(df_input)] = [
|
|
@@ -122,6 +125,7 @@ class XLSFormCHTStrategy(XLSFormCDSSStrategy):
|
|
|
122
125
|
"",
|
|
123
126
|
"",
|
|
124
127
|
"",
|
|
128
|
+
"",
|
|
125
129
|
]
|
|
126
130
|
df_input.loc[len(df_input)] = [
|
|
127
131
|
"string",
|
|
@@ -142,6 +146,7 @@ class XLSFormCHTStrategy(XLSFormCDSSStrategy):
|
|
|
142
146
|
"",
|
|
143
147
|
"",
|
|
144
148
|
"",
|
|
149
|
+
"",
|
|
145
150
|
]
|
|
146
151
|
df_input.loc[len(df_input)] = [
|
|
147
152
|
"string",
|
|
@@ -162,6 +167,7 @@ class XLSFormCHTStrategy(XLSFormCDSSStrategy):
|
|
|
162
167
|
"",
|
|
163
168
|
"",
|
|
164
169
|
"",
|
|
170
|
+
"",
|
|
165
171
|
]
|
|
166
172
|
df_input.loc[len(df_input)] = [
|
|
167
173
|
"string",
|
|
@@ -182,6 +188,7 @@ class XLSFormCHTStrategy(XLSFormCDSSStrategy):
|
|
|
182
188
|
"",
|
|
183
189
|
"",
|
|
184
190
|
"",
|
|
191
|
+
"",
|
|
185
192
|
]
|
|
186
193
|
df_input.loc[len(df_input)] = [
|
|
187
194
|
"end_group",
|
|
@@ -202,6 +209,7 @@ class XLSFormCHTStrategy(XLSFormCDSSStrategy):
|
|
|
202
209
|
"",
|
|
203
210
|
"",
|
|
204
211
|
"",
|
|
212
|
+
"",
|
|
205
213
|
]
|
|
206
214
|
df_input.loc[len(df_input)] = [
|
|
207
215
|
"begin_group",
|
|
@@ -222,6 +230,7 @@ class XLSFormCHTStrategy(XLSFormCDSSStrategy):
|
|
|
222
230
|
"",
|
|
223
231
|
"",
|
|
224
232
|
"",
|
|
233
|
+
"",
|
|
225
234
|
]
|
|
226
235
|
inputs = self.export_inputs(start_pages[self.processes[0]], **kwargs)
|
|
227
236
|
for input in inputs:
|
|
@@ -246,6 +255,7 @@ class XLSFormCHTStrategy(XLSFormCDSSStrategy):
|
|
|
246
255
|
"",
|
|
247
256
|
"",
|
|
248
257
|
"",
|
|
258
|
+
"",
|
|
249
259
|
]
|
|
250
260
|
|
|
251
261
|
df_input.loc[len(df_input)] = [
|
|
@@ -267,6 +277,7 @@ class XLSFormCHTStrategy(XLSFormCDSSStrategy):
|
|
|
267
277
|
"",
|
|
268
278
|
"",
|
|
269
279
|
"",
|
|
280
|
+
"",
|
|
270
281
|
]
|
|
271
282
|
|
|
272
283
|
df_input.loc[len(df_input)] = [
|
|
@@ -288,6 +299,7 @@ class XLSFormCHTStrategy(XLSFormCDSSStrategy):
|
|
|
288
299
|
"",
|
|
289
300
|
"",
|
|
290
301
|
"",
|
|
302
|
+
"",
|
|
291
303
|
]
|
|
292
304
|
|
|
293
305
|
df_input.loc[len(df_input)] = [
|
|
@@ -309,6 +321,7 @@ class XLSFormCHTStrategy(XLSFormCDSSStrategy):
|
|
|
309
321
|
"",
|
|
310
322
|
"",
|
|
311
323
|
"",
|
|
324
|
+
"",
|
|
312
325
|
]
|
|
313
326
|
self.get_contact_inputs_calculate(df_input)
|
|
314
327
|
df_input.loc[len(df_input)] = [
|
|
@@ -327,6 +340,7 @@ class XLSFormCHTStrategy(XLSFormCDSSStrategy):
|
|
|
327
340
|
*list(empty.values()), #'required message'
|
|
328
341
|
"", #'read only'
|
|
329
342
|
"../inputs/user/contact_id", #'expression'
|
|
343
|
+
"",
|
|
330
344
|
"", #'repeat_count'
|
|
331
345
|
"", #'image'
|
|
332
346
|
"", # choice filter
|
|
@@ -347,6 +361,7 @@ class XLSFormCHTStrategy(XLSFormCDSSStrategy):
|
|
|
347
361
|
*list(empty.values()), #'required message'
|
|
348
362
|
"", #'read only'
|
|
349
363
|
"../inputs/user/facility_id", #'expression'
|
|
364
|
+
"",
|
|
350
365
|
"", #'repeat_count'
|
|
351
366
|
"", #'image'
|
|
352
367
|
"", # choice filter
|
|
@@ -367,6 +382,7 @@ class XLSFormCHTStrategy(XLSFormCDSSStrategy):
|
|
|
367
382
|
*list(empty.values()), #'required message'
|
|
368
383
|
"", #'read only'
|
|
369
384
|
"../inputs/user/name", #'expression'
|
|
385
|
+
"",
|
|
370
386
|
"", #'repeat_count'
|
|
371
387
|
"", #'image'
|
|
372
388
|
"", # choice filter
|
|
@@ -387,6 +403,7 @@ class XLSFormCHTStrategy(XLSFormCDSSStrategy):
|
|
|
387
403
|
*list(empty.values()), #'required message'
|
|
388
404
|
"", #'read only'
|
|
389
405
|
"../inputs/contact/_id", #'expression'
|
|
406
|
+
"",
|
|
390
407
|
"", #'repeat_count'
|
|
391
408
|
"", #'image'
|
|
392
409
|
"", # choice filter
|
|
@@ -408,6 +425,7 @@ class XLSFormCHTStrategy(XLSFormCDSSStrategy):
|
|
|
408
425
|
*list(empty.values()), #'required message'
|
|
409
426
|
"", #'read only'
|
|
410
427
|
"../inputs/source_id", #'expression'
|
|
428
|
+
"",
|
|
411
429
|
"", #'repeat_count'
|
|
412
430
|
"", #'image'
|
|
413
431
|
"", # choice filter
|
|
@@ -428,6 +446,7 @@ class XLSFormCHTStrategy(XLSFormCDSSStrategy):
|
|
|
428
446
|
*list(empty.values()), #'required message'
|
|
429
447
|
"", #'read only'
|
|
430
448
|
"../inputs/user/facility_id", #'expression'
|
|
449
|
+
"",
|
|
431
450
|
"", #'repeat_count'
|
|
432
451
|
"", #'image'
|
|
433
452
|
"", # choice filter
|
|
@@ -451,6 +470,7 @@ class XLSFormCHTStrategy(XLSFormCDSSStrategy):
|
|
|
451
470
|
"",
|
|
452
471
|
"",
|
|
453
472
|
"",
|
|
473
|
+
"",
|
|
454
474
|
]
|
|
455
475
|
|
|
456
476
|
for input in inputs:
|
|
@@ -480,6 +500,7 @@ class XLSFormCHTStrategy(XLSFormCDSSStrategy):
|
|
|
480
500
|
"",
|
|
481
501
|
"",
|
|
482
502
|
"",
|
|
503
|
+
"",
|
|
483
504
|
]
|
|
484
505
|
if not len(df_input[df_input['name'] == 'date_of_birth']):
|
|
485
506
|
df_input.loc[len(df_input)] = [
|
|
@@ -501,6 +522,7 @@ class XLSFormCHTStrategy(XLSFormCDSSStrategy):
|
|
|
501
522
|
"",
|
|
502
523
|
"",
|
|
503
524
|
"",
|
|
525
|
+
"",
|
|
504
526
|
]
|
|
505
527
|
|
|
506
528
|
return df_input
|
|
@@ -527,6 +549,7 @@ class XLSFormCHTStrategy(XLSFormCDSSStrategy):
|
|
|
527
549
|
"",
|
|
528
550
|
"",
|
|
529
551
|
"",
|
|
552
|
+
"",
|
|
530
553
|
]
|
|
531
554
|
df_input.loc[len(df_input)] = [
|
|
532
555
|
"calculate",
|
|
@@ -547,6 +570,7 @@ class XLSFormCHTStrategy(XLSFormCDSSStrategy):
|
|
|
547
570
|
"",
|
|
548
571
|
"",
|
|
549
572
|
"",
|
|
573
|
+
"",
|
|
550
574
|
]
|
|
551
575
|
|
|
552
576
|
return df_input
|
|
File without changes
|
|
File without changes
|
|
@@ -591,6 +591,22 @@ def process_reference(node, processed_nodes, calculates, used_calculates=None,
|
|
|
591
591
|
return False
|
|
592
592
|
elif modified_expression and replace_reference:
|
|
593
593
|
node.relevance = modified_expression
|
|
594
|
+
|
|
595
|
+
if isinstance(getattr(node, 'trigger', None), (TriccOperation, TriccReference)):
|
|
596
|
+
modified_expression = process_operation_reference(
|
|
597
|
+
node.trigger,
|
|
598
|
+
node,
|
|
599
|
+
processed_nodes=processed_nodes,
|
|
600
|
+
calculates=calculates,
|
|
601
|
+
used_calculates=used_calculates,
|
|
602
|
+
replace_reference=replace_reference,
|
|
603
|
+
warn=warn,
|
|
604
|
+
codesystems=codesystems
|
|
605
|
+
)
|
|
606
|
+
if modified_expression is False:
|
|
607
|
+
return False
|
|
608
|
+
elif modified_expression and replace_reference:
|
|
609
|
+
node.trigger = modified_expression
|
|
594
610
|
|
|
595
611
|
if isinstance(getattr(node, 'default', None), (TriccOperation, TriccReference)):
|
|
596
612
|
modified_expression = process_operation_reference(
|
|
@@ -2101,7 +2117,7 @@ def get_rhombus_terms( node, processed_nodes, get_overall_exp=False, negate=Fals
|
|
|
2101
2117
|
node.get_name()))
|
|
2102
2118
|
exit(1)
|
|
2103
2119
|
elif node.expression_reference is not None and node.expression_reference != '':
|
|
2104
|
-
if isinstance(node.expression_reference, TriccOperation):
|
|
2120
|
+
if isinstance(node.expression_reference, (TriccOperation, TriccReference, TriccStatic)):
|
|
2105
2121
|
return node.expression_reference
|
|
2106
2122
|
elif isinstance(node.expression_reference, str):
|
|
2107
2123
|
expression = node.expression_reference.format(*get_list_names(node.reference))
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|