修正数据库字段大小写设置问题 修正Query类的where方法对原生sql条件的判断

This commit is contained in:
thinkphp
2016-04-30 15:05:52 +08:00
parent 11769ed15c
commit a8a8d93baa
2 changed files with 6 additions and 2 deletions

View File

@@ -491,7 +491,7 @@ class Query
if (is_string($field) && !empty($this->options['via'])) {
$field = $this->options['via'] . '.' . $field;
}
if (is_string($field) && preg_match('/[,=\>\<\'\"\(`.\s]/', $field)) {
if (is_string($field) && preg_match('/[,=\>\<\'\"\(\s]/', $field)) {
$where[] = ['exp', $field];
if (is_array($op)) {
// 参数绑定