mirror of
https://gitee.com/fastadminnet/framework.git
synced 2026-07-06 23:02:48 +08:00
withCount方法的第二个参数默认为true
This commit is contained in:
@@ -1678,7 +1678,7 @@ class Query
|
|||||||
* @param bool $subQuery 是否使用子查询
|
* @param bool $subQuery 是否使用子查询
|
||||||
* @return $this
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function withCount($relation, $subQuery = false)
|
public function withCount($relation, $subQuery = true)
|
||||||
{
|
{
|
||||||
if (!$subQuery) {
|
if (!$subQuery) {
|
||||||
$this->options['with_count'] = $relation;
|
$this->options['with_count'] = $relation;
|
||||||
|
|||||||
Reference in New Issue
Block a user