public static function fetchAll($where = null, $order = null, $limit = null, $offset = null) { $resultSet = self::getDbTable()->fetchAll($where, $order, $limit, $offset); $entries = array(); foreach ($resultSet as $row) { $entry = new Application_Model_O_GlobalConsultationApply(); $entry->setId($row->id)->setDepartment_category_id($row->department_category_id)->setDepartment_id($row->department_id)->setEmail($row->email)->setMobile($row->mobile)->setAge($row->age)->setSex($row->sex)->setLocation($row->location)->setTreatment_time($row->treatment_time)->setOpinion($row->opinion)->setReport($row->report)->setCtime($row->ctime)->setUtime($row->utime)->setStatus($row->status); $entry->setNew(false); $entries[] = $entry; } return $entries; }