cqm-models 0.8.4 → 1.0.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (142) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +1 -1
  3. data/app/assets/javascripts/AdverseEvent.js +2 -2
  4. data/app/assets/javascripts/AllDataElements.js +4 -8
  5. data/app/assets/javascripts/AllergyIntolerance.js +2 -2
  6. data/app/assets/javascripts/{CommunicationFromProviderToPatient.js → AssessmentOrder.js} +9 -9
  7. data/app/assets/javascripts/AssessmentPerformed.js +2 -2
  8. data/app/assets/javascripts/AssessmentRecommended.js +2 -3
  9. data/app/assets/javascripts/CareGoal.js +2 -2
  10. data/app/assets/javascripts/{CommunicationFromPatientToProvider.js → CommunicationPerformed.js} +13 -8
  11. data/app/assets/javascripts/Component.js +1 -1
  12. data/app/assets/javascripts/DeviceApplied.js +2 -3
  13. data/app/assets/javascripts/DeviceOrder.js +2 -2
  14. data/app/assets/javascripts/DeviceRecommended.js +2 -2
  15. data/app/assets/javascripts/Diagnosis.js +2 -2
  16. data/app/assets/javascripts/DiagnosticStudyOrder.js +2 -3
  17. data/app/assets/javascripts/DiagnosticStudyPerformed.js +2 -2
  18. data/app/assets/javascripts/DiagnosticStudyRecommended.js +2 -3
  19. data/app/assets/javascripts/EncounterOrder.js +2 -2
  20. data/app/assets/javascripts/EncounterPerformed.js +2 -2
  21. data/app/assets/javascripts/EncounterRecommended.js +2 -2
  22. data/app/assets/javascripts/FacilityLocation.js +1 -1
  23. data/app/assets/javascripts/FamilyHistory.js +2 -2
  24. data/app/assets/javascripts/Id.js +1 -1
  25. data/app/assets/javascripts/ImmunizationAdministered.js +2 -3
  26. data/app/assets/javascripts/ImmunizationOrder.js +2 -2
  27. data/app/assets/javascripts/InterventionOrder.js +2 -2
  28. data/app/assets/javascripts/InterventionPerformed.js +2 -2
  29. data/app/assets/javascripts/InterventionRecommended.js +2 -2
  30. data/app/assets/javascripts/LaboratoryTestOrder.js +2 -3
  31. data/app/assets/javascripts/LaboratoryTestPerformed.js +2 -2
  32. data/app/assets/javascripts/LaboratoryTestRecommended.js +2 -3
  33. data/app/assets/javascripts/MedicationActive.js +2 -3
  34. data/app/assets/javascripts/MedicationAdministered.js +2 -3
  35. data/app/assets/javascripts/MedicationDischarge.js +3 -2
  36. data/app/assets/javascripts/MedicationDispensed.js +5 -2
  37. data/app/assets/javascripts/MedicationOrder.js +5 -4
  38. data/app/assets/javascripts/Participation.js +2 -2
  39. data/app/assets/javascripts/Patient.js +4 -4
  40. data/app/assets/javascripts/PatientCareExperience.js +2 -2
  41. data/app/assets/javascripts/PatientCharacteristic.js +2 -2
  42. data/app/assets/javascripts/PatientCharacteristicBirthdate.js +2 -2
  43. data/app/assets/javascripts/PatientCharacteristicClinicalTrialParticipant.js +2 -2
  44. data/app/assets/javascripts/PatientCharacteristicEthnicity.js +2 -2
  45. data/app/assets/javascripts/PatientCharacteristicExpired.js +2 -2
  46. data/app/assets/javascripts/PatientCharacteristicPayer.js +2 -2
  47. data/app/assets/javascripts/PatientCharacteristicRace.js +2 -2
  48. data/app/assets/javascripts/PatientCharacteristicSex.js +2 -2
  49. data/app/assets/javascripts/PhysicalExamOrder.js +2 -3
  50. data/app/assets/javascripts/PhysicalExamPerformed.js +2 -2
  51. data/app/assets/javascripts/PhysicalExamRecommended.js +2 -3
  52. data/app/assets/javascripts/ProcedureOrder.js +2 -4
  53. data/app/assets/javascripts/ProcedurePerformed.js +2 -3
  54. data/app/assets/javascripts/ProcedureRecommended.js +2 -4
  55. data/app/assets/javascripts/ProviderCareExperience.js +2 -2
  56. data/app/assets/javascripts/ProviderCharacteristic.js +2 -2
  57. data/app/assets/javascripts/ResultComponent.js +1 -1
  58. data/app/assets/javascripts/SubstanceAdministered.js +2 -3
  59. data/app/assets/javascripts/SubstanceOrder.js +2 -3
  60. data/app/assets/javascripts/SubstanceRecommended.js +2 -4
  61. data/app/assets/javascripts/Symptom.js +2 -2
  62. data/app/assets/javascripts/basetypes/Any.js +3 -3
  63. data/app/assets/javascripts/basetypes/DateTime.js +1 -1
  64. data/app/assets/javascripts/basetypes/Interval.js +2 -2
  65. data/app/assets/javascripts/basetypes/Ratio.js +20 -0
  66. data/app/models/models.rb +4 -5
  67. data/app/models/qdm/adverse_event.rb +2 -2
  68. data/app/models/qdm/allergy_intolerance.rb +2 -2
  69. data/app/models/qdm/assessment_order.rb +14 -0
  70. data/app/models/qdm/assessment_performed.rb +2 -2
  71. data/app/models/qdm/assessment_recommended.rb +2 -3
  72. data/app/models/qdm/basetypes/ratio.rb +52 -0
  73. data/app/models/qdm/care_goal.rb +2 -2
  74. data/app/models/qdm/communication_performed.rb +19 -0
  75. data/app/models/qdm/component.rb +1 -1
  76. data/app/models/qdm/device_applied.rb +2 -3
  77. data/app/models/qdm/device_order.rb +2 -2
  78. data/app/models/qdm/device_recommended.rb +2 -2
  79. data/app/models/qdm/diagnosis.rb +2 -2
  80. data/app/models/qdm/diagnostic_study_order.rb +2 -3
  81. data/app/models/qdm/diagnostic_study_performed.rb +2 -2
  82. data/app/models/qdm/diagnostic_study_recommended.rb +2 -3
  83. data/app/models/qdm/encounter_order.rb +2 -2
  84. data/app/models/qdm/encounter_performed.rb +2 -2
  85. data/app/models/qdm/encounter_recommended.rb +2 -2
  86. data/app/models/qdm/facility_location.rb +1 -1
  87. data/app/models/qdm/family_history.rb +2 -2
  88. data/app/models/qdm/id.rb +1 -1
  89. data/app/models/qdm/immunization_administered.rb +2 -3
  90. data/app/models/qdm/immunization_order.rb +2 -2
  91. data/app/models/qdm/intervention_order.rb +2 -2
  92. data/app/models/qdm/intervention_performed.rb +2 -2
  93. data/app/models/qdm/intervention_recommended.rb +2 -2
  94. data/app/models/qdm/laboratory_test_order.rb +2 -3
  95. data/app/models/qdm/laboratory_test_performed.rb +2 -2
  96. data/app/models/qdm/laboratory_test_recommended.rb +2 -3
  97. data/app/models/qdm/medication_active.rb +2 -3
  98. data/app/models/qdm/medication_administered.rb +2 -3
  99. data/app/models/qdm/medication_discharge.rb +3 -2
  100. data/app/models/qdm/medication_dispensed.rb +5 -2
  101. data/app/models/qdm/medication_order.rb +5 -4
  102. data/app/models/qdm/participation.rb +2 -2
  103. data/app/models/qdm/patient.rb +3 -3
  104. data/app/models/qdm/patient_care_experience.rb +2 -2
  105. data/app/models/qdm/patient_characteristic.rb +2 -2
  106. data/app/models/qdm/patient_characteristic_birthdate.rb +2 -2
  107. data/app/models/qdm/patient_characteristic_clinical_trial_participant.rb +2 -2
  108. data/app/models/qdm/patient_characteristic_ethnicity.rb +2 -2
  109. data/app/models/qdm/patient_characteristic_expired.rb +2 -2
  110. data/app/models/qdm/patient_characteristic_payer.rb +2 -2
  111. data/app/models/qdm/patient_characteristic_race.rb +2 -2
  112. data/app/models/qdm/patient_characteristic_sex.rb +2 -2
  113. data/app/models/qdm/physical_exam_order.rb +2 -3
  114. data/app/models/qdm/physical_exam_performed.rb +2 -2
  115. data/app/models/qdm/physical_exam_recommended.rb +2 -3
  116. data/app/models/qdm/procedure_order.rb +2 -4
  117. data/app/models/qdm/procedure_performed.rb +2 -3
  118. data/app/models/qdm/procedure_recommended.rb +2 -4
  119. data/app/models/qdm/provider_care_experience.rb +2 -2
  120. data/app/models/qdm/provider_characteristic.rb +2 -2
  121. data/app/models/qdm/result_component.rb +1 -1
  122. data/app/models/qdm/substance_administered.rb +2 -3
  123. data/app/models/qdm/substance_order.rb +2 -3
  124. data/app/models/qdm/substance_recommended.rb +2 -4
  125. data/app/models/qdm/symptom.rb +2 -2
  126. data/cqm-models.gemspec +1 -1
  127. data/data/oids.json +209 -197
  128. data/dist/index.js +2114 -1230
  129. data/lib/generate_models.rb +14 -12
  130. data/modelinfo/qdm-modelinfo-5.4.xml +503 -0
  131. data/package.json +2 -2
  132. data/templates/models_template.rb.erb +2 -1
  133. data/templates/patient_extension.rb.erb +2 -2
  134. data/templates/patient_template.js.erb +3 -3
  135. data/yarn.lock +3 -3
  136. metadata +10 -11
  137. data/app/assets/javascripts/CommunicationFromProviderToProvider.js +0 -30
  138. data/app/assets/javascripts/Ratio.js +0 -26
  139. data/app/models/qdm/communication_from_patient_to_provider.rb +0 -14
  140. data/app/models/qdm/communication_from_provider_to_patient.rb +0 -14
  141. data/app/models/qdm/communication_from_provider_to_provider.rb +0 -14
  142. data/app/models/qdm/ratio.rb +0 -10
