cql_qdm_patientapi 1.1.4 → 1.2.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (28) hide show
  1. checksums.yaml +4 -4
  2. data/Gemfile.lock +2 -2
  3. data/app/assets/javascripts/datatypes/adverseevent.js.coffee +2 -2
  4. data/app/assets/javascripts/datatypes/allergyintolerance.js.coffee +2 -2
  5. data/app/assets/javascripts/datatypes/assessment.js.coffee +9 -7
  6. data/app/assets/javascripts/datatypes/careexperience.js.coffee +1 -0
  7. data/app/assets/javascripts/datatypes/caregoal.js.coffee +1 -1
  8. data/app/assets/javascripts/datatypes/communication.js.coffee +6 -3
  9. data/app/assets/javascripts/datatypes/datatype.js.coffee +8 -2
  10. data/app/assets/javascripts/datatypes/device.js.coffee +10 -8
  11. data/app/assets/javascripts/datatypes/diagnosis.js.coffee +2 -2
  12. data/app/assets/javascripts/datatypes/diagnosticstudy.js.coffee +11 -9
  13. data/app/assets/javascripts/datatypes/encounter.js.coffee +10 -8
  14. data/app/assets/javascripts/datatypes/familyhistory.js.coffee +2 -1
  15. data/app/assets/javascripts/datatypes/immunization.js.coffee +16 -8
  16. data/app/assets/javascripts/datatypes/intervention.js.coffee +9 -7
  17. data/app/assets/javascripts/datatypes/laboratorytest.js.coffee +11 -9
  18. data/app/assets/javascripts/datatypes/medication.js.coffee +38 -22
  19. data/app/assets/javascripts/datatypes/physicalexam.js.coffee +14 -12
  20. data/app/assets/javascripts/datatypes/procedure.js.coffee +21 -19
  21. data/app/assets/javascripts/datatypes/substance.js.coffee +27 -16
  22. data/app/assets/javascripts/datatypes/symptom.js.coffee +1 -1
  23. data/app/assets/javascripts/types/component.js.coffee +2 -1
  24. data/app/assets/javascripts/types/id.js.coffee +1 -1
  25. data/app/assets/javascripts/utils/helpers.js.coffee +9 -5
  26. data/lib/cql_qdm_patientapi/version.rb +1 -1
  27. data/vendor/assets/javascripts/cql4browsers.js +32 -0
  28. metadata +3 -3
@@ -20,6 +20,7 @@ class CQL_QDM.FamilyHistory extends CQL_QDM.QDMDatatype
20
20
  super @entry
21
21
  @_authorDatetime = CQL_QDM.Helpers.convertDateTime(@entry.start_time)
22
22
  @_relationship = @entry.relationshipToPatient
23
+ delete @entry.end_time
23
24
 
24
25
  ###
25
26
  @returns {Date}
@@ -32,6 +33,6 @@ class CQL_QDM.FamilyHistory extends CQL_QDM.QDMDatatype
32
33
  ###
33
34
  relationship: ->
34
35
  if @_relationship?
35
- new cql.Code(@_relationship.code, @_relationship.code_system)
36
+ new cql.Code(@_relationship.code, @_relationship.code_system, null, @_relationship.title || null)
36
37
  else
37
38
  null
@@ -22,6 +22,7 @@ class CQL_QDM.ImmunizationAdministered extends CQL_QDM.QDMDatatype
22
22
  @_reason = @entry.reason
23
23
  @_route = @entry.route
24
24
  @_supply = @entry.supply
25
+ delete @entry.end_time
25
26
 
26
27
  ###
27
28
  @returns {Date}
@@ -34,7 +35,10 @@ class CQL_QDM.ImmunizationAdministered extends CQL_QDM.QDMDatatype
34
35
  ###
35
36
  dosage: ->
36
37
  if @_dosage?
