@ApiImplicitParam({name:'phoneNumber'})
@Delete(':phoneNumber / delete')
异步deleteUser(@Req()req:任意,@Res()res:任意,@Param('phoneNumber')phoneNumber:任意):承诺{
如果(等待this.userService.deleteOneByPhoneNumber(phoneNumber)){
Logger.log(Method:${req.method + req.route.path}, phoneNumber:${phoneNumber}
);
返回res.status(HttpStatus.OK).json({});
}其他{
Logger.error(Method:${req.method + req.route.path}, phoneNumber:${phoneNumber}
);
返回res.status(HttpStatus.BAD_REQUEST).json({});
}
}
List item