@@ -20,14 +20,13 @@ const SubstanceOrderSchema = DataElementSchema({
20
20
  dosage: Quantity,
21
21
  supply: Quantity,
22
22
  frequency: Code,
23
- method: Code,
24
23
  refills: Number,
25
24
  route: Code,
26
25
  negationRationale: Code,
27
26
  hqmfOid: { type: String, default: '2.16.840.1.113883.10.20.28.3.77' },
28
- category: { type: String, default: 'substance' },
27
+ qdmCategory: { type: String, default: 'substance' },
29
28
  qdmStatus: { type: String, default: 'order' },
30
- qdmVersion: { type: String, default: '5.3' },
29
+ qdmVersion: { type: String, default: '5.4' },
31
30
  _type: { type: String, default: 'SubstanceOrder' },
32
31
 
33
32
  });
@@ -18,16 +18,14 @@ const SubstanceRecommendedSchema = DataElementSchema({
18
18
  authorDatetime: DateTime,
19
19
  reason: Code,
20
20
  dosage: Quantity,
21
- supply: Quantity,
22
21
  frequency: Code,
23
- method: Code,
24
22
  refills: Number,
25
23
  route: Code,
26
24
  negationRationale: Code,
27
25
  hqmfOid: { type: String, default: '2.16.840.1.113883.10.20.28.3.78' },
28
- category: { type: String, default: 'substance' },
26
+ qdmCategory: { type: String, default: 'substance' },
29
27
  qdmStatus: { type: String, default: 'recommended' },
30
- qdmVersion: { type: String, default: '5.3' },
28
+ qdmVersion: { type: String, default: '5.4' },
31
29
  _type: { type: String, default: 'SubstanceRecommended' },
32
30
 
33
31
  });
