From 80d928d872a3924419e51d47a58b57b78b67ea59 Mon Sep 17 00:00:00 2001 From: Karson Date: Tue, 7 Jun 2022 10:00:20 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E8=81=94=E5=8A=A8=E8=B0=83?= =?UTF-8?q?=E7=94=A8=E9=80=89=E6=8B=A9=E7=A9=BA=E6=97=B6=E7=9A=84=E9=94=99?= =?UTF-8?q?=E8=AF=AF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- application/admin/controller/Ajax.php | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/application/admin/controller/Ajax.php b/application/admin/controller/Ajax.php index f256906a..463066a3 100644 --- a/application/admin/controller/Ajax.php +++ b/application/admin/controller/Ajax.php @@ -273,18 +273,18 @@ class Ajax extends Backend { $params = $this->request->get("row/a"); if (!empty($params)) { - $province = isset($params['province']) ? $params['province'] : ''; - $city = isset($params['city']) ? $params['city'] : ''; + $province = isset($params['province']) ? $params['province'] : null; + $city = isset($params['city']) ? $params['city'] : null; } else { - $province = $this->request->get('province', ''); - $city = $this->request->get('city', ''); + $province = $this->request->get('province'); + $city = $this->request->get('city'); } $where = ['pid' => 0, 'level' => 1]; $provincelist = null; - if ($province !== '') { + if ($province !== null) { $where['pid'] = $province; $where['level'] = 2; - if ($city !== '') { + if ($city !== null) { $where['pid'] = $city; $where['level'] = 3; }