37
- new cql.Quantity({unit: @_dosage['units'], value: @_dosage['scalar']})
38
+ if @_dosage['unit']? || @_dosage['value']?
39
+ new cql.Quantity({unit: @_dosage['unit'], value: @_dosage['value']})
40
+ else
41
+ new cql.Quantity({unit: @_dosage['units'], value: @_dosage['scalar']})
38
42
  else
39
43
  null
40
44
 
@@ -43,7 +47,7 @@ class CQL_QDM.ImmunizationAdministered extends CQL_QDM.QDMDatatype
43
47
  ###
44
48
  negationRationale: ->
45
49
  if @_negationRationale?
46
- new cql.Code(@_negationRationale.code, @_negationRationale.code_system)
50
+ new cql.Code(@_negationRationale.code, @_negationRationale.code_system, null, @_negationRationale.title || null)
47
51
  else
48
52
  null
49
53
 
@@ -52,7 +56,7 @@ class CQL_QDM.ImmunizationAdministered extends CQL_QDM.QDMDatatype
52
56
  ###
53
57
  reason: ->
54
58
  if @_reason?
55
- new cql.Code(@_reason.code, @_reason.code_system)
59
+ new cql.Code(@_reason.code, @_reason.code_system, null, @_reason.title || null)
56
60
  else
57
61
  null
58
62
 
@@ -61,7 +65,7 @@ class CQL_QDM.ImmunizationAdministered extends CQL_QDM.QDMDatatype
61
65
  ###
62
66
  route: ->
63
67
  if @_route?
64
- new cql.Code(@_route.code, @_route.code_system)
68
+ new cql.Code(@_route.code, @_route.code_system, null, @_route.title || null)
65
69
  else
66
70
  null
67
71
 
@@ -99,6 +103,7 @@ class CQL_QDM.ImmunizationOrder extends CQL_QDM.QDMDatatype
99
103
  @_reason = @entry.reason
100
104
  @_route = @entry.route
101
105
  @_supply = @entry.supply
106
+ delete @entry.end_time
102
107
 
103
108
  ###
104
109
  @returns {Date}
@@ -117,7 +122,10 @@ class CQL_QDM.ImmunizationOrder extends CQL_QDM.QDMDatatype
117
122
  ###
118
123
  dosage: ->
119
124
  if @_dosage?
120
- new cql.Quantity({unit: @_dosage['units'], value: @_dosage['scalar']})
125
+ if @_dosage['unit']? || @_dosage['value']?
126
+ new cql.Quantity({unit: @_dosage['unit'], value: @_dosage['value']})
127
+ else
128
+ new cql.Quantity({unit: @_dosage['units'], value: @_dosage['scalar']})
121
129
  else
122
130
  null
123
131
 
@@ -126,7 +134,7 @@ class CQL_QDM.ImmunizationOrder extends CQL_QDM.QDMDatatype
126
134
  ###
127
135
  negationRationale: ->
128
136
  if @_negationRationale?
129
- new cql.Code(@_negationRationale.code, @_negationRationale.code_system)
137
+ new cql.Code(@_negationRationale.code, @_negationRationale.code_system, null, @_negationRationale.title || null)
130
138
  else
131
139
  null
132
140
 
@@ -135,7 +143,7 @@ class CQL_QDM.ImmunizationOrder extends CQL_QDM.QDMDatatype
135
143
  ###
136
144
  reason: ->
137
145
  if @_reason?
138
- new cql.Code(@_reason.code, @_reason.code_system)
146
+ new cql.Code(@_reason.code, @_reason.code_system, null, @_reason.title || null)
139
147
  else
140
148
  null
141
149
 
@@ -144,7 +152,7 @@ class CQL_QDM.ImmunizationOrder extends CQL_QDM.QDMDatatype
144
152
  ###
145
153
  route: ->
146
154
  if @_route?
147
- new cql.Code(@_route.code, @_route.code_system)
155
+ new cql.Code(@_route.code, @_route.code_system, null, @_route.title || null)
148
156
  else
149
157
  null
150
158
 