@@ -19,8 +19,8 @@ const SymptomSchema = DataElementSchema({
19
19
  severity: Code,
20
20
  hqmfOid: { type: String, default: '2.16.840.1.113883.10.20.28.3.116' },
21
21
  qrdaOid: { type: String, default: '2.16.840.1.113883.10.20.24.3.136' },
22
- category: { type: String, default: 'symptom' },
23
- qdmVersion: { type: String, default: '5.3' },
22
+ qdmCategory: { type: String, default: 'symptom' },
23
+ qdmVersion: { type: String, default: '5.4' },
24
24
  _type: { type: String, default: 'Symptom' },
25
25
 
26
26
  });
@@ -39,10 +39,10 @@ function RecursiveCast(any) {
39
39
 
40
40
  // Cast to DateTime if it is a string representing a DateTime
41
41
  if (casted.low && Date.parse(casted.low)) {
42
- casted.low = cql.DateTime.fromDate(new Date(casted.low), 0);
42
+ casted.low = cql.DateTime.fromJSDate(new Date(casted.low), 0);
43
43
  }
44
44
  if (casted.high && Date.parse(casted.high)) {
45
- casted.high = cql.DateTime.fromDate(new Date(casted.high), 0);
45
+ casted.high = cql.DateTime.fromJSDate(new Date(casted.high), 0);
46
46
  }
47
47
  return casted;
48
48
  }
