mirror of
https://gitee.com/fastadminnet/framework.git
synced 2026-07-07 23:22:48 +08:00
修正Model类的getAttr方法返回值
This commit is contained in:
@@ -381,6 +381,7 @@ abstract class Model implements \JsonSerializable, \ArrayAccess
|
|||||||
$value = $this->relation()->getRelation($name);
|
$value = $this->relation()->getRelation($name);
|
||||||
// 保存关联对象值
|
// 保存关联对象值
|
||||||
$this->data[$name] = $value;
|
$this->data[$name] = $value;
|
||||||
|
return $value;
|
||||||
} else {
|
} else {
|
||||||
throw new InvalidArgumentException('property not exists:' . __CLASS__ . '->' . $name);
|
throw new InvalidArgumentException('property not exists:' . __CLASS__ . '->' . $name);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user