改进一对多的预载入 支持传入闭包条件

This commit is contained in:
thinkphp
2016-04-21 12:37:14 +08:00
parent f24bc5289c
commit 4602f135f6
2 changed files with 18 additions and 6 deletions

View File

@@ -890,6 +890,8 @@ class Query
call_user_func_array($closure, [ & $this]);
}
$i++;
} elseif ($closure) {
$with[$key] = $closure;
}
}
$this->via();