@@ -57,7 +57,7 @@ function RecursiveCast(any) {
57
57
  return any;
58
58
  }
59
59
  if (Date.parse(any)) {
60
- return cql.DateTime.fromDate(new Date(any), 0);
60
+ return cql.DateTime.fromJSDate(new Date(any), 0);
61
61
  }
62
62
  return any;
63
63
  }
@@ -11,7 +11,7 @@ DateTime.prototype.cast = (dateTime) => {
11
11
  throw new Error(`DateTime: ${dateTime} is not a valid DateTime`);
12
12
  }
13
13
 
14
- return cql.DateTime.fromDate(new Date(dateTime), 0);
14
+ return cql.DateTime.fromJSDate(new Date(dateTime), 0);
15
15
  };
16
16
 
17
17
  mongoose.Schema.Types.DateTime = DateTime;
@@ -23,10 +23,10 @@ Interval.prototype.cast = (interval) => {
23
23
 
24
24
  // Cast to DateTime if it is a string representing a DateTime
25
25
  if (casted.low && Date.parse(casted.low)) {
26
- casted.low = cql.DateTime.fromDate(new Date(casted.low), 0);
26
+ casted.low = cql.DateTime.fromJSDate(new Date(casted.low), 0);
27
27
  }
28
28
  if (casted.high && Date.parse(casted.high)) {
29
- casted.high = cql.DateTime.fromDate(new Date(casted.high), 0);
29
+ casted.high = cql.DateTime.fromJSDate(new Date(casted.high), 0);
30
30
  }
31
31
  return casted;
32
32
  };
@@ -0,0 +1,20 @@
1
+ const mongoose = require('mongoose');
2
+ const cql = require('cql-execution');
3
+
4
+ function Ratio(key, options) {
5
+ mongoose.SchemaType.call(this, key, options, 'Ratio');
6
+ }
7
+ Ratio.prototype = Object.create(mongoose.SchemaType.prototype);
8
+
9
+ Ratio.prototype.cast = (ratio) => {
10
+ if (typeof ratio.numerator === 'undefined') {
11
+ throw new Error(`Ratio: ${ratio} does not have a numerator`);
12
+ } else if (typeof ratio.denominator === 'undefined') {
13
+ throw new Error(`Ratio: ${ratio} does not have a denominator`);
14
+ }
15
+
16
+ return new cql.Ratio(ratio);
17
+ };
18
+
19
+ mongoose.Schema.Types.Ratio = Ratio;
20
+ module.exports = Ratio;
data/app/models/models.rb CHANGED
@@ -8,9 +8,10 @@ require_relative 'qdm/id'
8
8
 
