Skip to content

Commit

Permalink
Add get_specialty() function.
Browse files Browse the repository at this point in the history
  • Loading branch information
lemonsoftwarero committed Jun 19, 2007
1 parent 2503f83 commit 273d00c
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion library/classes/Provider.class.php
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ class Provider extends ORDataObject{
var $fname;
var $federal_drug_id;
var $insurance_numbers;
var $specialty;

/**
* Constructor sets all Prescription attributes to their default value
Expand All @@ -36,12 +37,13 @@ function Provider ($id = "", $prefix = "") {
}

function populate() {
$res = sqlQuery("SELECT fname,lname,federaldrugid from users where id =". mysql_real_escape_string($this->id));
$res = sqlQuery("SELECT fname,lname,federaldrugid, specialty FROM users where id =". mysql_real_escape_string($this->id));

if (is_array($res)) {
$this->lname = $res['lname'];
$this->fname = $res['fname'];
$this->federal_drug_id = $res['federaldrugid'];
$this->specialty = $res['specialty'];
}

$ins = new InsuranceNumbers();
Expand Down Expand Up @@ -77,6 +79,10 @@ function get_name_display() {
return $this->fname . " " . $this->lname;
}

function get_specialty() {
return $this->specialty;
}

function get_provider_number_default() {
if (!empty($this->insurance_numbers)) {
return $this->insurance_numbers[0]->get_provider_number();
Expand Down

0 comments on commit 273d00c

Please sign in to comment.