From 4d74ea53975b740fd59651effa7f8d201731164e Mon Sep 17 00:00:00 2001 From: aozhiwei Date: Mon, 5 Jun 2023 20:06:48 +0800 Subject: [PATCH] 1 --- webapp/controller/UserController.class.php | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/webapp/controller/UserController.class.php b/webapp/controller/UserController.class.php index 3779bddf..fc2ba4db 100644 --- a/webapp/controller/UserController.class.php +++ b/webapp/controller/UserController.class.php @@ -64,6 +64,14 @@ class UserController extends BaseAuthedController { $this->_updateUserInfo(array( 'last_login_time'=>myself()->_getNowTime(), )); + if ($this->_getChannel() == BC_CHANNEL && + empty($userInfo['address']) + ) { + User::Update(array( + 'address' => $this->_getOpenId() + )); + $userInfo['address'] = $this->_getOpenId(); + } $this->updateLastSeason($userInfo); $this->_rspData(array( 'info' => User::show($userInfo),