From 8e11bdcf5918821408e3eb8c2422847cc5763cdb Mon Sep 17 00:00:00 2001 From: liweisen Date: Mon, 6 Jan 2020 17:57:33 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BC=98=E5=8C=96=E7=99=BB=E5=BD=95=E9=80=BB?= =?UTF-8?q?=E8=BE=91?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- application/project/controller/Login.php | 2 ++ 1 file changed, 2 insertions(+) diff --git a/application/project/controller/Login.php b/application/project/controller/Login.php index fa0dd58..e041474 100644 --- a/application/project/controller/Login.php +++ b/application/project/controller/Login.php @@ -84,6 +84,8 @@ class Login extends BasicApi // } $member = Member::where(['mobile' => $mobile])->order('id asc')->find(); } else { + !$data['password'] && $this->error('登录密码不能为空!'); + !$data['account'] && $this->error('登录账号不能为空!'); $member = Member::where(['account' => $data['account']])->whereOr(['email' => $data['account']])->order('id asc')->find(); } empty($member) && $this->error('账号或密码错误', 201);