@@ -19,6 +19,7 @@ class CQL_QDM.InterventionOrder extends CQL_QDM.QDMDatatype
19
19
  @_negationRationale = @entry.negationReason
20
20
  @_reason = @entry.reason
21
21
  @_authorDatetime = CQL_QDM.Helpers.convertDateTime(@entry.start_time)
22
+ delete @entry.end_time
22
23
 
23
24
  ###
24
25
  @returns {Date}
@@ -31,7 +32,7 @@ class CQL_QDM.InterventionOrder extends CQL_QDM.QDMDatatype
31
32
  ###
32
33
  negationRationale: ->
33
34
  if @_negationRationale?
34
- new cql.Code(@_negationRationale.code, @_negationRationale.code_system)
35
+ new cql.Code(@_negationRationale.code, @_negationRationale.code_system, null, @_negationRationale.title || null)
35
36
  else
36
37
  null
37
38
 
@@ -40,7 +41,7 @@ class CQL_QDM.InterventionOrder extends CQL_QDM.QDMDatatype
40
41
  ###
41
42
  reason: ->
42
43
  if @_reason?
43
- new cql.Code(@_reason.code, @_reason.code_system)
44
+ new cql.Code(@_reason.code, @_reason.code_system, null, @_reason.title || null)
44
45
  else
45
46
  null
46
47
 
@@ -81,7 +82,7 @@ class CQL_QDM.InterventionPerformed extends CQL_QDM.QDMDatatype
81
82
  ###
82
83
  negationRationale: ->
83
84
  if @_negationRationale?
84
- new cql.Code(@_negationRationale.code, @_negationRationale.code_system)
85
+ new cql.Code(@_negationRationale.code, @_negationRationale.code_system, null, @_negationRationale.title || null)
85
86
  else
86
87
  null
87
88
 
@@ -90,7 +91,7 @@ class CQL_QDM.InterventionPerformed extends CQL_QDM.QDMDatatype
90
91
  ###
91
92
  reason: ->
92
93
  if @_reason?
93
- new cql.Code(@_reason.code, @_reason.code_system)
94
+ new cql.Code(@_reason.code, @_reason.code_system, null, @_reason.title || null)
94
95
  else
95
96
  null
96
97
 
@@ -119,7 +120,7 @@ class CQL_QDM.InterventionPerformed extends CQL_QDM.QDMDatatype
119
120
  ###
120
121
  status: ->
121
122
  if @_status?
122
- new cql.Code(@_status.code, @_status.code_system)
123
+ new cql.Code(@_status.code, @_status.code_system, null, @_status.title || null)
123
124
  else
124
125
  null
125
126
 
@@ -138,6 +139,7 @@ class CQL_QDM.InterventionRecommended extends CQL_QDM.QDMDatatype
138
139
  @_authorDatetime = CQL_QDM.Helpers.convertDateTime(@entry.start_time)
139
140
  @_negationRationale = @entry.negationReason
140
141
  @_reason = @entry.reason
142
+ delete @entry.end_time
141
143
 
142
144
  ###
143
145
  @returns {Date}
@@ -150,7 +152,7 @@ class CQL_QDM.InterventionRecommended extends CQL_QDM.QDMDatatype
150
152
  ###
151
153
  negationRationale: ->
152
154
  if @_negationRationale?
153
- new cql.Code(@_negationRationale.code, @_negationRationale.code_system)
155
+ new cql.Code(@_negationRationale.code, @_negationRationale.code_system, null, @_negationRationale.title || null)
154
156
  else
155
157
  null
156
158
 
@@ -159,6 +161,6 @@ class CQL_QDM.InterventionRecommended extends CQL_QDM.QDMDatatype
159
161
  ###
160
162
  reason: ->
161
163
  if @_reason?
162
- new cql.Code(@_reason.code, @_reason.code_system)
164
+ new cql.Code(@_reason.code, @_reason.code_system, null, @_reason.title || null)
163
165
  else
