|
@@ -30,6 +30,9 @@ class LoginService extends CrudService {
|
|
|
} else { user = await this.model.findOne({ code: phone, role }); }
|
|
|
if (!user) { throw new BusinessError(ErrorCode.USER_NOT_EXIST); } else is_code = true;
|
|
|
}
|
|
|
+ console.group('user');
|
|
|
+ console.log(`${JSON.stringify(user)}`);
|
|
|
+ console.groupEnd();
|
|
|
const pdata = {};
|
|
|
if (is_code) pdata.code = phone;
|
|
|
else pdata.phone = phone;
|