|
@@ -948,7 +948,10 @@ public class PaymentManagementServiceImpl extends ServiceImpl<PaymentManagementM
|
|
|
sheet.setColumnWidth(28, 12 * 256 + 184);
|
|
|
sheet.setColumnWidth(29, 12 * 256 + 184);
|
|
|
sheet.setColumnWidth(30, 12 * 256 + 184);
|
|
|
- sheet.setColumnWidth(31, 1 * 256 + 184);
|
|
|
+ sheet.setColumnWidth(31, 12 * 256 + 184);
|
|
|
+ sheet.setColumnWidth(32, 12 * 256 + 184);
|
|
|
+ sheet.setColumnWidth(33, 12 * 256 + 184);
|
|
|
+ sheet.setColumnWidth(34, 1 * 256 + 184);
|
|
|
|
|
|
// 创建单元格对象
|
|
|
HSSFCell cell = null;
|
|
@@ -1030,7 +1033,12 @@ public class PaymentManagementServiceImpl extends ServiceImpl<PaymentManagementM
|
|
|
cell.setCellStyle(styleTitle);
|
|
|
cell = row0.createCell(30);
|
|
|
cell.setCellStyle(styleTitle);
|
|
|
-
|
|
|
+ cell = row0.createCell(31);
|
|
|
+ cell.setCellStyle(styleTitle);
|
|
|
+ cell = row0.createCell(32);
|
|
|
+ cell.setCellStyle(styleTitle);
|
|
|
+ cell = row0.createCell(33);
|
|
|
+ cell.setCellStyle(styleTitle);
|
|
|
rownum++;
|
|
|
|
|
|
HSSFRow row1 = sheet.createRow((int) rownum);
|
|
@@ -1057,72 +1065,81 @@ public class PaymentManagementServiceImpl extends ServiceImpl<PaymentManagementM
|
|
|
cell.setCellValue("供应商");
|
|
|
cell.setCellStyle(styleDetail);
|
|
|
cell = row1.createCell(8);
|
|
|
- cell.setCellValue("货名");
|
|
|
+ cell.setCellValue("初检员");
|
|
|
cell.setCellStyle(styleDetail);
|
|
|
cell = row1.createCell(9);
|
|
|
- cell.setCellValue("类型");
|
|
|
+ cell.setCellValue("复检员");
|
|
|
cell.setCellStyle(styleDetail);
|
|
|
cell = row1.createCell(10);
|
|
|
- cell.setCellValue("等级");
|
|
|
+ cell.setCellValue("检斤员");
|
|
|
cell.setCellStyle(styleDetail);
|
|
|
cell = row1.createCell(11);
|
|
|
- cell.setCellValue("水分");
|
|
|
+ cell.setCellValue("货名");
|
|
|
cell.setCellStyle(styleDetail);
|
|
|
cell = row1.createCell(12);
|
|
|
- cell.setCellValue("杂质");
|
|
|
+ cell.setCellValue("类型");
|
|
|
cell.setCellStyle(styleDetail);
|
|
|
cell = row1.createCell(13);
|
|
|
- cell.setCellValue("霉变粒");
|
|
|
+ cell.setCellValue("等级");
|
|
|
cell.setCellStyle(styleDetail);
|
|
|
cell = row1.createCell(14);
|
|
|
- cell.setCellValue("不完善粒");
|
|
|
+ cell.setCellValue("水分");
|
|
|
cell.setCellStyle(styleDetail);
|
|
|
cell = row1.createCell(15);
|
|
|
- cell.setCellValue("容重");
|
|
|
+ cell.setCellValue("杂质");
|
|
|
cell.setCellStyle(styleDetail);
|
|
|
cell = row1.createCell(16);
|
|
|
- cell.setCellValue("热损伤");
|
|
|
+ cell.setCellValue("霉变粒");
|
|
|
cell.setCellStyle(styleDetail);
|
|
|
cell = row1.createCell(17);
|
|
|
- cell.setCellValue("车牌号");
|
|
|
+ cell.setCellValue("不完善粒");
|
|
|
cell.setCellStyle(styleDetail);
|
|
|
cell = row1.createCell(18);
|
|
|
- cell.setCellValue("净重单价");
|
|
|
+ cell.setCellValue("容重");
|
|
|
cell.setCellStyle(styleDetail);
|
|
|
cell = row1.createCell(19);
|
|
|
- cell.setCellValue("毛重");
|
|
|
+ cell.setCellValue("热损伤");
|
|
|
cell.setCellStyle(styleDetail);
|
|
|
cell = row1.createCell(20);
|
|
|
- cell.setCellValue("皮重");
|
|
|
+ cell.setCellValue("车牌号");
|
|
|
cell.setCellStyle(styleDetail);
|
|
|
cell = row1.createCell(21);
|
|
|
- cell.setCellValue("扣重");
|
|
|
+ cell.setCellValue("净重单价");
|
|
|
cell.setCellStyle(styleDetail);
|
|
|
cell = row1.createCell(22);
|
|
|
- cell.setCellValue("净重");
|
|
|
+ cell.setCellValue("毛重");
|
|
|
cell.setCellStyle(styleDetail);
|
|
|
cell = row1.createCell(23);
|
|
|
- cell.setCellValue("扣单价");
|
|
|
+ cell.setCellValue("皮重");
|
|
|
cell.setCellStyle(styleDetail);
|
|
|
cell = row1.createCell(24);
|
|
|
- cell.setCellValue("纯重单价");
|
|
|
+ cell.setCellValue("扣重");
|
|
|
cell.setCellStyle(styleDetail);
|
|
|
cell = row1.createCell(25);
|
|
|
- cell.setCellValue("纯重");
|
|
|
+ cell.setCellValue("净重");
|
|
|
cell.setCellStyle(styleDetail);
|
|
|
cell = row1.createCell(26);
|
|
|
- cell.setCellValue("合计应付");
|
|
|
+ cell.setCellValue("扣单价");
|
|
|
cell.setCellStyle(styleDetail);
|
|
|
cell = row1.createCell(27);
|
|
|
- cell.setCellValue("实付金额");
|
|
|
+ cell.setCellValue("纯重单价");
|
|
|
cell.setCellStyle(styleDetail);
|
|
|
cell = row1.createCell(28);
|
|
|
- cell.setCellValue("姓名");
|
|
|
+ cell.setCellValue("纯重");
|
|
|
cell.setCellStyle(styleDetail);
|
|
|
cell = row1.createCell(29);
|
|
|
- cell.setCellValue("卡号");
|
|
|
+ cell.setCellValue("合计应付");
|
|
|
cell.setCellStyle(styleDetail);
|
|
|
cell = row1.createCell(30);
|
|
|
+ cell.setCellValue("实付金额");
|
|
|
+ cell.setCellStyle(styleDetail);
|
|
|
+ cell = row1.createCell(31);
|
|
|
+ cell.setCellValue("姓名");
|
|
|
+ cell.setCellStyle(styleDetail);
|
|
|
+ cell = row1.createCell(32);
|
|
|
+ cell.setCellValue("卡号");
|
|
|
+ cell.setCellStyle(styleDetail);
|
|
|
+ cell = row1.createCell(33);
|
|
|
cell.setCellValue("开户支行");
|
|
|
cell.setCellStyle(styleDetail);
|
|
|
|
|
@@ -1139,7 +1156,6 @@ public class PaymentManagementServiceImpl extends ServiceImpl<PaymentManagementM
|
|
|
Double imperfectGrainTotal = 0d;//不完善粒合计
|
|
|
Double bulkDensityTotal = 0d;//容重合计
|
|
|
Double jiaorenliTotal = 0d;//热损伤合计
|
|
|
- Double netWeightPriceTotal = 0d;//单价合计
|
|
|
Double netWeightTotal = 0d;//净重合计
|
|
|
Double amountIngPayableTotal = 0d;//应收合计
|
|
|
for (int i = 0; i < paymentManagement.getPaymentManagementList().size(); i++) {
|
|
@@ -1150,6 +1166,11 @@ public class PaymentManagementServiceImpl extends ServiceImpl<PaymentManagementM
|
|
|
.eq("relation_id", paymentManagement1.getRelationId())
|
|
|
.eq("comp_id", paymentManagement1.getCompId())
|
|
|
));
|
|
|
+ paymentManagement1.setWeighingManagement(weighingManagementService.selectOne(
|
|
|
+ new EntityWrapper<WeighingManagement>()
|
|
|
+ .eq("relation_id", paymentManagement1.getRelationId())
|
|
|
+ .eq("comp_id", paymentManagement1.getCompId())
|
|
|
+ ));
|
|
|
HSSFRow rowx = sheet.createRow((int) rownum);
|
|
|
rowx.setHeightInPoints(20);
|
|
|
cell = rowx.createCell(1);
|
|
@@ -1175,38 +1196,47 @@ public class PaymentManagementServiceImpl extends ServiceImpl<PaymentManagementM
|
|
|
cell.setCellValue(editString(paymentManagement1.getIdentityAuthenticationInfo().getSupplier()));
|
|
|
cell.setCellStyle(styleDetail);
|
|
|
cell = rowx.createCell(8);
|
|
|
- cell.setCellValue(editString(paymentManagement1.getGoodsName()));
|
|
|
+ cell.setCellValue(editString(paymentManagement1.getQualityInspectionManagement().getQualityInspector()));
|
|
|
cell.setCellStyle(styleDetail);
|
|
|
cell = rowx.createCell(9);
|
|
|
- cell.setCellValue(editString(paymentManagement1.getType()));
|
|
|
+ cell.setCellValue(editString(paymentManagement1.getQualityInspectionManagement().getReInspector()));
|
|
|
cell.setCellStyle(styleDetail);
|
|
|
cell = rowx.createCell(10);
|
|
|
+ cell.setCellValue(editString(paymentManagement1.getWeighingManagement().getSkinInspector()));
|
|
|
+ cell.setCellStyle(styleDetail);
|
|
|
+ cell = rowx.createCell(11);
|
|
|
+ cell.setCellValue(editString(paymentManagement1.getGoodsName()));
|
|
|
+ cell.setCellStyle(styleDetail);
|
|
|
+ cell = rowx.createCell(12);
|
|
|
+ cell.setCellValue(editString(paymentManagement1.getType()));
|
|
|
+ cell.setCellStyle(styleDetail);
|
|
|
+ cell = rowx.createCell(13);
|
|
|
cell.setCellValue(editString(paymentManagement1.getQualityInspectionManagement().getGrade()));
|
|
|
cell.setCellStyle(styleDetail);
|
|
|
HSSFDataFormat df = wb.createDataFormat(); // 此处设置数据格式
|
|
|
contextstyle.setDataFormat(df.getBuiltinFormat("#,##0.00"));//保留两位小数点
|
|
|
- cell = rowx.createCell(11);
|
|
|
+ cell = rowx.createCell(14);
|
|
|
cell.setCellValue(Double.parseDouble(paymentManagement1.getQualityInspectionManagement().getWaterContent()!=null?paymentManagement1.getQualityInspectionManagement().getWaterContent():"0"));
|
|
|
cell.setCellStyle(contextstyle);
|
|
|
- cell = rowx.createCell(12);
|
|
|
+ cell = rowx.createCell(15);
|
|
|
cell.setCellValue(Double.parseDouble(paymentManagement1.getQualityInspectionManagement().getImpurity()!=null?paymentManagement1.getQualityInspectionManagement().getImpurity():"0"));
|
|
|
cell.setCellStyle(contextstyle);
|
|
|
- cell = rowx.createCell(13);
|
|
|
+ cell = rowx.createCell(16);
|
|
|
cell.setCellValue(Double.parseDouble(paymentManagement1.getQualityInspectionManagement().getMildewGrain()!=null?paymentManagement1.getQualityInspectionManagement().getMildewGrain():"0"));
|
|
|
cell.setCellStyle(contextstyle);
|
|
|
- cell = rowx.createCell(14);
|
|
|
+ cell = rowx.createCell(17);
|
|
|
cell.setCellValue(Double.parseDouble(paymentManagement1.getQualityInspectionManagement().getImperfectGrain()!=null?paymentManagement1.getQualityInspectionManagement().getImperfectGrain():"0"));
|
|
|
cell.setCellStyle(contextstyle);
|
|
|
- cell = rowx.createCell(15);
|
|
|
+ cell = rowx.createCell(18);
|
|
|
cell.setCellValue(Double.parseDouble(paymentManagement1.getQualityInspectionManagement().getBulkDensity()!=null?paymentManagement1.getQualityInspectionManagement().getBulkDensity():"0"));
|
|
|
cell.setCellStyle(contextstyle);
|
|
|
- cell = rowx.createCell(16);
|
|
|
+ cell = rowx.createCell(19);
|
|
|
cell.setCellValue(Double.parseDouble(paymentManagement1.getQualityInspectionManagement().getJiaorenli()!=null?paymentManagement1.getQualityInspectionManagement().getJiaorenli():"0"));
|
|
|
cell.setCellStyle(contextstyle);
|
|
|
- cell = rowx.createCell(17);
|
|
|
+ cell = rowx.createCell(20);
|
|
|
cell.setCellValue(editString(paymentManagement1.getCarNo()));
|
|
|
cell.setCellStyle(styleDetail);
|
|
|
- cell = rowx.createCell(18);
|
|
|
+ cell = rowx.createCell(21);
|
|
|
// if("潮粮".equals(paymentManagement1.getType())){
|
|
|
// cell.setCellValue(new Formatter().format("%.3f", editFloat(paymentManagement1.getTidalGrainPrice())).toString());
|
|
|
//
|
|
@@ -1217,40 +1247,40 @@ public class PaymentManagementServiceImpl extends ServiceImpl<PaymentManagementM
|
|
|
// }
|
|
|
cell.setCellValue(new Formatter().format("%.3f", editFloat(paymentManagement1.getTidalGrainPrice())).toString());
|
|
|
cell.setCellStyle(styleDetail);
|
|
|
- cell = rowx.createCell(19);
|
|
|
+ cell = rowx.createCell(22);
|
|
|
cell.setCellValue(editFloat(paymentManagement1.getGrossWeight()));
|
|
|
cell.setCellStyle(styleDetail);
|
|
|
- cell = rowx.createCell(20);
|
|
|
+ cell = rowx.createCell(23);
|
|
|
cell.setCellValue(editFloat(paymentManagement1.getTare()));
|
|
|
cell.setCellStyle(styleDetail);
|
|
|
- cell = rowx.createCell(21);
|
|
|
+ cell = rowx.createCell(24);
|
|
|
cell.setCellValue(new Formatter().format("%.2f", editFloat(paymentManagement1.getWeightDeduction())).toString());
|
|
|
cell.setCellStyle(styleDetail);
|
|
|
- cell = rowx.createCell(22);
|
|
|
+ cell = rowx.createCell(25);
|
|
|
cell.setCellValue(editFloat(paymentManagement1.getNetWeight()));
|
|
|
cell.setCellStyle(styleDetail);
|
|
|
- cell = rowx.createCell(23);
|
|
|
+ cell = rowx.createCell(26);
|
|
|
cell.setCellValue(editDouble(paymentManagement1.getUnitDeduction()));
|
|
|
cell.setCellStyle(styleDetail);
|
|
|
- cell = rowx.createCell(24);
|
|
|
+ cell = rowx.createCell(27);
|
|
|
cell.setCellValue(new Formatter().format("%.2f", editFloat(paymentManagement1.getSolidGrainPrice())).toString());
|
|
|
cell.setCellStyle(styleDetail);
|
|
|
- cell = rowx.createCell(25);
|
|
|
+ cell = rowx.createCell(28);
|
|
|
cell.setCellValue(editFloat(paymentManagement1.getPureWeight()));
|
|
|
cell.setCellStyle(styleDetail);
|
|
|
- cell = rowx.createCell(26);
|
|
|
+ cell = rowx.createCell(29);
|
|
|
cell.setCellValue(editDouble(paymentManagement1.getAmountIngPayable()));
|
|
|
cell.setCellStyle(styleDetail);
|
|
|
- cell = rowx.createCell(27);
|
|
|
+ cell = rowx.createCell(30);
|
|
|
cell.setCellValue(editDouble(paymentManagement1.getAmountEdPayable()));
|
|
|
cell.setCellStyle(styleDetail);
|
|
|
- cell = rowx.createCell(28);
|
|
|
+ cell = rowx.createCell(31);
|
|
|
cell.setCellValue(editString(paymentManagement1.getCustomerName()));
|
|
|
cell.setCellStyle(styleDetail);
|
|
|
- cell = rowx.createCell(29);
|
|
|
+ cell = rowx.createCell(32);
|
|
|
cell.setCellValue(editString(paymentManagement1.getIdentityAuthenticationInfo().getBankCard()));
|
|
|
cell.setCellStyle(styleDetail);
|
|
|
- cell = rowx.createCell(30);
|
|
|
+ cell = rowx.createCell(33);
|
|
|
cell.setCellValue(editString(paymentManagement1.getIdentityAuthenticationInfo().getBankDeposit() + "-" +paymentManagement1.getIdentityAuthenticationInfo().getBankDepositBranch()));
|
|
|
cell.setCellStyle(styleDetail);
|
|
|
|
|
@@ -1261,7 +1291,7 @@ public class PaymentManagementServiceImpl extends ServiceImpl<PaymentManagementM
|
|
|
imperfectGrainTotal = imperfectGrainTotal + ((Double.valueOf(String.valueOf(paymentManagement1.getQualityInspectionManagement().getImperfectGrain()!=null?paymentManagement1.getQualityInspectionManagement().getImperfectGrain():"0"))) * (Double.valueOf(String.valueOf(paymentManagement1.getNetWeight()))));
|
|
|
bulkDensityTotal = bulkDensityTotal + ((Double.valueOf(String.valueOf(paymentManagement1.getQualityInspectionManagement().getBulkDensity()!=null?paymentManagement1.getQualityInspectionManagement().getBulkDensity():"0"))) * (Double.valueOf(String.valueOf(paymentManagement1.getNetWeight()))));
|
|
|
jiaorenliTotal = jiaorenliTotal + ((Double.valueOf(String.valueOf(paymentManagement1.getQualityInspectionManagement().getJiaorenli()!=null?paymentManagement1.getQualityInspectionManagement().getJiaorenli():"0"))) * (Double.valueOf(String.valueOf(paymentManagement1.getNetWeight()))));
|
|
|
- netWeightPriceTotal = netWeightPriceTotal + (Double.valueOf(String.valueOf(paymentManagement1.getTidalGrainPrice())));
|
|
|
+// netWeightPriceTotal = netWeightPriceTotal + (Double.valueOf(String.valueOf(paymentManagement1.getTidalGrainPrice())));
|
|
|
netWeightTotal = netWeightTotal + (Double.valueOf(String.valueOf(paymentManagement1.getNetWeight())));
|
|
|
amountIngPayableTotal = amountIngPayableTotal + paymentManagement1.getAmountIngPayable();
|
|
|
|
|
@@ -1269,34 +1299,84 @@ public class PaymentManagementServiceImpl extends ServiceImpl<PaymentManagementM
|
|
|
}
|
|
|
HSSFRow rowp = sheet.createRow((int)(rownum));
|
|
|
rowp.setHeightInPoints(20);
|
|
|
-
|
|
|
- //水分平均值
|
|
|
+ cell = rowp.createCell(1);
|
|
|
+ cell.setCellValue("平均值/合计");
|
|
|
+ cell.setCellStyle(styleDetail);
|
|
|
+ cell = rowp.createCell(2);
|
|
|
+ cell.setCellStyle(styleDetail);
|
|
|
+ cell = rowp.createCell(3);
|
|
|
+ cell.setCellStyle(styleDetail);
|
|
|
+ cell = rowp.createCell(4);
|
|
|
+ cell.setCellStyle(styleDetail);
|
|
|
+ cell = rowp.createCell(5);
|
|
|
+ cell.setCellStyle(styleDetail);
|
|
|
+ cell = rowp.createCell(6);
|
|
|
+ cell.setCellStyle(styleDetail);
|
|
|
+ cell = rowp.createCell(7);
|
|
|
+ cell.setCellStyle(styleDetail);
|
|
|
+ cell = rowp.createCell(8);
|
|
|
+ cell.setCellStyle(styleDetail);
|
|
|
+ cell = rowp.createCell(9);
|
|
|
+ cell.setCellStyle(styleDetail);
|
|
|
+ cell = rowp.createCell(10);
|
|
|
+ cell.setCellStyle(styleDetail);
|
|
|
cell = rowp.createCell(11);
|
|
|
- cell.setCellStyle(contextstyle);
|
|
|
- cell.setCellValue(waterContentTotal/netWeightTotal);
|
|
|
+ cell.setCellStyle(styleDetail);
|
|
|
cell = rowp.createCell(12);
|
|
|
+ cell.setCellStyle(styleDetail);
|
|
|
+ cell = rowp.createCell(13);
|
|
|
+ cell.setCellStyle(styleDetail);
|
|
|
+ //水分平均值
|
|
|
+ cell = rowp.createCell(14);
|
|
|
+ cell.setCellValue(waterContentTotal/netWeightTotal);
|
|
|
+ cell.setCellStyle(contextstyle);
|
|
|
+ cell = rowp.createCell(15);
|
|
|
cell.setCellValue(impurityTotal/netWeightTotal);
|
|
|
cell.setCellStyle(contextstyle);
|
|
|
- cell = rowp.createCell(13);
|
|
|
+ cell = rowp.createCell(16);
|
|
|
cell.setCellValue(mildewGrainTotal/netWeightTotal);
|
|
|
cell.setCellStyle(contextstyle);
|
|
|
- cell = rowp.createCell(14);
|
|
|
+ cell = rowp.createCell(17);
|
|
|
cell.setCellValue(imperfectGrainTotal/netWeightTotal);
|
|
|
cell.setCellStyle(contextstyle);
|
|
|
- cell = rowp.createCell(15);
|
|
|
+ cell = rowp.createCell(18);
|
|
|
cell.setCellValue(bulkDensityTotal/netWeightTotal);
|
|
|
cell.setCellStyle(contextstyle);
|
|
|
- cell = rowp.createCell(16);
|
|
|
+ cell = rowp.createCell(19);
|
|
|
cell.setCellValue(jiaorenliTotal/netWeightTotal);
|
|
|
cell.setCellStyle(contextstyle);
|
|
|
- cell = rowp.createCell(18);
|
|
|
- cell.setCellValue(netWeightPriceTotal/paymentManagement.getPaymentManagementList().size());
|
|
|
+ cell = rowp.createCell(20);
|
|
|
+ cell.setCellStyle(styleDetail);
|
|
|
+ cell = rowp.createCell(21);
|
|
|
+ cell.setCellValue(amountIngPayableTotal/netWeightTotal);
|
|
|
cell.setCellStyle(contextstyle);
|
|
|
- //净重合计
|
|
|
cell = rowp.createCell(22);
|
|
|
+ cell.setCellStyle(styleDetail);
|
|
|
+ cell = rowp.createCell(23);
|
|
|
+ cell.setCellStyle(styleDetail);
|
|
|
+ cell = rowp.createCell(24);
|
|
|
+ cell.setCellStyle(styleDetail);
|
|
|
+ //净重合计
|
|
|
+ cell = rowp.createCell(25);
|
|
|
cell.setCellValue(netWeightTotal);
|
|
|
+ cell.setCellStyle(styleDetail);
|
|
|
cell = rowp.createCell(26);
|
|
|
+ cell.setCellStyle(styleDetail);
|
|
|
+ cell = rowp.createCell(27);
|
|
|
+ cell.setCellStyle(styleDetail);
|
|
|
+ cell = rowp.createCell(28);
|
|
|
+ cell.setCellStyle(styleDetail);
|
|
|
+ cell = rowp.createCell(29);
|
|
|
cell.setCellValue(amountIngPayableTotal);
|
|
|
+ cell.setCellStyle(styleDetail);
|
|
|
+ cell = rowp.createCell(30);
|
|
|
+ cell.setCellStyle(styleDetail);
|
|
|
+ cell = rowp.createCell(31);
|
|
|
+ cell.setCellStyle(styleDetail);
|
|
|
+ cell = rowp.createCell(32);
|
|
|
+ cell.setCellStyle(styleDetail);
|
|
|
+ cell = rowp.createCell(33);
|
|
|
+ cell.setCellStyle(styleDetail);
|
|
|
}
|
|
|
|
|
|
|