164
166
  null
@@ -19,6 +19,7 @@ class CQL_QDM.LaboratoryTestOrder extends CQL_QDM.QDMDatatype
19
19
  @_negationRationale = @entry.negationReason
20
20
  @_reason = @entry.reason
21
21
  @_authorDatetime = CQL_QDM.Helpers.convertDateTime(@entry.start_time)
22
+ delete @entry.end_time
22
23
 
23
24
  ###
24
25
  @returns {Code}
@@ -34,7 +35,7 @@ class CQL_QDM.LaboratoryTestOrder extends CQL_QDM.QDMDatatype
34
35
  ###
35
36
  negationRationale: ->
36
37
  if @_negationRationale?
37
- new cql.Code(@_negationRationale.code, @_negationRationale.code_system)
38
+ new cql.Code(@_negationRationale.code, @_negationRationale.code_system, null, @_negationRationale.title || null)
38
39
  else
39
40
  null
40
41
 
@@ -43,7 +44,7 @@ class CQL_QDM.LaboratoryTestOrder extends CQL_QDM.QDMDatatype
43
44
  ###
44
45
  reason: ->
45
46
  if @_reason?
46
- new cql.Code(@_reason.code, @_reason.code_system)
47
+ new cql.Code(@_reason.code, @_reason.code_system, null, @_reason.title || null)
47
48
  else
48
49
  null
49
50
 
@@ -94,7 +95,7 @@ class CQL_QDM.LaboratoryTestPerformed extends CQL_QDM.QDMDatatype
94
95
  ###
95
96
  method: ->
96
97
  if @_method?
97
- new cql.Code(@_method.code, @_method.code_system)
98
+ new cql.Code(@_method.code, @_method.code_system, null, @_method.title || null)
98
99
  else
99
100
  null
100
101
 
@@ -103,7 +104,7 @@ class CQL_QDM.LaboratoryTestPerformed extends CQL_QDM.QDMDatatype
103
104
  ###
104
105
  negationRationale: ->
105
106
  if @_negationRationale?
106
- new cql.Code(@_negationRationale.code, @_negationRationale.code_system)
107
+ new cql.Code(@_negationRationale.code, @_negationRationale.code_system, null, @_negationRationale.title || null)
107
108
  else
108
109
  null
109
110
 
@@ -112,7 +113,7 @@ class CQL_QDM.LaboratoryTestPerformed extends CQL_QDM.QDMDatatype
112
113
  ###
113
114
  reason: ->
114
115
  if @_reason?
115
- new cql.Code(@_reason.code, @_reason.code_system)
116
+ new cql.Code(@_reason.code, @_reason.code_system, null, @_reason.title || null)
116
117
  else
117
118
  null
118
119
 
@@ -173,7 +174,7 @@ class CQL_QDM.LaboratoryTestPerformed extends CQL_QDM.QDMDatatype
173
174
  ###
174
175
  status: ->
175
176
  if @_status?
176
- new cql.Code(@_status.code, @_status.code_system)
177
+ new cql.Code(@_status.code, @_status.code_system, null, @_status.title || null)
177
178
  else
178
179
  null
179
180
 
@@ -207,6 +208,7 @@ class CQL_QDM.LaboratoryTestRecommended extends CQL_QDM.QDMDatatype
207
208
  @_method = @entry.method
208
209
  @_negationRationale = @entry.negationReason
209
210
  @_reason = @entry.reason
211
+ delete @entry.end_time
210
212
 
211
213
  ###
212
214
  @returns {Date}
@@ -219,7 +221,7 @@ class CQL_QDM.LaboratoryTestRecommended extends CQL_QDM.QDMDatatype
219
221
  ###
220
222
  method: ->
221
223
  if @_method?
222
- new cql.Code(@_method.code, @_method.code_system)
224
+ new cql.Code(@_method.code, @_method.code_system, null, @_method.title || null)
223
225
  else
224
226
  null
