diff --git a/app/api/controller/User.php b/app/api/controller/User.php index 2e7cae02..5d70a7f1 100644 --- a/app/api/controller/User.php +++ b/app/api/controller/User.php @@ -361,6 +361,9 @@ class User extends Controller $params = $this->request->param(); $user_id = $params['user_id'] ?? 0; unset($params['user_id']); + if (isset($params['status']) && $params['status']) { + $params['user_type'] = 0; + } UserModel::where('user_id', $user_id)->update($params); return $this->renderSuccess('ok'); }