开票文件

product
chuang 2 years ago
parent 1e9b2fb2af
commit bf66688753

@ -158,7 +158,7 @@ public class PurchaseorderitemServiceImpl extends ServiceImpl<PurchaseorderitemM
try {
//调用 creatSheet() 方法并传递要创建的工作表的名称
HSSFSheet sheet = workbook.createSheet("单信息");
HSSFSheet sheet = workbook.createSheet("单信息");
HSSFCellStyle cellStyle = workbook.createCellStyle();
HSSFCellStyle headLineStyle = workbook.createCellStyle();
HSSFCellStyle headStyle = workbook.createCellStyle();
@ -535,7 +535,7 @@ public class PurchaseorderitemServiceImpl extends ServiceImpl<PurchaseorderitemM
HashMap<String, Object> map = list.get(i);
if (i == 0) {
Paragraph title = section.addParagraph();
title.appendText(map.get("supplierName") + "单图片");
title.appendText(map.get("supplierName") + "单图片");
titleStr = String.valueOf(map.get("supplierName"));
title.getFormat().setHorizontalAlignment(HorizontalAlignment.Center);
title.applyStyle("titleStyle");
@ -581,7 +581,7 @@ public class PurchaseorderitemServiceImpl extends ServiceImpl<PurchaseorderitemM
}
}
//生成word文档
document.saveToFile(templateFilePath + "废钢收货单照片(" + titleStr +settlements+"吨).docx", FileFormat.Docx_2013);
document.saveToFile(templateFilePath + "废钢收货单照片(" + titleStr +settlements+"吨).docx", FileFormat.Docx_2013);
document.close();
log.warn("word文档生成成功");
}
@ -624,8 +624,8 @@ public class PurchaseorderitemServiceImpl extends ServiceImpl<PurchaseorderitemM
// List<PurchaseOrderVO> pMap = this.getPMap(pagination);
// if (pMap != null && pMap.size() > 0) {
// PurchaseOrderVO pVO = pMap.get(0);
//// 单图片地址
//// 单图片传输到指定文件夹
//// 单图片地址
//// 单图片传输到指定文件夹
//
// byte[] bytes = null;
// HttpHeaders headers = null;
@ -635,7 +635,7 @@ public class PurchaseorderitemServiceImpl extends ServiceImpl<PurchaseorderitemM
// //渲染模板参数
//// pdf模板
// Map map = new HashMap();
//// 多个单的图片信息
//// 多个单的图片信息
// ArrayList<HashMap<String, Object>> imgList = new ArrayList<>();
//// word模板
// HashMap wordHashMap = new HashMap();
@ -667,7 +667,7 @@ public class PurchaseorderitemServiceImpl extends ServiceImpl<PurchaseorderitemM
// imgMap.put("supplierNm", supplierNm);
//// 车辆图片地址
// String vehiclePictures = model.getVehiclePictures();
//// 单图片地址
//// 单图片地址
// String pictures = model.getPoundPictures();
// imgMap.put("pictures", FileCopy.getImageInfo(pictures));
// imgList.add(imgMap);
@ -681,7 +681,7 @@ public class PurchaseorderitemServiceImpl extends ServiceImpl<PurchaseorderitemM
// Section section = document.addSection();
//
// Paragraph title = section.addParagraph();
// title.appendText(map.get("supplierName") + "单图片");
// title.appendText(map.get("supplierName") + "单图片");
// ParagraphStyle style = new ParagraphStyle(document);
// style.setName("titleStyle");
// style.getCharacterFormat().setBold(true);
@ -1601,11 +1601,11 @@ public class PurchaseorderitemServiceImpl extends ServiceImpl<PurchaseorderitemM
continue;
}
}
// 单照片
// 单照片
if (model.getPoundPictures()!=null&&!model.getPoundPictures().isEmpty()){
}else {
model.setCauseError("单照片导入失败!请重新导入!");
model.setCauseError("单照片导入失败!请重新导入!");
errList.add(model);
ints.add(i);
continue;
@ -1714,7 +1714,7 @@ public class PurchaseorderitemServiceImpl extends ServiceImpl<PurchaseorderitemM
PurchaseorderDTO model = dataList.get(i);
Purchaseorder_item0Entity item0 = new Purchaseorder_item0Entity();
Long aLong2 = new DefaultIdentifierGenerator().nextId(Purchaseorder_item0Entity.class);
// 雪花算法获取单id
// 雪花算法获取单id
Long aLong1 = new DefaultIdentifierGenerator().nextId(PoundlistEntity.class);
model.setId(aLong1.toString());
// 设置id
@ -1822,7 +1822,7 @@ public class PurchaseorderitemServiceImpl extends ServiceImpl<PurchaseorderitemM
int i5 = 0;
for (PoundlistEntity model : entitys) {
PurchaseorderDTO purchaseorderDTO = dataList.get(i5);
// 生成的单编码
// 生成的单编码
ActionResult pdBillNumber = bean.getBillNumber(str1);
model.setPoundlistNo(String.valueOf(pdBillNumber.getData()));
model.setSupplierName(contractMEntities.get(0).getName());
@ -1837,7 +1837,7 @@ public class PurchaseorderitemServiceImpl extends ServiceImpl<PurchaseorderitemM
model.setSalesPrice(salesPrice.divide(settlement, 6,RoundingMode.CEILING).setScale(6, RoundingMode.HALF_UP));
// 是否审核
model.setIsExamine("1");
// 单类型
// 单类型
model.setPoundType("0");
model.setPurchaseStatus("0");
// 业务员默认当前操作人
@ -1846,7 +1846,7 @@ public class PurchaseorderitemServiceImpl extends ServiceImpl<PurchaseorderitemM
sum += poundlistMapper.insert(model);
i5++;
}
// 单逻辑
// 单逻辑
//进行数据添加
@ -1894,7 +1894,7 @@ public class PurchaseorderitemServiceImpl extends ServiceImpl<PurchaseorderitemM
map.put(17, "备注");
map.put(18, "错误原因");
map.put(19, "车辆图片地址");
map.put(20, "单图片地址");
map.put(20, "单图片地址");
map.put(21, "销售合同编码");
map.put(22, "采购合同编码");
map.put(23, "客户");

Loading…
Cancel
Save