225
227
 
@@ -228,7 +230,7 @@ class CQL_QDM.LaboratoryTestRecommended extends CQL_QDM.QDMDatatype
228
230
  ###
229
231
  negationRationale: ->
230
232
  if @_negationRationale?
231
- new cql.Code(@_negationRationale.code, @_negationRationale.code_system)
233
+ new cql.Code(@_negationRationale.code, @_negationRationale.code_system, null, @_negationRationale.title || null)
232
234
  else
233
235
  null
234
236
 
@@ -237,6 +239,6 @@ class CQL_QDM.LaboratoryTestRecommended extends CQL_QDM.QDMDatatype
237
239
  ###
238
240
  reason: ->
239
241
  if @_reason?
240
- new cql.Code(@_reason.code, @_reason.code_system)
242
+ new cql.Code(@_reason.code, @_reason.code_system, null, @_reason.title || null)
241
243
  else
242
244
  null
@@ -34,7 +34,10 @@ class CQL_QDM.MedicationActive extends CQL_QDM.QDMDatatype
34
34
  ###
35
35
  dosage: ->
36
36
  if @_dosage?
37
- new cql.Quantity({unit: @_dosage['units'], value: @_dosage['scalar']})
37
+ if @_dosage['unit']? || @_dosage['value']?
38
+ new cql.Quantity({unit: @_dosage['unit'], value: @_dosage['value']})
39
+ else
40
+ new cql.Quantity({unit: @_dosage['units'], value: @_dosage['scalar']})
38
41
  else
39
42
  null
40
43
 
@@ -43,7 +46,7 @@ class CQL_QDM.MedicationActive extends CQL_QDM.QDMDatatype
43
46
  ###
44
47
  frequency: ->
45
48
  if @_frequency?
46
- new cql.Code(@_frequency.code, @_frequency.code_system)
49
+ new cql.Code(@_frequency.code, @_frequency.code_system, null, @_frequency.title || null)
47
50
  else
48
51
  null
49
52
 
@@ -52,7 +55,7 @@ class CQL_QDM.MedicationActive extends CQL_QDM.QDMDatatype
52
55
  ###
53
56
  route: ->
54
57
  if @_route?
55
- new cql.Code(@_route.code, @_route.code_system)
58
+ new cql.Code(@_route.code, @_route.code_system, null, @_route.title || null)
56
59
  else
57
60
  null
58
61
 
@@ -114,7 +117,10 @@ class CQL_QDM.MedicationAdministered extends CQL_QDM.QDMDatatype
114
117
  ###
115
118
  dosage: ->
116
119
  if @_dosage?
117
- new cql.Quantity({unit: @_dosage['units'], value: @_dosage['scalar']})
120
+ if @_dosage['unit']? || @_dosage['value']?
121
+ new cql.Quantity({unit: @_dosage['unit'], value: @_dosage['value']})
122
+ else
123
+ new cql.Quantity({unit: @_dosage['units'], value: @_dosage['scalar']})
118
124
  else
119
125
  null
120
126
 
@@ -123,7 +129,7 @@ class CQL_QDM.MedicationAdministered extends CQL_QDM.QDMDatatype
123
129
  ###
124
130
  frequency: ->
125
131
  if @_frequency?
126
- new cql.Code(@_frequency.code, @_frequency.code_system)
132
+ new cql.Code(@_frequency.code, @_frequency.code_system, null, @_frequency.title || null)
127
133
  else
128
134
  null
129
135
 
@@ -132,7 +138,7 @@ class CQL_QDM.MedicationAdministered extends CQL_QDM.QDMDatatype
132
138
  ###
133
139
  negationRationale: ->
134
140
  if @_negationRationale?
135
- new cql.Code(@_negationRationale.code, @_negationRationale.code_system)
141
+ new cql.Code(@_negationRationale.code, @_negationRationale.code_system, null, @_negationRationale.title || null)
136
142
  else
137
143
  null
138
144
 