9
9
  # base types
10
10
  require_relative 'qdm/basetypes/code'
11
+ require_relative 'qdm/basetypes/data_element'
11
12
  require_relative 'qdm/basetypes/interval'
12
13
  require_relative 'qdm/basetypes/quantity'
13
- require_relative 'qdm/basetypes/data_element'
14
+ require_relative 'qdm/basetypes/ratio'
14
15
 
15
16
  # Tacoma-specific models
16
17
  require_relative 'qdm/tacoma/measure'
@@ -21,7 +22,6 @@ require_relative 'qdm/tacoma/individual_result'
21
22
 
22
23
  # Generated models
23
24
  require_relative 'qdm/patient'
24
- require_relative 'qdm/ratio'
25
25
  require_relative 'qdm/physical_exam_order'
26
26
  require_relative 'qdm/participation'
27
27
  require_relative 'qdm/patient_characteristic_sex'
@@ -35,7 +35,7 @@ require_relative 'qdm/medication_administered'
35
35
  require_relative 'qdm/procedure_recommended'
36
36
  require_relative 'qdm/encounter_performed'
37
37
  require_relative 'qdm/diagnosis'
38
- require_relative 'qdm/communication_from_provider_to_patient'
38
+ require_relative 'qdm/communication_performed'
39
39
  require_relative 'qdm/assessment_performed'
40
40
  require_relative 'qdm/patient_characteristic_clinical_trial_participant'
41
41
  require_relative 'qdm/device_order'
@@ -45,13 +45,13 @@ require_relative 'qdm/family_history'
45
45
  require_relative 'qdm/component'
46
46
  require_relative 'qdm/result_component'
47
47
  require_relative 'qdm/facility_location'
48
- require_relative 'qdm/communication_from_provider_to_provider'
49
48
  require_relative 'qdm/medication_active'
50
49
  require_relative 'qdm/laboratory_test_order'
51
50
  require_relative 'qdm/diagnostic_study_order'
52
51
  require_relative 'qdm/substance_order'
53
52
  require_relative 'qdm/patient_characteristic_payer'
54
53
  require_relative 'qdm/patient_characteristic_expired'
54
+ require_relative 'qdm/assessment_order'
55
55
  require_relative 'qdm/assessment_recommended'
56
56
  require_relative 'qdm/immunization_administered'
57
57
  require_relative 'qdm/substance_administered'
@@ -63,7 +63,6 @@ require_relative 'qdm/provider_characteristic'
63
63
  require_relative 'qdm/physical_exam_recommended'
64
64
  require_relative 'qdm/patient_characteristic_birthdate'
65
65
  require_relative 'qdm/adverse_event'
66
- require_relative 'qdm/communication_from_patient_to_provider'
67
66
  require_relative 'qdm/device_recommended'
68
67
  require_relative 'qdm/device_applied'
69
68
  require_relative 'qdm/medication_discharge'
@@ -9,7 +9,7 @@ module QDM
9
9
  field :facilityLocation, type: QDM::Code
10
10
  field :type, type: QDM::Code
11
11
  field :hqmfOid, type: String, default: '2.16.840.1.113883.10.20.28.3.120'
12
- field :category, type: String, default: 'adverse_event'
13
- field :qdmVersion, type: String, default: '5.3'
12
+ field :qdmCategory, type: String, default: 'adverse_event'
13
+ field :qdmVersion, type: String, default: '5.4'
14
14
  end
15
15
  end
@@ -8,8 +8,8 @@ module QDM
8
8
  field :type, type: QDM::Code
9
9
  field :severity, type: QDM::Code
10
10
  field :hqmfOid, type: String, default: '2.16.840.1.113883.10.20.28.3.119'
