|
|
|
@ -3388,7 +3388,7 @@ public class SignFpqsServiceImpl extends MpBaseServiceImpl<SignRecordInvoiceDao, |
|
|
|
|
if(pramsMap.get("ids") != null){ |
|
|
|
|
String ids1 = pramsMap.get("ids").toString(); |
|
|
|
|
log.info("ids值为{}",ids1); |
|
|
|
|
String replace = ids1.replace("[", "").replace("]", ""); |
|
|
|
|
String replace = ids1.replace("[", "").replace("]", "").replace("\"","").trim(); |
|
|
|
|
String[] split = replace.split(","); |
|
|
|
|
List<String> strings = Arrays.asList(split); |
|
|
|
|
pramsMap.put("ids",strings); |
|
|
|
@ -3419,6 +3419,7 @@ public class SignFpqsServiceImpl extends MpBaseServiceImpl<SignRecordInvoiceDao, |
|
|
|
|
|
|
|
|
|
public String qsSendEmail(Map<String, Object> pramsMap){ |
|
|
|
|
List<QsExcelEntity> excelList = selectWqsfp(pramsMap); |
|
|
|
|
log.info("excelList {}",excelList); |
|
|
|
|
ExcelWriter excelWriter = null; |
|
|
|
|
if(excelList != null){ |
|
|
|
|
// String fileName = "签收数据导出" + ".xlsx";
|
|
|
|
@ -3429,6 +3430,7 @@ public class SignFpqsServiceImpl extends MpBaseServiceImpl<SignRecordInvoiceDao, |
|
|
|
|
WriteSheet writeSheet = EasyExcel.writerSheet("sheet1").head(QsExcelEntity.class).build(); |
|
|
|
|
excelWriter.write(excelList, writeSheet); |
|
|
|
|
byte[] bytes = outputStream.toByteArray(); |
|
|
|
|
log.info("byte数组信息为 {}",bytes); |
|
|
|
|
return sendEmailByqs((String) pramsMap.get("emailAddress"),"",bytes); |
|
|
|
|
}catch(Exception e){ |
|
|
|
|
log.error("签收数据导出,错误日志:{}",e); |
|
|
|
@ -3486,8 +3488,9 @@ public class SignFpqsServiceImpl extends MpBaseServiceImpl<SignRecordInvoiceDao, |
|
|
|
|
attachmentVo.setName("发票签收"); |
|
|
|
|
attachmentVo.setFileBytes(xlsxFile); |
|
|
|
|
attachmentVo.setType("application/vnd.openxmlformats-officedocument.spreadsheetml.sheet"); |
|
|
|
|
mailContent.setAttachmentVos(attachmentVoList); |
|
|
|
|
// attachmentVo.setType("application/msexcel");
|
|
|
|
|
attachmentVoList.add(attachmentVo); |
|
|
|
|
mailContent.setAttachmentVos(attachmentVoList); |
|
|
|
|
try { |
|
|
|
|
messageSenderUtil.sendMailExecutor(mailContent,sendVo); |
|
|
|
|
json.put("code", "0"); |
|
|
|
|