rain
2024-03-27 6322f4c190dc9b41572e59e671dd3ecc005253b9
src/main/java/com/dji/sample/patches/service/impl/GetPatchesServiceImpl.java
@@ -5,7 +5,7 @@
import com.dji.sample.common.model.PaginationData;
import com.dji.sample.patches.dao.GetPatchesMapper;
import com.dji.sample.patches.model.Param.PatchesParam;
import com.dji.sample.patches.model.entity.PatchesEntity;
import com.dji.sample.patches.model.entity.LotInfo;
import com.dji.sample.patches.service.GetPatchesService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
@@ -19,12 +19,12 @@
    private GetPatchesMapper mapper;
    @Override
    public PaginationData<PatchesEntity> limitGet(PatchesParam param) {
        Page<PatchesEntity> page = mapper.selectPage(new Page<PatchesEntity>(param.getPage(), param.getPageSize()), null);
        List<PatchesEntity> records = page.getRecords()
    public PaginationData<LotInfo> limitGet(PatchesParam param) {
        Page<LotInfo> page = mapper.selectPage(new Page<LotInfo>(param.getPage(), param.getPageSize()), null);
        List<LotInfo> records = page.getRecords()
                .stream()
                .collect(Collectors.toList());
        return new PaginationData<PatchesEntity>(records, new Pagination(page));
        return new PaginationData<LotInfo>(records, new Pagination(page));
    }
}