|  |  | 
 |  |  |         if(Objects.isNull(ywDeviceRecord) | 
 |  |  |         || Objects.isNull(ywDeviceRecord.getDeviceId()) | 
 |  |  |         || Objects.isNull(ywDeviceRecord.getStatus()) | 
 |  |  |         || StringUtils.isBlank(ywDeviceRecord.getContent()) | 
 |  |  |         ){ | 
 |  |  |             throw new BusinessException(ResponseStatus.BAD_REQUEST); | 
 |  |  |         } | 
 |  |  | 
 |  |  |                         .and(Objects.nonNull(model)&&StringUtils.isNotBlank(model.getDeviceName()),i->i.like(YwDevice::getName,model.getDeviceName()).or().like(YwDevice::getCode,model.getDeviceName())) | 
 |  |  |                         .ge(Objects.nonNull(model.getStartDate()),YwDeviceRecord::getCreateDate, Utils.Date.getStart(pageWrap.getModel().getStartDate())) | 
 |  |  |                         .le(Objects.nonNull(model.getEndDate()),YwDeviceRecord::getCreateDate, Utils.Date.getStart(pageWrap.getModel().getEndDate())) | 
 |  |  |                         .eq(Objects.nonNull(model.getDeviceId()),YwDeviceRecord::getDeviceId,model.getDeviceId()) | 
 |  |  |                         .eq(YwDeviceRecord::getIsdeleted,Constants.ZERO) | 
 |  |  |                         .orderByDesc(YwDeviceRecord::getCreateDate) | 
 |  |  |         ); | 
 |  |  |         return PageData.from(iPage); | 
 |  |  |     } | 
 |  |  | 
 |  |  |         QueryWrapper<YwDeviceRecord> wrapper = new QueryWrapper<>(ywDeviceRecord); | 
 |  |  |         return ywDeviceRecordMapper.selectCount(wrapper); | 
 |  |  |     } | 
 |  |  |  | 
 |  |  |  | 
 |  |  |  | 
 |  |  | } |