cqm-reports 4.1.0 → 4.1.2

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: b0938369271d07282db5933dda15b47f0cbe346abbeff4a6004a23fcce61e680
4
- data.tar.gz: 4ff25f7dfda32510cccb638966ab51eb76cb04c7ab31778fb2e95bc0cba88a2c
3
+ metadata.gz: c84889c53f81e1413f131f6a7ef1828151342b1375fbafe5c7aabf0c0954e001
4
+ data.tar.gz: 17fdb0f2fe5037320b8861b80038127dbd3899bd55300a088a3de2b7b9573a5d
5
5
  SHA512:
6
- metadata.gz: 3c3c6bd90513f5f83610596a4789a30b0995569efcf7e6598a48f385a00d7cc869265c4f7f6b77c24c3130153df714ad3858d55e4b97f88168282d833e4a2961
7
- data.tar.gz: 750f9df81d0cb2c633dbecc2b6be45a77c580dd7bc53defe6cc27ad592e0588cbebd563f3382e7d193f2cfcdf038728f3e01eee1f9fdbb2fc07e3a11f049afdb
6
+ metadata.gz: 9d672b492f6f4c9d7bd3f2db62f126df717632b81d15c15f29b4c875151eb0f95c2a5df0b9156e099ba49b6ed44e8f0282bf0696800b5bec37a12682efb2db30
7
+ data.tar.gz: c6deea05526b3ce0ede6c02f2203fbabc7f42c46685563e0f8d8f895f3ccb191304aed021abb3b8b0157d7bb6ea6d991ff7705a12d70ae0060fbb85b4038b44e
data/Gemfile CHANGED
@@ -6,7 +6,7 @@ gem 'protected_attributes_continued'
6
6
 
7
7
  group :development, :test do
8
8
  gem 'bundler-audit'
9
- gem 'rubocop', '~> 0.52.1', require: false
9
+ gem 'rubocop', '~> 0.93.0', require: false
10
10
  end
11
11
 
12
12
  group :development do
@@ -16,11 +16,11 @@ end
16
16
 
17
17
  group :test do
18
18
  gem 'cqm-models', '~> 4.0'
19
- gem 'factory_girl', '~> 4.1.0'
20
19
  gem 'tailor', '~> 1.1.2'
21
20
  gem 'cane', '~> 2.3.0'
22
21
  gem 'codecov'
23
22
  gem 'simplecov', :require => false
23
+ gem 'simplecov-cobertura'
24
24
  gem 'webmock'
25
25
  gem 'minitest', '~> 5.3'
26
26
  gem 'minitest-reporters'
@@ -3,7 +3,7 @@
3
3
  <head>
4
4
  <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
