Page<FwSjJbEntity> page1 = new Page<>(page,pageSize); LambdaQueryWrapper<FwSjJbEntity> queryWrapper = new LambdaQueryWrapper<>(); Page<FwSjJbEntity> jbEntityPage = new Page<FwSjJbEntity>(); if(name==null||name.equals("")){ jbEntityPage = this.page(page1); }else { queryWrapper.like(FwSjJbEntity::getHouseName,name); jbEntityPage = this.page(page1, queryWrapper); } List<FwSjJbEntity> records = jbEntityPage.getRecords(); List<FwSjJbEntity> collect = records.stream().map(o -> { o.setSource(Const.FANGYUAN_LAIYUAN.get(o.getSource())); return o; }).collect(Collectors.toList()); jbEntityPage.setRecords(collect);