11
- field :category, type: String, default: 'allergy'
11
+ field :qdmCategory, type: String, default: 'allergy'
12
12
  field :qdmStatus, type: String, default: 'intolerance'
13
- field :qdmVersion, type: String, default: '5.3'
13
+ field :qdmVersion, type: String, default: '5.4'
14
14
  end
15
15
  end
@@ -0,0 +1,14 @@
1
+ module QDM
2
+ # app/models/qdm/assessment_order.rb
3
+ class AssessmentOrder < DataElement
4
+ include Mongoid::Document
5
+ embedded_in :patient
6
+ field :authorDatetime, type: DateTime
7
+ field :negationRationale, type: QDM::Code
8
+ field :reason, type: QDM::Code
9
+ field :hqmfOid, type: String, default: '2.16.840.1.113883.10.20.28.4.131'
10
+ field :qdmCategory, type: String, default: 'assessment'
11
+ field :qdmStatus, type: String, default: 'order'
12
+ field :qdmVersion, type: String, default: '5.4'
13
+ end
14
+ end
@@ -11,8 +11,8 @@ module QDM
11
11
  field :components, type: Array
12
12
  embeds_many :relatedTo, class_name: 'QDM::Id'
13
13
  field :hqmfOid, type: String, default: '2.16.840.1.113883.10.20.28.3.117'
14
- field :category, type: String, default: 'assessment'
14
+ field :qdmCategory, type: String, default: 'assessment'
15
15
  field :qdmStatus, type: String, default: 'performed'
16
- field :qdmVersion, type: String, default: '5.3'
16
+ field :qdmVersion, type: String, default: '5.4'
17
17
  end
18
18
  end
@@ -6,10 +6,9 @@ module QDM
6
6
  field :authorDatetime, type: DateTime
7
7
  field :negationRationale, type: QDM::Code
8
8
  field :reason, type: QDM::Code
9
- field :method, type: QDM::Code
10
9
  field :hqmfOid, type: String, default: '2.16.840.1.113883.10.20.28.3.118'
11
- field :category, type: String, default: 'assessment'
10
+ field :qdmCategory, type: String, default: 'assessment'
12
11
  field :qdmStatus, type: String, default: 'recommended'
13
- field :qdmVersion, type: String, default: '5.3'
12
+ field :qdmVersion, type: String, default: '5.4'
14
13
  end
15
14
  end
@@ -0,0 +1,52 @@
1
+ module QDM
2
+ # Represents a Ratio
3
+ class Ratio
4
+ attr_accessor :numerator, :denominator
5
+
6
+ # Numerator and denominator are required
7
+ def initialize(numerator, denominator)
8
+ @numerator = numerator
9
+ @denominator = denominator
10
+ end
11
+
12
+ # Converts an object of this instance into a database friendly value.
13
+ def mongoize
14
+ { numerator: @numerator, denominator: @denominator, _type: 'QDM::Ratio' }
15
+ end
16
+
17
+ class << self
18
+ # Get the object as it was stored in the database, and instantiate
19
+ # this custom class from it.
20
+ #
21
+ # The array elements in demongoize are the same 2 elements used in mongoize, i.e.
22
+ # [ numerator, denominator ].
23
+ def demongoize(object)
24
+ return nil unless object
25
+ object = object.symbolize_keys
26
+ QDM::Ratio.new(object[:numerator], object[:denominator]) if object.is_a?(Hash)
27
+ end
28
+
29
+ # Takes any possible object and converts it to how it would be
30
+ # stored in the database.
31
+ def mongoize(object)
32
+ case object
33
+ when nil then nil
34
+ when QDM::Ratio then object.mongoize
35
+ when Hash
36
+ object = object.symbolize_keys
37
+ QDM::Ratio.new(object[:numerator], object[:denominator]).mongoize
38
+ else object
39
+ end
40
+ end
41
+
42
+ # Converts the object that was supplied to a criteria and converts it
43
+ # into a database friendly form.
44
+ def evolve(object)
45
+ case object
46
+ when QDM::Ratio then object.mongoize
47
+ else object
48
+ end
49
+ end
50
+ end
51
+ end
52
+ end
@@ -7,7 +7,7 @@ module QDM
7
7
  embeds_many :relatedTo, class_name: 'QDM::Id'
