From c2236528abe4ee973d273db30091444aee1c8b4f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mr=C2=B7x?= Date: Wed, 18 Aug 2021 15:09:40 +0800 Subject: [PATCH] =?UTF-8?q?=E6=94=B9=E5=90=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/ActiveQuery.php | 3 +-- src/Command.php | 1 + 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/ActiveQuery.php b/src/ActiveQuery.php index 5de5566..e52c308 100644 --- a/src/ActiveQuery.php +++ b/src/ActiveQuery.php @@ -43,7 +43,6 @@ class ActiveQuery extends Component implements ISqlBuilder public array $attributes = []; - /** * Comply constructor. * @param $model @@ -270,7 +269,7 @@ class ActiveQuery extends Component implements ISqlBuilder [$sql, $params] = $this->builder->insert($data, true); - return $this->execute($sql, $params)->exec(); + return $this->execute($sql, $params)->exec(null, true); } /** diff --git a/src/Command.php b/src/Command.php index a9b3035..d277e5d 100644 --- a/src/Command.php +++ b/src/Command.php @@ -168,6 +168,7 @@ class Command extends Component { $pdo = $this->db->getConnect($this->sql); $result = $pdo->execute($this->sql, $isInsert, $this->params); + var_dump($result); if ($hasAutoIncrement && $result == 0) { return false; }