FreeMED. Patient

Patient object container.

Summary
Patient object container.
Produces a user-friendly age description.
Produces a numeric age value.
Determine last procedure date for this patient object.
Get the patient’s full name.
Convert record into textual representation.
Determine patient’s city/state/zip address line.
Determine patient’s date of birth.
Get short date of birth output.
Determine patient’s database table id number.
Determine patient’s employment status.
Determine whether patient is female.
Determine whether patient is male.
Formatted phone number string
Get list of patient id keys based on first and last name provided
Get list of procedures to bill by patient
Produce proper capitalization of a string.

Functions

FreeMED. Patient

Parameters

$patient_numberDatabase table identifier for the specified patient.
$is_callin(optional) Boolean flag to specify if the patient is a “call-in” patient.  Defaults to false.

age

function age ($date_to = "")

Produces a user-friendly age description.

Parameters

$date_to(optional) Date to which the age is being calculated.  Defaults to today.

Returns

Text string describing the patient’s age.

numericAge

function numericAge ( )

Produces a numeric age value.

Returns

Text string describing the patient’s age.

date_of_last_procedure

function date_of_last_procedure ( )

Determine last procedure date for this patient object.

Returns

SQL date formatted string, or NULL if there is no previous procedure date.

fullName

function fullName ($with_dob =  false)

Get the patient’s full name.

Parameters

$with_dob(optional) Boolean flag to determine if date of birth is included in the output.  Defaults to false.

Returns

Text string containing patient’s full name.

to_text

function to_text ($id = )

Convert record into textual representation.

Returns

Textual representation of record.

cityStateZip

function cityStateZip ( )

Determine patient’s city/state/zip address line.

Returns

String representation of patient’s last address line.

dateOfBirth

function dateOfBirth ($no_parameters =  "")

Determine patient’s date of birth.

Returns

String representation of patient’s date of birth, using fm_date_print format.

dateOfBirthShort

function dateOfBirthShort ( )

Get short date of birth output.

Returns

MM/DD/YYYY date format for patient date of birth.

idNumber

function idNumber ( )

Determine patient’s database table id number.

Returns

SQL table id number for this patient object.

isEmployed

function isEmployed ( )

Determine patient’s employment status.

Returns

Boolean value, whether patient is employed.

isFemale

function isFemale ( )

Determine whether patient is female.

Returns

Boolean value, whether patient is female.

isMale

function isMale ( )

Determine whether patient is male.

Returns

Boolean value, whether patient is male.

phoneNumber

function phoneNumber ( )

Returns

Formatted phone number string

get_list_by_name

function get_list_by_name ($last,
$first)

Get list of patient id keys based on first and last name provided

Parameters

$lastLast name substring
$firstFirst name substring

Returns

Array of patient id keys

get_procedures_to_bill

function get_procedures_to_bill ($by_patient =  true)

Get list of procedures to bill by patient

Parameters

$by_patient(optional) Boolean.  If this is false, all procedures which are billable in the system will be returned.  Defaults to true.

Returns

Array of procedure ids.

_fixcaps

function _fixcaps ($string)

Produce proper capitalization of a string.

Parameters

$stringOriginal string.

Returns

Properly capitalized string.

function age ($date_to = "")
Produces a user-friendly age description.
function numericAge ( )
Produces a numeric age value.
function date_of_last_procedure ( )
Determine last procedure date for this patient object.
function fullName ($with_dob =  false)
Get the patient’s full name.
function to_text ($id = )
Convert record into textual representation.
function cityStateZip ( )
Determine patient’s city/state/zip address line.
function dateOfBirth ($no_parameters =  "")
Determine patient’s date of birth.
function dateOfBirthShort ( )
Get short date of birth output.
function idNumber ( )
Determine patient’s database table id number.
function isEmployed ( )
Determine patient’s employment status.
function isFemale ( )
Determine whether patient is female.
function isMale ( )
Determine whether patient is male.
function phoneNumber ( )
Formatted phone number string
function get_list_by_name ($last,
$first)
Get list of patient id keys based on first and last name provided
function get_procedures_to_bill ($by_patient =  true)
Get list of procedures to bill by patient
function _fixcaps ($string)
Produce proper capitalization of a string.
function fm_date_print ($actualdate,  
$show_text_days = false)
Create a nicely formatted date display