Class: ChangeHealthcare::LabConfig

Inherits:
BaseApiObject show all
Defined in:
lib/change_healthcare/lab_config.rb

Overview

Class Method Summary collapse

Methods inherited from BaseApiObject

configuration, #initialize

Constructor Details

This class inherits a constructor from ChangeHealthcare::BaseApiObject

Class Method Details

.attributesObject



3
4
5
6
7
8
9
10
11
# File 'lib/change_healthcare/lab_config.rb', line 3

def self.attributes
  [
    :address_1, :address_2, :city, :configurable_item, :control_type,
    :control_width, :description, :domain_code_type, :is_required,
    :lab, :lab_code, :lab_name, :parent_level, :parentlab, :range,
    :sequence, :state, :transmission_mode, :validate, :validation,
    :value, :zip
  ]
end

.chc_object_nameObject



15
16
17
# File 'lib/change_healthcare/lab_config.rb', line 15

def self.chc_object_name
  "labcfg"
end

.configurable_itemsObject



26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
# File 'lib/change_healthcare/lab_config.rb', line 26

def self.configurable_items
  [
    "Max diagnoses per test",
    "Max diagnoses per requisition",
    "Show Report Comments",
    "Max tests per requisition",
    "Show Fasting Hours",
    "STAT Indicator",
    "Phone Results",
    "Copy To Functionality",
    "Max copy to per requisition",
    "Custom ABN Format",
    "Support Standard Requisitions",
    "Support PSC Requisitions",
    "Support Third Party Billing",
    "Support Client Billing",
    "Support Patient Billing"
  ]
end

.search(lab_id) ⇒ Object



20
21
22
23
24
# File 'lib/change_healthcare/lab_config.rb', line 20

def self.search(lab_id)
  params = configurable_items.map{|i| {lab: lab_id, configurable_item: i} }
  resp = call_api(__method__.to_s, params)
  response_to_list(resp)
end