8
8
  field :targetOutcome
9
9
  field :hqmfOid, type: String, default: '2.16.840.1.113883.10.20.28.3.7'
10
- field :category, type: String, default: 'care_goal'
11
- field :qdmVersion, type: String, default: '5.3'
10
+ field :qdmCategory, type: String, default: 'care_goal'
11
+ field :qdmVersion, type: String, default: '5.4'
12
12
  end
13
13
  end
@@ -0,0 +1,19 @@
1
+ module QDM
2
+ # app/models/qdm/communication_performed.rb
3
+ class CommunicationPerformed < DataElement
4
+ include Mongoid::Document
5
+ embedded_in :patient
6
+ field :authorDatetime, type: DateTime
7
+ field :category, type: QDM::Code
8
+ field :medium, type: QDM::Code
9
+ field :sender, type: QDM::Code
10
+ field :recipient, type: QDM::Code
11
+ embeds_many :relatedTo, class_name: 'QDM::Id'
12
+ field :relevantPeriod, type: QDM::Interval
13
+ field :negationRationale, type: QDM::Code
14
+ field :hqmfOid, type: String, default: '2.16.840.1.113883.10.20.28.4.132'
15
+ field :qdmCategory, type: String, default: 'communication'
16
+ field :qdmStatus, type: String, default: 'performed'
17
+ field :qdmVersion, type: String, default: '5.4'
18
+ end
19
+ end
@@ -4,6 +4,6 @@ module QDM
4
4
  include Mongoid::Document
5
5
  field :code, type: QDM::Code
6
6
  field :result
7
- field :qdmVersion, type: String, default: '5.3'
7
+ field :qdmVersion, type: String, default: '5.4'
8
8
  end
9
9
  end
@@ -8,10 +8,9 @@ module QDM
8
8
  field :negationRationale, type: QDM::Code
9
9
  field :reason, type: QDM::Code
10
10
  field :anatomicalLocationSite, type: QDM::Code
11
- field :anatomicalApproachSite, type: QDM::Code
12
11
  field :hqmfOid, type: String, default: '2.16.840.1.113883.10.20.28.3.13'
13
- field :category, type: String, default: 'device'
12
+ field :qdmCategory, type: String, default: 'device'
14
13
  field :qdmStatus, type: String, default: 'applied'
15
- field :qdmVersion, type: String, default: '5.3'
14
+ field :qdmVersion, type: String, default: '5.4'
16
15
  end
17
16
  end
@@ -7,8 +7,8 @@ module QDM
7
7
  field :negationRationale, type: QDM::Code
8
8
  field :reason, type: QDM::Code
9
9
  field :hqmfOid, type: String, default: '2.16.840.1.113883.10.20.28.3.15'
10
- field :category, type: String, default: 'device'
10
+ field :qdmCategory, type: String, default: 'device'
11
11
  field :qdmStatus, type: String, default: 'order'
12
- field :qdmVersion, type: String, default: '5.3'
12
+ field :qdmVersion, type: String, default: '5.4'
13
13
  end
14
14
  end
@@ -7,8 +7,8 @@ module QDM
7
7
  field :negationRationale, type: QDM::Code
8
8
  field :reason, type: QDM::Code
9
9
  field :hqmfOid, type: String, default: '2.16.840.1.113883.10.20.28.3.16'
10
- field :category, type: String, default: 'device'
10
+ field :qdmCategory, type: String, default: 'device'
11
11
  field :qdmStatus, type: String, default: 'recommended'
12
- field :qdmVersion, type: String, default: '5.3'
12
+ field :qdmVersion, type: String, default: '5.4'
13
13
  end
14
14
  end
