Commit 49574ce9 authored by zYne's avatar zYne

--no commit message

--no commit message
parent adc6c1b2
......@@ -132,7 +132,8 @@ class Doctrine_Hook
list($alias, $column) = $e;
$tableAlias = $this->query->getTableAlias($alias);
$table = $this->query->getTable($tableAlias);
$map = $this->query->getAliasDeclaration($alias);
$table = $map['table'];
if ( ! $table) {
throw new Doctrine_Exception('Unknown table alias ' . $tableAlias);
......@@ -181,7 +182,8 @@ class Doctrine_Hook
list($alias, $column) = $e;
$tableAlias = $this->query->getTableAlias($alias);
$table = $this->query->getTable($tableAlias);
$map = $this->query->getAliasDeclaration($alias);
$table = $map['table'];
if ($def = $table->getDefinitionOf($column)) {
$this->query->addOrderBy($alias . '.' . $column . ' ' . $order);
......
......@@ -58,7 +58,7 @@ abstract class Doctrine_Hook_Parser_Complex extends Doctrine_Hook_Parser
*/
public function parseClause($alias, $field, $value)
{
$parts = Doctrine_Query::quoteExplode($value, ' AND ');
$parts = Doctrine_Tokenizer::quoteExplode($value, ' AND ');
if (count($parts) > 1) {
$ret = array();
......@@ -68,7 +68,7 @@ abstract class Doctrine_Hook_Parser_Complex extends Doctrine_Hook_Parser
$r = implode(' AND ', $ret);
} else {
$parts = Doctrine_Query::quoteExplode($value, ' OR ');
$parts = Doctrine_Tokenizer::quoteExplode($value, ' OR ');
if (count($parts) > 1) {
$ret = array();
foreach ($parts as $part) {
......
......@@ -47,7 +47,7 @@ class Doctrine_Hook_WordLike extends Doctrine_Hook_Parser_Complex
public function parseSingle($alias, $field, $value)
{
if (strpos($value, "'") !== false) {
$value = Doctrine_Query::bracketTrim($value, "'", "'");
$value = Doctrine_Tokenizer::bracketTrim($value, "'", "'");
$a[] = $alias . '.' . $field . ' LIKE ?';
$this->params[] = $value . '%';
......
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