改进appendRelationAttr方法

This commit is contained in:
thinkphp
2017-10-22 22:39:18 +08:00
parent 983b3afe49
commit caf8657b9f

View File

@@ -692,7 +692,7 @@ abstract class Model implements \JsonSerializable, \ArrayAccess
if (isset($this->data[$key])) {
throw new Exception('bind attr has exists:' . $key);
} else {
$this->data[$key] = $model->$attr;
$this->data[$key] = $model->getAttr($attr);
}
}
}