ruby-hl7-extensions 0.1.0 → 0.1.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/VERSION +1 -1
- data/VERSION.yml +1 -1
- data/lib/core_ext/segments/dg1.rb +16 -0
- data/lib/core_ext/segments/in1.rb +35 -0
- data/lib/segments/dg1.rb +31 -0
- data/ruby-hl7-extensions.gemspec +2 -3
- metadata +4 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: f38198718bb77f3662ab948656518093f1ef5aec
|
4
|
+
data.tar.gz: 6911f78b0d4cd3a7975a2dbfda7cea3de3cc5902
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 846029a167bd39045c4b28155ccf5388d45480af8478232af1e9c9e5454d5c2b4621af7bdde8aced385da5fb2b6339a0fc049186052019d4ec1c63bd297da02f
|
7
|
+
data.tar.gz: 902d77ae34cc0be36690264a5b94a06bb4c98327e1b42d044b26d03c55e2eed715db1c58f0df56c8f7b67162cdd9c646e27f3e3986628b3ca5a68adedf595d3a
|
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.1.
|
1
|
+
0.1.1
|
data/VERSION.yml
CHANGED
@@ -0,0 +1,35 @@
|
|
1
|
+
module Extensions
|
2
|
+
module HL7
|
3
|
+
module Segments
|
4
|
+
module IN1
|
5
|
+
|
6
|
+
def self.included base
|
7
|
+
base.send :include, InstanceMethods
|
8
|
+
base.extend ClassMethods
|
9
|
+
end
|
10
|
+
|
11
|
+
module InstanceMethods
|
12
|
+
def insurance_co
|
13
|
+
self.value_for_field("4")
|
14
|
+
end
|
15
|
+
|
16
|
+
def insurance_plan
|
17
|
+
self.value_for_field("2.2")
|
18
|
+
end
|
19
|
+
|
20
|
+
def insured_name
|
21
|
+
lname = self.value_for_field("16.1")
|
22
|
+
fname = self.value_for_field("16.2")
|
23
|
+
middle = self.value_for_field("16.3")
|
24
|
+
"#{lname}, #{fname} #{middle}"
|
25
|
+
end
|
26
|
+
|
27
|
+
def insured_address
|
28
|
+
address1, address2, city, state, zip = self.value_for_field("19").split(@item_delim)
|
29
|
+
"#{address1}#{address2.blank? ? "," : ", #{address2},"} #{city}, #{state}, #{zip}"
|
30
|
+
end
|
31
|
+
end
|
32
|
+
end
|
33
|
+
end
|
34
|
+
end
|
35
|
+
end
|
data/lib/segments/dg1.rb
ADDED
@@ -0,0 +1,31 @@
|
|
1
|
+
# encoding: UTF-8
|
2
|
+
require 'ruby-hl7'
|
3
|
+
|
4
|
+
class HL7::Message::Segment::DG1 < HL7::Message::Segment
|
5
|
+
weight 100
|
6
|
+
add_field :set_id
|
7
|
+
add_field :diagnosis_coding_method
|
8
|
+
add_field :diagnosis_code
|
9
|
+
add_field :diagnosis_description
|
10
|
+
add_field :diagnosis_date_time do |value|
|
11
|
+
convert_to_ts(value)
|
12
|
+
end
|
13
|
+
add_field :diagnosis_type
|
14
|
+
add_field :major_diagnostic_category
|
15
|
+
add_field :diagnostic_related_group
|
16
|
+
add_field :drg_approval_indicator
|
17
|
+
add_field :drg_grouper_review_code
|
18
|
+
add_field :outlier_type
|
19
|
+
add_field :outlier_days
|
20
|
+
add_field :outlier_cost
|
21
|
+
add_field :grouper_version_and_type
|
22
|
+
add_field :diagnosis_priority
|
23
|
+
add_field :diagnosing_clinician
|
24
|
+
add_field :diagnosis_classification
|
25
|
+
add_field :confidential_indicator
|
26
|
+
add_field :attestation_date_time do |value|
|
27
|
+
convert_to_ts(value)
|
28
|
+
end
|
29
|
+
add_field :diagnosis_identifier
|
30
|
+
add_field :diagnosis_action_code
|
31
|
+
end
|
data/ruby-hl7-extensions.gemspec
CHANGED
@@ -3,7 +3,7 @@
|
|
3
3
|
|
4
4
|
Gem::Specification.new do |s|
|
5
5
|
s.name = "ruby-hl7-extensions"
|
6
|
-
s.version = "0.1.
|
6
|
+
s.version = "0.1.1"
|
7
7
|
|
8
8
|
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
|
9
9
|
s.require_paths = ["lib"]
|
@@ -14,8 +14,7 @@ Gem::Specification.new do |s|
|
|
14
14
|
s.extra_rdoc_files = ["LICENSE", "README.md"]
|
15
15
|
s.files = [".gitignore", "Gemfile", "Gemfile.lock", "LICENSE", "README.md", "Rakefile", "VERSION", "VERSION.yml", "lib/core_ext/segments/rol.rb",
|
16
16
|
"lib/core_ext/message.rb", "lib/core_ext/segment.rb", "lib/core_ext/segments/err.rb", "lib/core_ext/segments/sft.rb",
|
17
|
-
"lib/core_ext/segments/msh.rb", "lib/core_ext/segments/nk1.rb", "lib/core_ext/segments/orc.rb", "lib/core_ext/segments/evn.rb", "lib/core_ext/segments/nte.rb", "lib/core_ext/segments/obr.rb",
|
18
|
-
"lib/ruby-hl7-extensions.rb", "ruby-hl7-extensions.gemspec"]
|
17
|
+
"lib/core_ext/segments/msh.rb", "lib/core_ext/segments/nk1.rb", "lib/core_ext/segments/orc.rb", "lib/core_ext/segments/evn.rb", "lib/core_ext/segments/nte.rb", "lib/core_ext/segments/obr.rb", "lib/core_ext/segments/obx.rb", "lib/core_ext/segments/pid.rb", "lib/core_ext/segments/pv1.rb", "lib/core_ext/segments/pd1.rb", "lib/core_ext/segments/segments.rb", "lib/core_ext/segments/dg1.rb", "lib/core_ext/segments/in1.rb", "lib/segments/dg1.rb", "lib/ruby-hl7-extensions.rb", "ruby-hl7-extensions.gemspec"]
|
19
18
|
s.homepage = "http://github.com/nmlynl/ruby-hl7-extensions"
|
20
19
|
s.rdoc_options = ["--charset=UTF-8"]
|
21
20
|
s.required_ruby_version = Gem::Requirement.new(">= 1.8.6")
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: ruby-hl7-extensions
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Nick Lega
|
@@ -56,8 +56,10 @@ files:
|
|
56
56
|
- VERSION.yml
|
57
57
|
- lib/core_ext/message.rb
|
58
58
|
- lib/core_ext/segment.rb
|
59
|
+
- lib/core_ext/segments/dg1.rb
|
59
60
|
- lib/core_ext/segments/err.rb
|
60
61
|
- lib/core_ext/segments/evn.rb
|
62
|
+
- lib/core_ext/segments/in1.rb
|
61
63
|
- lib/core_ext/segments/msh.rb
|
62
64
|
- lib/core_ext/segments/nk1.rb
|
63
65
|
- lib/core_ext/segments/nte.rb
|
@@ -71,6 +73,7 @@ files:
|
|
71
73
|
- lib/core_ext/segments/segments.rb
|
72
74
|
- lib/core_ext/segments/sft.rb
|
73
75
|
- lib/ruby-hl7-extensions.rb
|
76
|
+
- lib/segments/dg1.rb
|
74
77
|
- ruby-hl7-extensions.gemspec
|
75
78
|
homepage: http://github.com/nmlynl/ruby-hl7-extensions
|
76
79
|
licenses: []
|