This commit is contained in:
2021-11-24 16:56:16 +08:00
parent eb75e69d60
commit 5756573d8d
+2 -2
View File
@@ -522,7 +522,7 @@ trait QueryTrait
$conditionArray = $this->sprintf($conditionArray, $value, $opera); $conditionArray = $this->sprintf($conditionArray, $value, $opera);
} }
$this->where = ['(' . implode(' AND ', $this->where) . ') OR (' . $conditionArray . ')']; $this->where = ['((' . implode(' AND ', $this->where) . ') OR (' . $conditionArray . '))'];
return $this; return $this;
} }
@@ -865,7 +865,7 @@ trait QueryTrait
} else { } else {
$generate->where($closure); $generate->where($closure);
} }
return '(' . $generate->getSql() . ')'; return $generate->getSql();
} }