修复留言板Bug

This commit is contained in:
wen 2022-01-19 16:46:07 +08:00
parent b6a6fd3d85
commit 3ff14d7135
2 changed files with 2 additions and 7 deletions

View File

@ -5,7 +5,6 @@ import lombok.Data;
import lombok.NoArgsConstructor;
import javax.validation.constraints.Min;
import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;
/**
@ -47,14 +46,11 @@ public class QueryUserListRequest {
* tenantId
*/
@JsonProperty("tenantId")
@NotNull(message = "tenantId的参数名不正确或者tenantId的值为空请检查传入参数")
@NotBlank(message = "tenantId的参数为''字符串,请检查传入参数")
private String tenantId;
/**
* tenantType
*/
@JsonProperty("tenantType")
@NotNull(message = "tenantType的参数名不正确或者tenantType的值为空请检查传入参数")
private Integer tenantType;
}

View File

@ -268,9 +268,8 @@ public class XhpcMessageBoardServiceImpl implements XhpcMessageBoardService {
param.setCurrentPage(startIndex);
//查询用户列表
SysUser receiverInfo = tokenService.getLoginUser().getSysUser();
if (receiverInfo == null) {
throw new Exception("查询不到指定的租户receiverInfo为null请检查传递的参数");
}
param.setTenantId(receiverInfo.getTenantId());
param.setTenantType(0);
QueryUserListResponse queryUserListResponse = new QueryUserListResponse();
//查询出该租户拥有的所有用户列表
List<XhpcMessageBoardReceiveUser> userList = xhpcMessageBoardReceiveUserMapper.findAllBy(param);