Example #1
0
 public static function getClaimFile($claimId)
 {
     $db = Zend_Registry::get('dbAdapter');
     $claimFile = new self();
     $sqlSelect = $db->select()->from($claimFile->_table)->where('claimIds LIKE ?', '%' . $claimId . '%');
     $claimFile->populateWithSql($sqlSelect->__toString());
     return $claimFile;
 }
Example #2
0
 public static function retrieveSignatureId($objectClass, $objectId, $signed = true)
 {
     $db = Zend_Registry::get('dbAdapter');
     $esig = new self();
     $sqlSelect = $db->select()->from($esig->_table)->where('objectClass = ?', $objectClass)->where('objectId = ?', $objectId)->limit(1);
     if ($signed) {
         $sqlSelect->where("signature != ''");
     }
     $esig->populateWithSql($sqlSelect->__toString());
     return $esig->eSignatureId;
 }
 public static function filterByPayerPersonIds($insuranceProgramId, $personId)
 {
     $db = Zend_Registry::get('dbAdapter');
     $orm = new self();
     $sqlSelect = $db->select()->from($orm->_table)->where('insurance_program_id = ?', (int) $insuranceProgramId)->where('person_id = ?', (int) $personId)->where('active = 1')->order('program_order')->limit(1);
     $orm->populateWithSql($sqlSelect->__toString());
     return $orm;
 }