From caf8657b9f65000bbac05a3cd60125dfc67cef29 Mon Sep 17 00:00:00 2001 From: thinkphp Date: Sun, 22 Oct 2017 22:39:18 +0800 Subject: [PATCH] =?UTF-8?q?=E6=94=B9=E8=BF=9BappendRelationAttr=E6=96=B9?= =?UTF-8?q?=E6=B3=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- library/think/Model.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/library/think/Model.php b/library/think/Model.php index 05d56f95..6f74d388 100644 --- a/library/think/Model.php +++ b/library/think/Model.php @@ -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); } } }