@@ -141,7 +147,7 @@ class CQL_QDM.MedicationAdministered extends CQL_QDM.QDMDatatype
141
147
  ###
142
148
  reason: ->
143
149
  if @_reason?
144
- new cql.Code(@_reason.code, @_reason.code_system)
150
+ new cql.Code(@_reason.code, @_reason.code_system, null, @_reason.title || null)
145
151
  else
146
152
  null
147
153
 
@@ -161,7 +167,7 @@ class CQL_QDM.MedicationAdministered extends CQL_QDM.QDMDatatype
161
167
  ###
162
168
  route: ->
163
169
  if @_route?
164
- new cql.Code(@_route.code, @_route.code_system)
170
+ new cql.Code(@_route.code, @_route.code_system, null, @_route.title || null)
165
171
  else
166
172
  null
167
173
 
@@ -194,6 +200,7 @@ class CQL_QDM.MedicationDischarge extends CQL_QDM.QDMDatatype
194
200
  @_refills = @entry.refills
195
201
  @_route = @entry.route
196
202
  @_supply = @entry.supply
203
+ delete @entry.end_time
197
204
 
198
205
  ###
199
206
  @returns {Date}
@@ -206,7 +213,10 @@ class CQL_QDM.MedicationDischarge extends CQL_QDM.QDMDatatype
206
213
  ###
207
214
  dosage: ->
208
215
  if @_dosage?
209
- new cql.Quantity({unit: @_dosage['units'], value: @_dosage['scalar']})
216
+ if @_dosage['unit']? || @_dosage['value']?
217
+ new cql.Quantity({unit: @_dosage['unit'], value: @_dosage['value']})
218
+ else
219
+ new cql.Quantity({unit: @_dosage['units'], value: @_dosage['scalar']})
210
220
  else
211
221
  null
212
222
 
@@ -215,7 +225,7 @@ class CQL_QDM.MedicationDischarge extends CQL_QDM.QDMDatatype
215
225
  ###
216
226
  frequency: ->
217
227
  if @_frequency?
218
- new cql.Code(@_frequency.code, @_frequency.code_system)
228
+ new cql.Code(@_frequency.code, @_frequency.code_system, null, @_frequency.title || null)
219
229
  else
220
230
  null
221
231
 
@@ -224,7 +234,7 @@ class CQL_QDM.MedicationDischarge extends CQL_QDM.QDMDatatype
224
234
  ###
225
235
  negationRationale: ->
226
236
  if @_negationRationale?
227
- new cql.Code(@_negationRationale.code, @_negationRationale.code_system)
237
+ new cql.Code(@_negationRationale.code, @_negationRationale.code_system, null, @_negationRationale.title || null)
228
238
  else
229
239
  null
230
240
 
@@ -242,7 +252,7 @@ class CQL_QDM.MedicationDischarge extends CQL_QDM.QDMDatatype
242
252
  ###
243
253
  route: ->
244
254
  if @_route?
245
- new cql.Code(@_route.code, @_route.code_system)
255
+ new cql.Code(@_route.code, @_route.code_system, null, @_route.title || null)
246
256
  else
247
257
  null
248
258
 
@@ -297,7 +307,10 @@ class CQL_QDM.MedicationDispensed extends CQL_QDM.QDMDatatype
297
307
  ###
298
308
  dosage: ->
299
309
  if @_dosage?
300
- new cql.Quantity({unit: @_dosage['units'], value: @_dosage['scalar']})
310
+ if @_dosage['unit']? || @_dosage['value']?
311
+ new cql.Quantity({unit: @_dosage['unit'], value: @_dosage['value']})
312
+ else
313
+ new cql.Quantity({unit: @_dosage['units'], value: @_dosage['scalar']})
301
314
  else
302
315
  null
303
316
 
@@ -306,7 +319,7 @@ class CQL_QDM.MedicationDispensed extends CQL_QDM.QDMDatatype
306
319
  ###
