Add operator to walkComparison output
This commit is contained in:
parent
15c145f3b3
commit
7c28a932ae
@ -259,10 +259,11 @@ class ManyToManyPersister extends AbstractCollectionPersister
|
||||
$parameters = $this->expandCriteriaParameters($criteria);
|
||||
|
||||
foreach ($parameters as $parameter) {
|
||||
list($name, $value) = $parameter;
|
||||
$field = $this->quoteStrategy->getColumnName($name, $targetClass, $this->platform);
|
||||
$whereClauses[] = sprintf('te.%s = ?', $field);
|
||||
$params[] = $value;
|
||||
[$name, $value, $operator] = $parameter;
|
||||
|
||||
$field = $this->quoteStrategy->getColumnName($name, $targetClass, $this->platform);
|
||||
$whereClauses[] = sprintf('te.%s %s ?', $field, $operator);
|
||||
$params[] = $value;
|
||||
}
|
||||
|
||||
$tableName = $this->quoteStrategy->getTableName($targetClass, $this->platform);
|
||||
|
@ -50,9 +50,9 @@ class SqlValueVisitor extends ExpressionVisitor
|
||||
*/
|
||||
public function walkComparison(Comparison $comparison)
|
||||
{
|
||||
$value = $this->getValueFromComparison($comparison);
|
||||
$field = $comparison->getField();
|
||||
$operator = $comparison->getOperator();
|
||||
$value = $this->getValueFromComparison($comparison);
|
||||
$field = $comparison->getField();
|
||||
$operator = $comparison->getOperator();
|
||||
|
||||
if (($operator === Comparison::EQ || $operator === Comparison::IS) && $value === null) {
|
||||
return;
|
||||
@ -61,7 +61,7 @@ class SqlValueVisitor extends ExpressionVisitor
|
||||
}
|
||||
|
||||
$this->values[] = $value;
|
||||
$this->types[] = [$field, $value];
|
||||
$this->types[] = [$field, $value, $operator];
|
||||
}
|
||||
|
||||
/**
|
||||
|
Loading…
x
Reference in New Issue
Block a user