2 require_once("ORDataObject.class.php");
3 require_once("InsuranceCompany.class.php");
6 * class InsuranceNumbers
10 class InsuranceNumbers
extends ORDataObject
{
14 var $insurance_company_name;
15 var $insurance_company_id;
17 var $rendering_provider_number;
19 var $provider_number_type;
20 var $provider_number_type_array = array ("" => "Unspecified", "0B" => "State License Number", "1A" => "Blue Cross Provider Number","1B" => "Blue Shield Provider Number","1C" => "Medicare Provider Number",
21 "1D" => "Medicaid Provider Number","1G" => "Provider UPIN Number","1H" => "Champus Identification Number","1J" => "Facility ID Number",
22 "B3" => "Preferred Provider Organization Number","BQ" => "Health Maintenance Organization Code Number","E1" => "Employer's Identification Number",
23 "FH" => "Clinic Number", "G2" => "Provider Commercial Number", "G5" => "Provider Site Number", "LU" => "Location Number", "SY" => "Social Security Number",
24 "U3" => "Unique Supplier Identification Number (USIN)", "X5" => "State Industrial Accident Provider Number");
25 var $rendering_provider_number_type;
26 var $rendering_provider_number_type_array = array ("" => "Unspecified", "0B" => "State License Number", "1A" => "Blue Cross Provider Number","1B" => "Blue Shield Provider Number","1C" => "Medicare Provider Number",
27 "1D" => "Medicaid Provider Number","1G" => "Provider UPIN Number","1H" => "Champus Identification Number","G2" => "Provider Commercial Number",
28 "LU" => "Location Number", "N5" => "Provider Plan Network Identification Number",
29 "TJ" => "Federal Taxpayer's Identification Number", "X4" => "Clinical Laboratory Improvement Amendment Number", "X5" => "State Industrial Accident Provider Number");
32 * Constructor sets all Insurance attributes to their default value
35 function InsuranceNumbers ($id = "", $prefix = "") {
37 $this->_table
= "insurance_numbers";
45 $ic = new InsuranceCompany($this->insurance_company_id
);
46 $this->insurance_company_name
= $ic->get_name();
50 function insurance_numbers_factory($provider_id) {
52 $sql = "SELECT id FROM " . $this->_table
. " where provider_id = '" . $provider_id . "' order by insurance_company_id";
53 $results = sqlQ($sql);
55 while($row = mysql_fetch_array($results) ) {
56 $ins[] = new InsuranceNumbers($row['id']);
66 function set_id($id) {
67 if (is_numeric($id)) {
72 function get_provider_id() {
73 return $this->provider_id
;
76 function set_provider_id($num) {
77 $this->provider_id
= $num;
80 function get_insurance_company_id() {
81 return $this->insurance_company_id
;
84 function set_insurance_company_id($num) {
85 $this->insurance_company_id
= $num;
88 function get_insurance_company_name() {
89 if (empty($this->insurance_company_name
)) {
92 return $this->insurance_company_name
;
95 function get_provider_number() {
96 return $this->provider_number
;
99 function set_provider_number($num) {
100 $this->provider_number
= $num;
103 function get_rendering_provider_number() {
104 return $this->rendering_provider_number
;
107 function set_rendering_provider_number($num) {
108 $this->rendering_provider_number
= $num;
111 function get_group_number() {
112 return $this->group_number
;
115 function set_group_number($num) {
116 $this->group_number
= $num;
119 function get_provider_number_type() {
120 return $this->provider_number_type
;
123 function set_provider_number_type($string) {
124 $this->provider_number_type
= $string;
127 function get_rendering_provider_number_type() {
128 return $this->rendering_provider_number_type
;
131 function set_rendering_provider_number_type($string) {
132 $this->rendering_provider_number_type
= $string;