Commit 7435ec30 authored by zYne's avatar zYne

--no commit message

--no commit message
parent 6eb68578
......@@ -1399,12 +1399,31 @@ abstract class Doctrine_Record extends Doctrine_Record_Abstract implements Count
* @param array $params prepared statement params (if any)
* @return mixed the fetched data
*/
public function fetch($queryKey, $params = array())
public function fetch($queryKey, $params = array(), $hydrationMode = Doctrine::HYDRATE_RECORD)
{
return Doctrine_Manager::getInstance()
->getQueryRegistry()
->get($queryKey, $this->_table->getComponentName())
->execute($params);
->execute($params, $hydrationMode);
}
/**
* fetchOne
* fetches data using the provided queryKey and
* the associated query in the query registry
*
* if no query for given queryKey is being found a
* Doctrine_Query_Registry exception is being thrown
*
* @param string $queryKey the query key
* @param array $params prepared statement params (if any)
* @return mixed the fetched data
*/
public function fetchOne($queryKey, $params = array(), $hydrationMode = Doctrine::HYDRATE_RECORD)
{
return Doctrine_Manager::getInstance()
->getQueryRegistry()
->get($queryKey, $this->_table->getComponentName())
->fetchOne($params, $hydrationMode);
}
/**
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment