mirror of
https://gitee.com/fastadminnet/framework.git
synced 2026-07-07 07:12:47 +08:00
修正关联
This commit is contained in:
@@ -1239,6 +1239,7 @@ class Query
|
|||||||
$logic = strtoupper($logic);
|
$logic = strtoupper($logic);
|
||||||
if (isset($this->options['where'][$logic][$field])) {
|
if (isset($this->options['where'][$logic][$field])) {
|
||||||
unset($this->options['where'][$logic][$field]);
|
unset($this->options['where'][$logic][$field]);
|
||||||
|
unset($this->options['multi'][$logic][$field]);
|
||||||
}
|
}
|
||||||
return $this;
|
return $this;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -185,7 +185,7 @@ class HasMany extends Relation
|
|||||||
if ($closure) {
|
if ($closure) {
|
||||||
call_user_func_array($closure, [ & $model]);
|
call_user_func_array($closure, [ & $model]);
|
||||||
}
|
}
|
||||||
$list = $model->where($where)->with($subRelation)->select();
|
$list = $model->removeWhereField($foreignKey)->where($where)->with($subRelation)->select();
|
||||||
|
|
||||||
// 组装模型数据
|
// 组装模型数据
|
||||||
$data = [];
|
$data = [];
|
||||||
|
|||||||
Reference in New Issue
Block a user