From a439c616b4acd75917d672c9d133b08915fb3129 Mon Sep 17 00:00:00 2001 From: whwyy Date: Wed, 10 Jan 2024 17:48:54 +0800 Subject: [PATCH] eee --- Base/Model.php | 3 +++ 1 file changed, 3 insertions(+) diff --git a/Base/Model.php b/Base/Model.php index 025b468..82650c8 100644 --- a/Base/Model.php +++ b/Base/Model.php @@ -503,6 +503,9 @@ abstract class Model extends Component implements ModelInterface, ArrayAccess, \ $oldPrams[$key] = $this->_oldAttributes[$key]; } } + if ($this->hasPrimary()) { + $condition = [$this->getPrimary() => $this->getPrimaryValue()]; + } return [$oldPrams, $condition, $params]; }