307
320
  frequency: ->
308
321
  if @_frequency?
309
- new cql.Code(@_frequency.code, @_frequency.code_system)
322
+ new cql.Code(@_frequency.code, @_frequency.code_system, null, @_frequency.title || null)
310
323
  else
311
324
  null
312
325
 
@@ -315,7 +328,7 @@ class CQL_QDM.MedicationDispensed extends CQL_QDM.QDMDatatype
315
328
  ###
316
329
  negationRationale: ->
317
330
  if @_negationRationale?
318
- new cql.Code(@_negationRationale.code, @_negationRationale.code_system)
331
+ new cql.Code(@_negationRationale.code, @_negationRationale.code_system, null, @_negationRationale.title || null)
319
332
  else
320
333
  null
321
334
 
@@ -344,7 +357,7 @@ class CQL_QDM.MedicationDispensed extends CQL_QDM.QDMDatatype
344
357
  ###
345
358
  route: ->
346
359
  if @_route?
347
- new cql.Code(@_route.code, @_route.code_system)
360
+ new cql.Code(@_route.code, @_route.code_system, null, @_route.title || null)
348
361
  else
349
362
  null
350
363
 
@@ -396,7 +409,10 @@ class CQL_QDM.MedicationOrder extends CQL_QDM.QDMDatatype
396
409
  ###
397
410
  dosage: ->
398
411
  if @_dosage?
399
- new cql.Quantity({unit: @_dosage['units'], value: @_dosage['scalar']})
412
+ if @_dosage['unit']? || @_dosage['value']?
413
+ new cql.Quantity({unit: @_dosage['unit'], value: @_dosage['value']})
414
+ else
415
+ new cql.Quantity({unit: @_dosage['units'], value: @_dosage['scalar']})
400
416
  else
401
417
  null
402
418
 
@@ -405,7 +421,7 @@ class CQL_QDM.MedicationOrder extends CQL_QDM.QDMDatatype
405
421
  ###
406
422
  frequency: ->
407
423
  if @_frequency?
408
- new cql.Code(@_frequency.code, @_frequency.code_system)
424
+ new cql.Code(@_frequency.code, @_frequency.code_system, null, @_frequency.title || null)
409
425
  else
410
426
  null
411
427
 
@@ -414,7 +430,7 @@ class CQL_QDM.MedicationOrder extends CQL_QDM.QDMDatatype
414
430
  ###
415
431
  method: ->
416
432
  if @_method?
417
- new cql.Code(@_method.code, @_method.code_system)
433
+ new cql.Code(@_method.code, @_method.code_system, null, @_method.title || null)
418
434
  else
419
435
  null
420
436
 
@@ -423,7 +439,7 @@ class CQL_QDM.MedicationOrder extends CQL_QDM.QDMDatatype
423
439
  ###
424
440
  negationRationale: ->
425
441
  if @_negationRationale?
426
- new cql.Code(@_negationRationale.code, @_negationRationale.code_system)
442
+ new cql.Code(@_negationRationale.code, @_negationRationale.code_system, null, @_negationRationale.title || null)
427
443
  else
428
444
  null
429
445
 
@@ -432,7 +448,7 @@ class CQL_QDM.MedicationOrder extends CQL_QDM.QDMDatatype
432
448
  ###
433
449
  reason: ->
434
450
  if @_reason?
435
- new cql.Code(@_reason.code, @_reason.code_system)
451
+ new cql.Code(@_reason.code, @_reason.code_system, null, @_reason.title || null)
436
452
  else
437
453
  null
438
454
 
@@ -461,7 +477,7 @@ class CQL_QDM.MedicationOrder extends CQL_QDM.QDMDatatype
461
477
  ###
462
478
  route: ->
463
479
  if @_route?
464
- new cql.Code(@_route.code, @_route.code_system)
480
+ new cql.Code(@_route.code, @_route.code_system, null, @_route.title || null)
465
481
  else
466
482
  null
467
483