mirror of
https://gitee.com/fastadminnet/framework.git
synced 2026-07-07 23:22:48 +08:00
改进Query类table方法
This commit is contained in:
@@ -1111,7 +1111,6 @@ class Query
|
|||||||
if (is_string($table)) {
|
if (is_string($table)) {
|
||||||
if (strpos($table, ')')) {
|
if (strpos($table, ')')) {
|
||||||
// 子查询
|
// 子查询
|
||||||
$table = $table;
|
|
||||||
} elseif (strpos($table, ',')) {
|
} elseif (strpos($table, ',')) {
|
||||||
$tables = explode(',', $table);
|
$tables = explode(',', $table);
|
||||||
$table = [];
|
$table = [];
|
||||||
@@ -1126,7 +1125,8 @@ class Query
|
|||||||
}
|
}
|
||||||
} elseif (strpos($table, ' ')) {
|
} elseif (strpos($table, ' ')) {
|
||||||
list($table, $alias) = explode(' ', $table);
|
list($table, $alias) = explode(' ', $table);
|
||||||
$table = [$table => $alias];
|
|
||||||
|
$table = [$table => $alias];
|
||||||
$this->alias($table);
|
$this->alias($table);
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
|
|||||||
Reference in New Issue
Block a user