mirror of
https://gitee.com/fastadminnet/framework.git
synced 2026-07-07 15:12:48 +08:00
修正一对一嵌套关联数组定义的问题
This commit is contained in:
@@ -1902,6 +1902,9 @@ class Query
|
|||||||
$closure = $relation;
|
$closure = $relation;
|
||||||
$relation = $key;
|
$relation = $key;
|
||||||
$with[$key] = $key;
|
$with[$key] = $key;
|
||||||
|
} elseif (is_array($relation)) {
|
||||||
|
$subRelation = $relation;
|
||||||
|
$relation = $key;
|
||||||
} elseif (is_string($relation) && strpos($relation, '.')) {
|
} elseif (is_string($relation) && strpos($relation, '.')) {
|
||||||
$with[$key] = $relation;
|
$with[$key] = $relation;
|
||||||
list($relation, $subRelation) = explode('.', $relation, 2);
|
list($relation, $subRelation) = explode('.', $relation, 2);
|
||||||
|
|||||||
Reference in New Issue
Block a user