@@ -9,7 +9,7 @@ module QDM
9
9
  field :severity, type: QDM::Code
10
10
  field :hqmfOid, type: String, default: '2.16.840.1.113883.10.20.28.3.110'
11
11
  field :qrdaOid, type: String, default: '2.16.840.1.113883.10.20.24.3.135'
12
- field :category, type: String, default: 'condition'
13
- field :qdmVersion, type: String, default: '5.3'
12
+ field :qdmCategory, type: String, default: 'condition'
13
+ field :qdmVersion, type: String, default: '5.4'
14
14
  end
15
15
  end
@@ -5,11 +5,10 @@ module QDM
5
5
  embedded_in :patient
6
6
  field :authorDatetime, type: DateTime
7
7
  field :reason, type: QDM::Code
8
- field :method, type: QDM::Code
9
8
  field :negationRationale, type: QDM::Code
10
9
  field :hqmfOid, type: String, default: '2.16.840.1.113883.10.20.28.3.22'
11
- field :category, type: String, default: 'diagnostic_study'
10
+ field :qdmCategory, type: String, default: 'diagnostic_study'
12
11
  field :qdmStatus, type: String, default: 'order'
13
- field :qdmVersion, type: String, default: '5.3'
12
+ field :qdmVersion, type: String, default: '5.4'
14
13
  end
15
14
  end
@@ -14,8 +14,8 @@ module QDM
14
14
  field :negationRationale, type: QDM::Code
15
15
  field :components, type: Array
16
16
  field :hqmfOid, type: String, default: '2.16.840.1.113883.10.20.28.3.23'
17
- field :category, type: String, default: 'diagnostic_study'
17
+ field :qdmCategory, type: String, default: 'diagnostic_study'
18
18
  field :qdmStatus, type: String, default: 'performed'
19
- field :qdmVersion, type: String, default: '5.3'
19
+ field :qdmVersion, type: String, default: '5.4'
20
20
  end
21
21
  end
@@ -4,12 +4,11 @@ module QDM
4
4
  include Mongoid::Document
5
5
  embedded_in :patient
6
6
  field :authorDatetime, type: DateTime
7
- field :method, type: QDM::Code
8
7
  field :negationRationale, type: QDM::Code
9
8
  field :hqmfOid, type: String, default: '2.16.840.1.113883.10.20.28.3.24'
10
9
  field :qrdaOid, type: String, default: '2.16.840.1.113883.10.20.24.3.19'
11
- field :category, type: String, default: 'diagnostic_study'
10
+ field :qdmCategory, type: String, default: 'diagnostic_study'
12
11
  field :qdmStatus, type: String, default: 'recommended'
13
- field :qdmVersion, type: String, default: '5.3'
12
+ field :qdmVersion, type: String, default: '5.4'
14
13
  end
15
14
  end
@@ -8,8 +8,8 @@ module QDM
8
8
  field :facilityLocation, type: QDM::Code
9
9
  field :negationRationale, type: QDM::Code
10
10
  field :hqmfOid, type: String, default: '2.16.840.1.113883.10.20.28.3.27'
11
- field :category, type: String, default: 'encounter'
11
+ field :qdmCategory, type: String, default: 'encounter'
12
12
  field :qdmStatus, type: String, default: 'order'
13
- field :qdmVersion, type: String, default: '5.3'
13
+ field :qdmVersion, type: String, default: '5.4'
14
14
  end
15
15
  end
@@ -13,8 +13,8 @@ module QDM
13
13
  field :negationRationale, type: QDM::Code
14
14
  field :lengthOfStay, type: QDM::Quantity
15
15
  field :hqmfOid, type: String, default: '2.16.840.1.113883.10.20.28.3.5'
16
- field :category, type: String, default: 'encounter'
16
+ field :qdmCategory, type: String, default: 'encounter'
17
17
  field :qdmStatus, type: String, default: 'performed'
18
- field :qdmVersion, type: String, default: '5.3'
18
+ field :qdmVersion, type: String, default: '5.4'
19
19
  end
20
20
  end