Compare commits
No commits in common. "694c169e48ef3d8b6a48ad3fb757b4efb2130414" and "f1f40d92f8b8b593c121c35b72c3daa51b415521" have entirely different histories.
694c169e48
...
f1f40d92f8
|
|
@ -101,7 +101,6 @@ public class SltAgreementInfoController extends BaseController {
|
|||
List<SltAgreementInfo> sltInfoMonth = sltAgreementInfoService.getSltInfoMonth(list);
|
||||
List<List<MonthRepairInfo>> allLists = new ArrayList<>();
|
||||
for (AgreementInfo agreementInfo : list) {
|
||||
List<MonthRepairInfo> list1 = new ArrayList<>();
|
||||
for (SltAgreementInfo sltAgreementInfo : sltInfoMonth) {
|
||||
// 单个协议导出
|
||||
if (StringUtils.isNotBlank(agreementInfo.getCodeNum())) {
|
||||
|
|
@ -110,20 +109,17 @@ public class SltAgreementInfoController extends BaseController {
|
|||
if (s.equals(sltAgreementInfo.getCodeNum().toString())) {
|
||||
List<SltAgreementInfo> node = sltAgreementInfo.getNode();
|
||||
List<MonthRepairInfo> leaseInfoList = Convert.toList(MonthRepairInfo.class, node);
|
||||
list1.addAll(leaseInfoList);
|
||||
allLists.add(leaseInfoList);
|
||||
}
|
||||
}
|
||||
} else {
|
||||
if (String.valueOf(agreementInfo.getAgreementId()).equals(sltAgreementInfo.getAgreementId())){
|
||||
// 多个协议导出
|
||||
List<SltAgreementInfo> node = sltAgreementInfo.getNode();
|
||||
List<MonthRepairInfo> leaseInfoList = Convert.toList(MonthRepairInfo.class, node);
|
||||
list1.addAll(leaseInfoList);
|
||||
allLists.add(leaseInfoList);
|
||||
}
|
||||
}
|
||||
}
|
||||
allLists.add(list1);
|
||||
}
|
||||
exportMultipleLists(allLists, response);
|
||||
}
|
||||
|
||||
|
|
@ -287,7 +283,7 @@ public class SltAgreementInfoController extends BaseController {
|
|||
ExcelWriter excelWriter = EasyExcel.write(response.getOutputStream(), MonthRepairInfo.class).build();
|
||||
|
||||
for (int i = 0; i < lists.size(); i++) {
|
||||
WriteSheet writeSheet = EasyExcel.writerSheet(lists.get(i).get(0).getProjectName()).build();
|
||||
WriteSheet writeSheet = EasyExcel.writerSheet("Sheet" + (i + 1)).build();
|
||||
excelWriter.write(lists.get(i), writeSheet);
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -32,7 +32,6 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||
bui.unit_name AS unitName,
|
||||
bp.lot_name AS projectName,
|
||||
spm.month as month,
|
||||
pmc.agreement_id as agreementId,
|
||||
pmc.cost_bearing_party as costBearingParty,
|
||||
pmc.costs as costs
|
||||
FROM
|
||||
|
|
|
|||
Loading…
Reference in New Issue