mirror of
https://gitee.com/fastadminnet/framework.git
synced 2026-07-07 15:12:48 +08:00
修正Model类hasWhere方法
This commit is contained in:
@@ -1450,7 +1450,7 @@ abstract class Model implements \JsonSerializable, \ArrayAccess
|
|||||||
$model = new static();
|
$model = new static();
|
||||||
$relation = $model->$relation();
|
$relation = $model->$relation();
|
||||||
if ($relation instanceof HasMany) {
|
if ($relation instanceof HasMany) {
|
||||||
return $model->$relation()->hasWhere($where);
|
return $relation->hasWhere($where);
|
||||||
} else {
|
} else {
|
||||||
return $relation;
|
return $relation;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user