示例#1
0
 public function getProviderCredentializationForDate($provider_id, $insurance_id, $date = null)
 {
     $this->getProviderCredentializationModel();
     $this->pc->addFilter('provider_id', $provider_id);
     $this->pc->addFilter('insurance_company_id', $insurance_id);
     if (isset($date)) {
         $this->pc->addFilter('start_date', $date, '<=');
         $this->pc->addFilter('end_date', $date, '>=');
     }
     return $this->pc->load()->one();
 }
示例#2
0
 public function getImmunizationsAdministeredByPid($pid)
 {
     $this->i->addFilter('pid', $pid);
     $this->i->addFilter('administered_uid', null, '!=');
     $this->i->addFilter('administered_uid', 0, '!=');
     return $this->i->load()->leftJoin(['title' => 'administered_title', 'fname' => 'administered_fname', 'mname' => 'administered_mname', 'lname' => 'administered_lname'], 'users', 'administered_uid', 'id')->all();
 }
示例#3
0
 public function getPatientActiveMedicationsByPidAndCode($pid, $code)
 {
     $this->m->addFilter('pid', $pid);
     $this->m->addFilter('RXCUI', $code);
     $records = $this->m->load()->leftJoin(['title', 'fname', 'mname', 'lname'], 'users', 'administered_uid', 'id')->all();
     foreach ($records as $i => $record) {
         if ($record['end_date'] != '0000-00-00' && strtotime($record['end_date']) < strtotime(date('Y-m-d'))) {
             unset($records[$i]);
         }
     }
     return $records;
 }
示例#4
0
 public function getActiveInsurances()
 {
     if ($this->I == null) {
         $this->I = MatchaModel::setSenchaModel('App.model.administration.InsuranceCompany');
     }
     $options = [];
     $this->I->addFilter('active', 1);
     $records = $this->I->load()->all();
     foreach ($records as $record) {
         $options[] = ['option_name' => $record['id'] . ': ' . $record['name'], 'option_value' => $record['id']];
     }
     return $options;
 }
示例#5
0
 public function getActiveProviders()
 {
     //		$records = array();
     //		$records[] = array('option_name' => 'Select', 'option_value' => '');
     $this->u->addFilter('npi', '', '!=');
     $this->u->addFilter('active', 1);
     //		$users = $this->u->load()->all();
     //		foreach($users As $row){
     //			$foo = array();
     //			$foo['option_name'] = $row['title'] . Person::fullname($row['fname'],$row['mname'],$row['lname']);
     //			$foo['option_value'] = $row['id'];
     //			$records[] = $foo;
     //		}
     return $this->u->load()->all();
 }
示例#6
0
 public function getPatientComplementaryInsuranceByPid($pid)
 {
     $this->pi->addFilter('pid', $pid);
     $this->pi->addFilter('insurance_type', 'C');
     return $this->pi->load()->one();
 }
示例#7
0
 /**
  * @param $port
  *
  * @return mixed
  */
 protected function getServerByPort($port)
 {
     $this->s->addFilter('port', $port);
     return $this->s->load()->one();
 }
示例#8
0
 public function getPatientCarePlanGoalsByPid($pid)
 {
     $this->c->addFilter('pid', $pid);
     return $this->c->load()->all();
 }
示例#9
0
 public function getPatientReferralByEid($eid)
 {
     $this->r->addFilter('eid', $eid);
     return $this->r->load()->one();
 }
示例#10
0
文件: Services.php 项目: igez/gaiaehr
 public function getEncounterServicesByEid($eid)
 {
     $this->s->addFilter('eid', $eid);
     return $this->s->load()->all();
 }
 public function getPatientCognitiveAndFunctionalStatusesByPid($pid)
 {
     $this->c->addFilter('pid', $pid);
     return $this->c->load()->all();
 }