From afc61298beb45778899086ea512f714b9ca949aa Mon Sep 17 00:00:00 2001 From: aozhiwei Date: Thu, 26 May 2022 15:12:11 +0800 Subject: [PATCH] 1 --- webapp/controller/UserController.class.php | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/webapp/controller/UserController.class.php b/webapp/controller/UserController.class.php index 8e199650..ee889baa 100644 --- a/webapp/controller/UserController.class.php +++ b/webapp/controller/UserController.class.php @@ -371,12 +371,17 @@ class UserController extends BaseAuthedController { public function query() { $name = getReqVal('name', ''); + $filter = array( + 'name' => $name, + 'channel' => BC_CHANNEL + ); + if (SERVER_ENV == _ONLINE) { + $filter['channel'] = BC_CHANNEL; + } $userDb = SqlHelper::ormSelectOne ($this->_getMysql($name), 't_user', - array( - 'name' => $name - ) + $filter ); if (!$userDb) { $this->_rspErr(1, 'not found');