2 require_once( 'ClinicalType.php' );
4 class Diagnosis
extends ClinicalType
6 const HYPERTENSION
= 'diag_hypertension';
7 const PREGNANCY
= 'diag_pregnancy';
8 const ENCEPHALOPATHY
= 'diag_encephalopathy';
9 const PROG_NEURO_DISORDER
= 'diag_prog_neuro_disorder';
11 public function getListType() {
12 return 'medical_problem';
15 public function getListColumn() {
19 public function getListId() {
20 return 'Clinical_Rules_Diagnosis_Types';
24 * Check if the patient has this diagnosis
26 * @param (CqmPatient) $patient
27 * @param (date) $beginMeasurement
28 * @param (date) $endMeasurement
30 * @return true if patient meets criteria, false ow
32 public function doPatientCheck( RsPatient
$patient, $beginDate = null, $endDate = null, $options = null ) {
33 $data = Codes
::lookup( $this->getOptionId() );
34 $type = $this->getListType();
35 foreach( $data as $codeType => $codes ) {
36 foreach ( $codes as $code ) {
37 if ( exist_lists_item( $patient->id
, $type, $codeType.'::'.$code, $endDate ) ) {