| | |
| | | .eq(!"0".equals(businessDeptId), TContract::getBusinessDeptId, businessDeptId) |
| | | .eq(TContract::getPayType, 2)); |
| | | List<String> houseIds = tContracts.stream().map(TContract::getHouseId).collect(Collectors.toList()); |
| | | if (houseIds.isEmpty()){ |
| | | return R.ok(new ArrayList<>()); |
| | | } |
| | | |
| | | |
| | | // 获取所有房屋信息 |
| | | List<THouse> houses = houseService.list(new LambdaQueryWrapper<THouse>() |
| | | .and(wrapper -> wrapper.in(THouse::getId, houseIds) |
| | | .or() |
| | | .and(wrapper -> wrapper.in(!houseIds.isEmpty(),THouse::getId, houseIds) |
| | | .or(!houseIds.isEmpty()) |
| | | .eq(THouse::getLeaseStatus, "1") |
| | | ) |
| | | .eq(!"0".equals(businessDeptId),THouse::getBusinessDeptId, businessDeptId) |