5
5
  {{#patient}}
6
- <title>Cypress Certification Patient Test Record: {{given_name}} {{familyName}}</title>
6
+ <title>Patient Test Record: {{given_name}} {{familyName}}</title>
7
7
  {{/patient}}
8
8
  {{#include_style?}}
9
9
  {{> _header_css}}
@@ -11,7 +11,7 @@
11
11
  </head>
12
12
  <body>
13
13
  {{#patient}}
14
- <h1 class="h1center">Cypress Certification Patient Test Record: {{given_name}} {{familyName}}</h1>
14
+ <h1 class="h1center">Patient Test Record: {{given_name}} {{familyName}}</h1>
15
15
  <div class="div-table">
16
16
  <div class="div-table-body">
17
17
  <div class="div-head-row patient_narr_tr panel panel-default patient-details">
@@ -36,7 +36,7 @@
36
36
  <div class="div-table-head patient_narr_th panel-heading"><span class="td_label">Insurance Providers</span></div>
37
37
  <div class="div-table-head">{{{payer}}}{{#demographic_code_description}}payer{{/demographic_code_description}}</div>
38
38
  <div class="div-table-head patient_narr_th panel-heading"><span class="td_label">Patient IDs</span></div>
39
- <div class="div-table-head">{{{mrn}}} Cypress</div>
39
+ <div class="div-table-head">{{{mrn}}}</div>
40
40
  </div>
41
41
  <div class="div-head-row patient_narr_tr panel panel-default patient-details">
42
42
  <div class="div-table-head patient_narr_th panel-heading"><span class="td_label">Address</span></div>
@@ -22,6 +22,11 @@ class Qrda1R5 < Mustache
22
22
  @submission_program = options[:submission_program]
23
23
  @medicare_beneficiary_identifier = options[:medicare_beneficiary_identifier]
24
24
  @hicn = options[:hicn]
25
+ @authoring_system = options[:authoring_system]
26
+ end
27
+
28
+ def authoring_system
29
+ @authoring_system || 'TestSystem'
25
30
  end
26
31
 
27
32
  def patient_addresses
@@ -19,8 +19,8 @@
19
19
  </addr>
20
20
  <telecom use="WP" value="tel:(781)271-3000"/>
21
21
  <assignedAuthoringDevice>
22
- <manufacturerModelName>Cypress</manufacturerModelName>
23
- <softwareName>Cypress</softwareName>
22
+ <manufacturerModelName>{{authoring_system}}</manufacturerModelName>
23
+ <softwareName>{{authoring_system}}</softwareName>
24
24
  </assignedAuthoringDevice>
25
25
  </assignedAuthor>
26
26
  </author>
@@ -8,7 +8,7 @@
8
8
  {{^provider_ccn}}
9
9
  <id extension="800890" root="2.16.840.1.113883.4.336"/>
10
10
  {{/provider_ccn}}
11
- <name>Cypress Test Deck</name>
11
+ <name>{{authoring_system}} Test Deck</name>
12
12
  <telecom use="WP" value="tel:(781)271-3000"/>
13
13
  {{#addresses}}
14
14
  <addr use="HP">
@@ -28,7 +28,7 @@
28
28
  <assignedCustodian>
29
29
  <representedCustodianOrganization>
30
30
  <id extension="800890" root="2.16.840.1.113883.4.336"/>
31
- <name>Cypress Test Deck</name>
31
+ <name>{{authoring_system}} Test Deck</name>
32
32
  <telecom use="WP" value="tel:(781)271-3000"/>
33
33
  <addr>
34
34
  <streetAddressLine>202 Burlington Rd.</streetAddressLine>
@@ -19,7 +19,7 @@
19
19
  </assignedPerson>
20
20
  <representedOrganization>
21
21
  <id root="2.16.840.1.113883.19.5"/>
22
- <name>Cypress</name>
22
+ <name>{{authoring_system}}</name>
23
23
  </representedOrganization>
24
24
  </assignedEntity>
25
25
  </legalAuthenticator>
@@ -3,7 +3,6 @@
3
3
  <!-- Encounter Diagnosis QDM -->
4
4
  <templateId extension="2021-08-01" root="2.16.840.1.113883.10.20.24.3.168"/>
5
5
  <code code="29308-4" codeSystem="2.16.840.1.113883.6.1"/>
6
- <statusCode code="completed"/>
7
6
  {{#code}}
8
7
  <value {{> _code}} xsi:type="CD"/>
9
8
  {{/code}}
@@ -18,7 +18,7 @@
18
18
  </addr>
19
19
  <telecom use="WP" value="tel:(781)271-3000"/>
20
20
  <playingEntity classCode="PLC">
21
- <name>Cypress Test Deck</name>
21
+ <name>{{authoring_system}} Test Deck</name>
22
22
  </playingEntity>
23
23
  </participantRole>
24
24
  </participant>
@@ -3,8 +3,14 @@
3
3
  <typeId root="2.16.840.1.113883.1.3" extension="POCD_HD000040"/>
4
4
  <!-- US Realm Header Template Id -->
5
5
  <templateId root="2.16.840.1.113883.10.20.27.1.1" extension="2020-12-01"/>
6
+ {{#ry2025_submission?}}
7
+ <!-- QRDA Category III Report - CMS (V9) -->
8
+ <templateId root="2.16.840.1.113883.10.20.27.1.2" extension="2024-07-01"/>
9
+ {{/ry2025_submission?}}
10
+ {{^ry2025_submission?}}
6
11
  <!-- QRDA Category III Report - CMS (V7) -->
7
12
  <templateId root="2.16.840.1.113883.10.20.27.1.2" extension="2022-12-01"/>
13
+ {{/ry2025_submission?}}
8
14
  <!-- This is the globally unique identifier for this QRDA document -->
9
15
  <id root="{{random_id}}"/>
10
16
  <!-- QRDA III document type code -->
@@ -11,7 +11,7 @@
11
11
  <!-- QRDA Category III Measure Section template -->
12
12
  <templateId extension="2020-12-01" root="2.16.840.1.113883.10.20.27.2.1"/>
13
13
  <!-- QRDA Category III Measure Section - CMS (V4) -->
14
- <templateId extension="2019-05-01" root="2.16.840.1.113883.10.20.27.2.3"/>
14
+ <templateId extension="2022-05-01" root="2.16.840.1.113883.10.20.27.2.3"/>
15
15
  <code code="55186-1" codeSystem="2.16.840.1.113883.6.1"/>
16
16
  <title>Measure Section</title>
17
17
  <text>
@@ -41,7 +41,7 @@
41
41
  <templateId root="2.16.840.1.113883.10.20.24.3.98"/>
42
42
  <!-- SHALL 1..* (one for each referenced measure) Measure Reference and Results template -->
43
43
  <templateId extension="2020-12-01" root="2.16.840.1.113883.10.20.27.3.1"/>
44
- <templateId extension="2019-05-01" root="2.16.840.1.113883.10.20.27.3.17"/>
44
+ <templateId extension="2022-05-01" root="2.16.840.1.113883.10.20.27.3.17"/>
45
45
  <id extension="{{random_id}}" root="1.3.6.1.4.1.115"/>
46
46
  <statusCode code="completed"/>
47
47
  <!-- Containing isBranch external references -->
@@ -28,6 +28,8 @@ class Qrda3 < Mustache
28
28
  @performance_period_end = options[:end_time]
29
29
  @submission_program = options[:submission_program]
30
30
  @ry2022_submission = options[:ry2022_submission]
31
+ @ry2025_submission = options[:ry2025_submission]
32
+ @authoring_system = options[:authoring_system]
31
33
  end
32
34
 
33
35
  def agg_results(measure_id, cache_entries, population_sets)
@@ -92,6 +94,14 @@ class Qrda3 < Mustache
92
94
  @ry2022_submission
93
95
  end
94
96
 
97
+ def ry2025_submission?
98
+ @ry2025_submission
99
+ end
100
+
101
+ def authoring_system
102
+ @authoring_system || 'TestSystem'
103
+ end
104
+
95
105
  def payer_code?
96
106
  self['type'] == 'PAYER'
97
107
  end
@@ -1,7 +1,7 @@
1
1
  <author>
2
2
  <time value="{{current_time}}"/>
3
3
  <assignedAuthor>
4
- <!-- id extension="Cypress" root="2.16.840.1.113883.19.5"/ -->
4
+ <!-- id extension="{{authoring_system}}" root="2.16.840.1.113883.19.5"/ -->
5
5
  <!-- NPI -->
6
6
  <id extension="1982671962" root="2.16.840.1.113883.4.6"/>
7
7
  <addr>
@@ -13,8 +13,8 @@
13
13
  </addr>
14
14
  <telecom use="WP" value="tel:(781)271-3000"/>
15
15
  <assignedAuthoringDevice>
16
- <manufacturerModelName>Cypress</manufacturerModelName>
17
- <softwareName>Cypress</softwareName>
16
+ <manufacturerModelName>{{authoring_system}}</manufacturerModelName>
17
+ <softwareName>{{authoring_system}}</softwareName>
18
18
  </assignedAuthoringDevice>
19
19
  <representedOrganization>
20
20
  <!-- The organization id is optional, but the name is required -->
@@ -3,7 +3,7 @@
3
3
  <representedCustodianOrganization>
4
4
  <!-- HQR Only -->
5
5
  <id extension="800890" root="2.16.840.1.113883.4.336"/>
6
- <name>Cypress Test Deck</name>
6
+ <name>{{authoring_system}} Test Deck</name>
7
7
  <telecom use="WP" value="tel:(781)271-3000"/>
8
8
  <addr>
9
9
  <streetAddressLine>202 Burlington Rd.</streetAddressLine>
@@ -19,7 +19,7 @@
19
19
  </assignedPerson>
20
20
  <representedOrganization>
21
21
  <id root="2.16.840.1.113883.19.5"/>
22
- <name>Cypress</name>
22
+ <name>{{authoring_system}}</name>
23
23
  </representedOrganization>
24
24
  </assignedEntity>
25
25
  </legalAuthenticator>
@@ -3,23 +3,23 @@ module Qrda
3
3
  module Helper
4
4
  module PopulationSelectors
5
5
  def numerator
6
- populations.find {|pop| pop.type == 'NUMER'}
6
+ populations.find { |pop| pop.type == 'NUMER' }
7
7
  end
8
8
 
9
9
  def denominator
10
- populations.find {|pop| pop.type == 'DENOM'}
10
+ populations.find { |pop| pop.type == 'DENOM' }
11
11
  end
12
12
 
13
13
  def denominator_exceptions
14
- populations.find {|pop| pop.type == 'DENEXCEP'}
14
+ populations.find { |pop| pop.type == 'DENEXCEP' }
15
15
  end
16
16
 
17
17
  def denominator_exclusions
18
- populations.find {|pop| pop.type == 'DENEX'}
18
+ populations.find { |pop| pop.type == 'DENEX' }
19
19
  end
20
20
 
21
21
  def population_count(population_type, population_id)
22
- population = populations.find {|pop| pop.type == population_type && pop.id == population_id}
22
+ population = populations.find { |pop| pop.type == population_type && pop.id == population_id }
23
23
  if population
24
24
  population.value
25
25
  else
@@ -28,7 +28,7 @@ module Qrda
28
28
  end
29
29
 
30
30
  def population_id(population_type)
31
- populations.find {|pop| pop.type == population_type}.id
31
+ populations.find { |pop| pop.type == population_type }.id
32
32
  end
33
33
 
34
34
  def method_missing(method, *args, &block)
@@ -64,7 +64,7 @@ module Qrda
64
64
  end
65
65
 
66
66
  def add_stratification(id,value,observation)
67
- stratifications << Stratification.new(id,value,observation) unless stratifications.find {|st| st.id == id}
67
+ stratifications << Stratification.new(id,value,observation) unless stratifications.find { |st| st.id == id }
68
68
  end
69
69
 
70
70
  end
@@ -91,7 +91,7 @@ module Qrda
91
91
  end
92
92
 
93
93
  def is_cv?
94
- populations.any? {|pop| pop.type == 'MSRPOPL'}
94
+ populations.any? { |pop| pop.type == 'MSRPOPL' }
95
95
  end
96
96
 
97
97
  end
@@ -123,7 +123,7 @@ module Qrda
123
123
  end
124
124
  entry_populations << population if population
125
125
  end
126
- return if population_groups.find {|pg| pg.populations.collect(&:id).compact.sort == entry_populations.collect(&:id).compact.sort }
126
+ return if population_groups.find { |pg| pg.populations.collect(&:id).compact.sort == entry_populations.collect(&:id).compact.sort }
127
127
 
128
128
  pg = PopulationGroup.new
129
129
  pg.populations = entry_populations
@@ -142,7 +142,7 @@ module Qrda
142
142
  end
143
143
 
144
144
  def is_cv?
145
- populations.any? {|pop| pop.type == 'MSRPOPL'}
145
+ populations.any? { |pop| pop.type == 'MSRPOPL' }
146
146
  end
147
147
  end
148
148
  end
@@ -81,7 +81,8 @@ module QRDA
81
81
  next unless translation_code
82
82
 
83
83
  code_list << translation_code
84
- @warnings << ValidationError.new(message: "Translation code #{translation_code.system}:#{translation_code.code} may not be used for eCQM calculation by a receiving system. Ensure that the root code includes a code from the eCQM valueset.",
84
+ root_code_string = "#{code_list[0].system}:#{code_list[0].code}"
85
+ @warnings << ValidationError.new(message: "Translation code #{translation_code.system}:#{translation_code.code} may not be used for eCQM calculation by a receiving system. Ensure that the root code #{root_code_string} is from an eCQM valueset.",
85
86
  location: coded_element.path)
86
87
  end
87
88
  end
@@ -3,7 +3,7 @@ module HQMF
3
3
  # General helpers for working with codes and code systems
4
4
  class HQMFTemplateHelper
5
5
 
6
- def self.definition_for_template_id(template_id, version="r1")
6
+ def self.definition_for_template_id(template_id, version = "r1")
7
7
  template_id_map(version)[template_id]
8
8
  end
9
9
 
@@ -18,14 +18,14 @@ module HQMF
18
18
  @id_map[version]
19
19
  end
20
20
 
21
- def self.template_id_by_definition_and_status(definition, status, negation=false, version="r1")
21
+ def self.template_id_by_definition_and_status(definition, status, negation, version)
22
22
  case version
23
23
  when "r1"
24
- kv_pair = template_id_map(version).find {|k, v| v['definition'] == definition &&
24
+ kv_pair = template_id_map(version).find { |k, v| v['definition'] == definition &&
25
25
  v['status'] == status &&
26
26
  v['negation'] == negation}
27
27
  when "r2", "r2cql"
28
- kv_pair = template_id_map(version).find {|k, v| v['definition'] == definition &&
28
+ kv_pair = template_id_map(version).find { |k, v| v['definition'] == definition &&
29
29
  v['status'] == status}
30
30
  end
31
31
  if kv_pair
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: cqm-reports
3
3
  version: !ruby/object:Gem::Version
4
- version: 4.1.0
4
+ version: 4.1.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - The MITRE Corporation
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2023-11-01 00:00:00.000000000 Z
11
+ date: 2024-07-26 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: cqm-models
@@ -86,20 +86,14 @@ dependencies:
86
86
  requirements:
87
87
  - - ">="
88
88
  - !ruby/object:Gem::Version
89
- version: 1.8.5
90
- - - "<"
91
- - !ruby/object:Gem::Version
92
- version: 1.15.0
89
+ version: 1.16.2
93
90
  type: :runtime
94
91
  prerelease: false
95
92
  version_requirements: !ruby/object:Gem::Requirement
96
93
  requirements:
97
94
  - - ">="
98
95
  - !ruby/object:Gem::Version
99
- version: 1.8.5
100
- - - "<"
101
- - !ruby/object:Gem::Version
102
- version: 1.15.0
96
+ version: 1.16.2
103
97
  - !ruby/object:Gem::Dependency
104
98
  name: uuid
105
99
  requirement: !ruby/object:Gem::Requirement
@@ -263,11 +257,6 @@ files:
263
257
  - lib/qrda-export/catI-r5/qrda_templates/template_partials/_results.mustache
264
258
  - lib/qrda-export/catI-r5/qrda_templates/template_partials/_severity.mustache
265
259
  - lib/qrda-export/catI-r5/qrda_templates/template_partials/_status.mustache
266
- - lib/qrda-export/catI-r52/qrda1_r52.rb
267
- - lib/qrda-export/catI-r52/qrda_header/_participant.mustache
268
- - lib/qrda-export/catI-r52/qrda_header/_record_target.mustache
269
- - lib/qrda-export/catI-r52/qrda_templates/medication_order.mustache
270
- - lib/qrda-export/catIII-r2-1/qrda_header/_participant_ehr.mustache
271
260
  - lib/qrda-export/catIII/_continuous_variable_value.mustache
272
261
  - lib/qrda-export/catIII/_header.mustache
273
262
  - lib/qrda-export/catIII/_measure_data.mustache
@@ -1,258 +0,0 @@
1
- require 'mustache'
2
- class Qrda1R52 < Mustache
3
- include Qrda::Export::Helper::DateHelper
4
- include Qrda::Export::Helper::ViewHelper
5
- include Qrda::Export::Helper::Cat1ViewHelper
6
- include Qrda::Export::Helper::PatientViewHelper
7
- include Qrda::Export::Helper::FrequencyHelper
8
- include HQMF::Util::EntityHelper
9
-
10
- self.template_path = __dir__
11
-
12
- def initialize(patient, measures, options = {})
13
- @patient = patient
14
- @qdmPatient = patient.qdmPatient
15
- @measures = measures
16
- @provider = options[:provider]
17
- @patient_address_option = options[:patient_addresses]
18
- @patient_telecom_option = options[:patient_telecoms]
19
- @patient_email_option = options[:patient_email]
20
- @performance_period_start = options[:start_time]
21
- @performance_period_end = options[:end_time]
22
- @submission_program = options[:submission_program]
23
- @medicare_beneficiary_identifier = options[:medicare_beneficiary_identifier]
24
- end
25
-
26
- def patient_addresses
27
- @patient_address_option ||= [CQM::Address.new(
28
- use: 'HP',
29
- street: ['202 Burlington Rd.'],
30
- city: 'Bedford',
31
- state: 'MA',
32
- zip: '01730',
33
- country: 'US'
34
- )]
35
- JSON.parse(@patient_address_option.to_json)
36
- end
37
-
38
- def patient_telecoms
39
- @patient_telecom_option ||= [CQM::Telecom.new(
40
- use: 'HP',
41
- value: '555-555-2003'
42
- )]
43
- JSON.parse(@patient_telecom_option.to_json)
44
- end
45
-
46
- def patient_email
47
- return unless @patient_email_option
48
- telecom_email = [CQM::Telecom.new(
49
- use: 'HP',
50
- value: @patient_email_option
51
- )]
52
- JSON.parse(telecom_email.to_json)
53
- end
54
-
55
- def patient_characteristic_payer
56
- JSON.parse(@qdmPatient.get_data_elements('patient_characteristic', 'payer').to_json)
57
- end
58
-
59
- def patient_characteristic_birthdate
60
- JSON.parse(@qdmPatient.get_data_elements('patient_characteristic', 'birthdate').to_json)
61
- end
62
-
63
- def patient_characteristic_sex
64
- JSON.parse(@qdmPatient.get_data_elements('patient_characteristic', 'gender').to_json)
65
- end
66
-
67
- def patient_characteristic_race
68
- JSON.parse(@qdmPatient.get_data_elements('patient_characteristic', 'race').to_json)
69
- end
70
-
71
- def patient_characteristic_ethnicity
72
- JSON.parse(@qdmPatient.get_data_elements('patient_characteristic', 'ethnicity').to_json)
73
- end
74
-
75
- def adverse_event
76
- JSON.parse(@qdmPatient.get_data_elements('adverse_event', nil).to_json)
77
- end
78
-
79
- def allergy_intolerance
80
- JSON.parse(@qdmPatient.get_data_elements('allergy', 'intolerance').to_json)
81
- end
82
-
83
- def assessment_order
84
- JSON.parse(@qdmPatient.get_data_elements('assessment', 'order').to_json)
85
- end
86
-
87
- def assessment_performed
88
- JSON.parse(@qdmPatient.get_data_elements('assessment', 'performed').to_json)
89
- end
90
-
91
- def assessment_recommended
92
- JSON.parse(@qdmPatient.get_data_elements('assessment', 'recommended').to_json)
93
- end
94
-
95
- def communication_performed
96
- JSON.parse(@qdmPatient.get_data_elements('communication', 'performed').to_json)
97
- end
98
-
99
- def diagnosis
100
- JSON.parse(@qdmPatient.get_data_elements('condition', nil).to_json)
101
- end
102
-
103
- def device_applied
104
- JSON.parse(@qdmPatient.get_data_elements('device', 'applied').to_json)
105
- end
106
-
107
- def device_order
108
- JSON.parse(@qdmPatient.get_data_elements('device', 'order').to_json)
109
- end
110
-
111
- def device_recommended
112
- JSON.parse(@qdmPatient.get_data_elements('device', 'recommended').to_json)
113
- end
114
-
115
- def diagnostic_study_order
116
- JSON.parse(@qdmPatient.get_data_elements('diagnostic_study', 'order').to_json)
117
- end
118
-
119
- def diagnostic_study_performed
120
- JSON.parse(@qdmPatient.get_data_elements('diagnostic_study', 'performed').to_json)
121
- end
122
-
123
- def diagnostic_study_recommended
124
- JSON.parse(@qdmPatient.get_data_elements('diagnostic_study', 'recommended').to_json)
125
- end
126
-
127
- def encounter_order
128
- JSON.parse(@qdmPatient.get_data_elements('encounter', 'order').to_json)
129
- end
130
-
131
- def encounter_performed
132
- JSON.parse(@qdmPatient.get_data_elements('encounter', 'performed').to_json)
133
- end
134
-
135
- def encounter_recommended
136
- JSON.parse(@qdmPatient.get_data_elements('encounter', 'recommended').to_json)
137
- end
138
-
139
- def family_history
140
- JSON.parse(@qdmPatient.get_data_elements('family_history', nil).to_json)
141
- end
142
-
143
- def immunization_administered
144
- JSON.parse(@qdmPatient.get_data_elements('immunization', 'administered').to_json)
145
- end
146
-
147
- def immunization_order
148
- JSON.parse(@qdmPatient.get_data_elements('immunization', 'order').to_json)
149
- end
150
-
151
- def intervention_order
152
- JSON.parse(@qdmPatient.get_data_elements('intervention', 'order').to_json)
153
- end
154
-
155
- def intervention_performed
156
- JSON.parse(@qdmPatient.get_data_elements('intervention', 'performed').to_json)
157
- end
158
-
159
- def intervention_recommended
160
- JSON.parse(@qdmPatient.get_data_elements('intervention', 'recommended').to_json)
161
- end
162
-
163
- def laboratory_test_order
164
- JSON.parse(@qdmPatient.get_data_elements('laboratory_test', 'order').to_json)
165
- end
166
-
167
- def laboratory_test_performed
168
- JSON.parse(@qdmPatient.get_data_elements('laboratory_test', 'performed').to_json)
169
- end
170
-
171
- def laboratory_test_recommended
172
- JSON.parse(@qdmPatient.get_data_elements('laboratory_test', 'recommended').to_json)
173
- end
174
-
175
- def medication_active
176
- JSON.parse(@qdmPatient.get_data_elements('medication', 'active').to_json)
177
- end
178
-
179
- def medication_administered
180
- JSON.parse(@qdmPatient.get_data_elements('medication', 'administered').to_json) + JSON.parse(@qdmPatient.get_data_elements('substance', 'administered').to_json)
181
- end
182
-
183
- def medication_discharge
184
- JSON.parse(@qdmPatient.get_data_elements('medication', 'discharge').to_json)
185
- end
186
-
187
- def medication_dispensed
188
- JSON.parse(@qdmPatient.get_data_elements('medication', 'dispensed').to_json)
189
- end
190
-
191
- def medication_order
192
- JSON.parse(@qdmPatient.get_data_elements('medication', 'order').to_json)
193
- end
194
-
195
- def patient_care_experience
196
- JSON.parse(@qdmPatient.dataElements.where(hqmfOid: { '$in' => HQMF::Util::HQMFTemplateHelper.get_all_hqmf_oids('patient_care_experience', '') }).to_json)
197
- end
198
-
199
- def patient_characteristic_clinical_trial_participant
200
- JSON.parse(@qdmPatient.get_data_elements('patient_characteristic', 'clinical_trial_participant').to_json)
201
- end
202
-
203
- def patient_characteristic_expired
204
- JSON.parse(@qdmPatient.get_data_elements('patient_characteristic', 'expired').to_json)
205
- end
206
-
207
- def physical_exam_order
208
- JSON.parse(@qdmPatient.get_data_elements('physical_exam', 'order').to_json)
209
- end
210
-
211
- def physical_exam_performed
212
- JSON.parse(@qdmPatient.get_data_elements('physical_exam', 'performed').to_json)
213
- end
214
-
215
- def physical_exam_recommended
216
- JSON.parse(@qdmPatient.get_data_elements('physical_exam', 'recommended').to_json)
217
- end
218
-
219
- def procedure_order
220
- JSON.parse(@qdmPatient.get_data_elements('procedure', 'order').to_json)
221
- end
222
-
223
- def procedure_performed
224
- JSON.parse(@qdmPatient.get_data_elements('procedure', 'performed').to_json)
225
- end
226
-
227
- def procedure_recommended
228
- JSON.parse(@qdmPatient.get_data_elements('procedure', 'recommended').to_json)
229
- end
230
-
231
- def program_participation
232
- JSON.parse(@qdmPatient.get_data_elements('participation', nil).to_json)
233
- end
234
-
235
- def provider_care_experience
236
- JSON.parse(@qdmPatient.dataElements.where(hqmfOid: { '$in' => HQMF::Util::HQMFTemplateHelper.get_all_hqmf_oids('provider_care_experience', '') }).to_json)
237
- end
238
-
239
- def related_person
240
- JSON.parse(@qdmPatient.get_data_elements('related_person', nil).to_json)
241
- end
242
-
243
- def substance_administered
244
- JSON.parse(@qdmPatient.get_data_elements('substance', 'administered').to_json)
245
- end
246
-
247
- def substance_order
248
- JSON.parse(@qdmPatient.get_data_elements('substance', 'order').to_json)
249
- end
250
-
251
- def substance_recommended
252
- JSON.parse(@qdmPatient.get_data_elements('substance', 'recommended').to_json)
253
- end
254
-
255
- def symptom
256
- JSON.parse(@qdmPatient.get_data_elements('symptom', nil).to_json)
257
- end
258
- end
@@ -1,8 +0,0 @@
1
- <participant typeCode="DEV">
2
- <associatedEntity classCode="RGPR">
3
- <!-- CMS EHR Certification Number (formerly known as Office of the
4
- National Coordinator Certification Number). Note, this is a test
5
- file, and the provided ID is not for a certified product set. -->
6
- <id extension="0015CPV4ZTB4WBU" root="2.16.840.1.113883.3.2074.1"/>
7
- </associatedEntity>
8
- </participant>
@@ -1,65 +0,0 @@
1
- <recordTarget>
2
- <patientRole>
3
- <id extension="{{mrn}}" root="1.3.6.1.4.1.115" />
4
- {{#medicare_beneficiary_identifier}}
5
- <id extension="{{medicare_beneficiary_identifier}}" root="2.16.840.1.113883.4.927" />
6
- {{/medicare_beneficiary_identifier}}
7
- {{#patient_addresses}}
8
- <addr use="{{use}}">
9
- {{#street}}
10
- <streetAddressLine>{{.}}</streetAddressLine>
11
- {{/street}}
12
- <city>{{city}}</city>
13
- <state>{{state}}</state>
14
- <postalCode>{{zip}}</postalCode>
15
- <country>{{country}}</country>
16
- </addr>
17
- {{/patient_addresses}}
18
- {{#patient_telecoms}}
19
- <telecom use="{{use}}" value="tel:{{value}}"/>
20
- {{/patient_telecoms}}
21
- {{#patient_email}}
22
- <telecom use="{{use}}" value="mailto:{{value}}"/>
23
- {{/patient_email}}
24
- <patient>
25
- {{#patient}}
26
- <name>
27
- <given>{{given_name}}</given>
28
- <family>{{familyName}}</family>
29
- </name>
30
- {{/patient}}
31
- {{#patient_characteristic_sex}}
32
- {{#dataElementCodes}}
33
- <administrativeGenderCode {{> _code}}/>
34
- {{/dataElementCodes}}
35
- {{/patient_characteristic_sex}}
36
- {{^patient_characteristic_sex}}
37
- <administrativeGenderCode nullFlavor="UNK"/>
38
- {{/patient_characteristic_sex}}
39
- {{#patient_characteristic_birthdate}}
40
- {{{birth_date_time}}}
41
- {{/patient_characteristic_birthdate}}
42
- {{#patient_characteristic_race}}
43
- {{#dataElementCodes}}
44
- <raceCode {{> _code}}/>
45
- {{/dataElementCodes}}
46
- {{/patient_characteristic_race}}
47
- {{^patient_characteristic_race}}
48
- <raceCode nullFlavor="UNK"/>
49
- {{/patient_characteristic_race}}
50
- {{#patient_characteristic_ethnicity}}
51
- {{#dataElementCodes}}
52
- <ethnicGroupCode {{> _code}}/>
53
- {{/dataElementCodes}}
54
- {{/patient_characteristic_ethnicity}}
55
- {{^patient_characteristic_ethnicity}}
56
- <ethnicGroupCode nullFlavor="UNK"/>
57
- {{/patient_characteristic_ethnicity}}
58
- <languageCommunication>
59
- <templateId root="2.16.840.1.113883.3.88.11.83.2" assigningAuthorityName="HITSP/C83"/>
60
- <templateId root="1.3.6.1.4.1.19376.1.5.3.1.2.1" assigningAuthorityName="IHE/PCC"/>
61
- <languageCode code="eng"/>
62
- </languageCommunication>
63
- </patient>
64
- </patientRole>
65
- </recordTarget>
@@ -1,70 +0,0 @@
1
- <entry>
2
- <!--Medication Order -->
3
- <substanceAdministration classCode="SBADM" moodCode="RQO" {{{negation_ind}}}>
4
- <templateId root="2.16.840.1.113883.10.20.22.4.42" extension="2014-06-09"/>
5
- <!-- Medication, Order template -->
6
- <templateId root="2.16.840.1.113883.10.20.24.3.47" extension="2019-12-01"/>
7
- <id root="1.3.6.1.4.1.115" extension="{{object_id}}"/>
8
- <text>{{description}}</text>
9
- <statusCode code="active"/>
10
- {{#relevantPeriod}}
11
- <!-- QDM Attribute: Relevant Period -->
12
- {{{medication_duration_effective_time}}}
13
- {{/relevantPeriod}}
14
- {{^relevantPeriod}}
15
- {{#authorDatetime}}
16
- <!-- QDM Attribute: Relevant Period -->
17
- {{{medication_duration_author_effective_time}}}
18
- {{/authorDatetime}}
19
- {{/relevantPeriod}}
20
- {{> qrda_templates/template_partials/_medication_details}}
21
- <consumable>
22
- <manufacturedProduct classCode="MANU">
23
- <!-- Medication Information (consolidation) template -->
24
- <templateId root="2.16.840.1.113883.10.20.22.4.23" extension="2014-06-09"/>
25
- <id root="{{random_id}}"/>
26
- <manufacturedMaterial>
27
- <!-- QDM Attribute: Code -->
28
- {{> _codes}}
29
- </manufacturedMaterial>
30
- </manufacturedProduct>
31
- </consumable>
32
- {{#authorDatetime}}
33
- <!-- QDM Attribute: Author dateTime -->
34
- {{> qrda_templates/template_partials/_author}}
35
- {{/authorDatetime}}
36
- {{#setting}}
37
- <participant typeCode="LOC">
38
- <participantRole>
39
- <!-- QDM Attribute: Setting -->
40
- <code {{> _code}}/>
41
- </participantRole>
42
- </participant>
43
- {{/setting}}
44
- {{#prescriber}}
45
- <!-- QDM Attribute: Prescriber -->
46
- <participant typeCode="PRF">
47
- {{> qrda_templates/template_partials/_entity}}
48
- </participant>
49
- {{/prescriber}}
50
- {{#reason}}
51
- <!-- QDM Attribute: Reason -->
52
- {{> qrda_templates/template_partials/_reason}}
53
- {{/reason}}
54
- {{#negationRationale}}
55
- <!-- QDM Attribute: Negation Rationale -->
56
- {{> qrda_templates/template_partials/_reason}}
57
- {{/negationRationale}}
58
- {{#daysSupplied}}
59
- <entryRelationship typeCode="REFR">
60
- {{> qrda_templates/template_partials/_days_supplied}}
61
- </entryRelationship>
62
- {{/daysSupplied}}
63
- {{#supply}}
64
- <!-- QDM Attribute: Supply -->
65
- <entryRelationship typeCode="COMP">
66
- {{> qrda_templates/template_partials/_medication_supply_request}}
67
- </entryRelationship>
68
- {{/supply}}
69
- </substanceAdministration>
70
- </entry>
@@ -1,9 +0,0 @@
1
- <participant typeCode="DEV">
2
- <associatedEntity classCode="RGPR">
3
- <!-- CMS EHR Certification Number (formerly known as Office of the
4
- National Coordinator Certification Number). Note, this is a test
5
- file, and the provided ID is not for a certified product set. -->
6
- <id root="2.16.840.1.113883.3.2074.1" extension="0015CPV4ZTB4WBU"/>
7
- <code code="129465004" displayName="medical record, device" codeSystem="2.16.840.1.113883.6.96" codeSystemName="SNOMED-CT"/>
8
- </associatedEntity>
9
- </participant>