/** * Fetch all attributes matching $where * * @param string|array $where OPTIONAL An SQL WHERE clause. * @param string|array $order OPTIONAL An SQL ORDER clause. * @param int $count OPTIONAL An SQL LIMIT count. * @param int $offset OPTIONAL An SQL LIMIT offset. * @return Zend_Db_Table_Rowset The row results per the Zend_Db_Adapter_Abstract fetch mode. */ public function fetchAll($where = null, $order = null, $count = null, $offset = null) { $result = parent::fetchAll($where, $order, $count, $offset)->toArray(); foreach ($result as &$r) { $r['zendMailObject'] = unserialize($r['zendMailObject']); } return $result; }
/** * Gets all the bugs, with options to only show new bugs * * @param boolean $newOnly * @return result from fetchAll */ public function getBugText($bugId, $order = 'ASC') { $where = $this->getAdapter()->quoteInto('bugId = ?', $bugId); return parent::fetchAll($where, 'postDt ' . $order); }
/** * Gets all the bugs, with options to only show new bugs * * @param boolean $newOnly * @return result from fetchAll */ public function getBugs($newOnly = true) { if ($newOnly) { $where = $this->getAdapter()->quoteInto('status IN (?)', array('new', 'escalated')); } else { $where = null; } return parent::fetchAll($where, 'submitDt DESC'); }