Showing
2 changed files
with
50 additions
and
1 deletions
| ... | ... | @@ -328,7 +328,7 @@ public class ContractDistributorStandardController extends DefaultBaseController |
| 328 | 328 | String materialProductRatioName = rawToProdRatioCodeAndNameMap.get(contractStdProcessingLineBo.getMaterialProductRatio()); |
| 329 | 329 | contractStdProcessingLineBo.setRawProductName(rawProductName); |
| 330 | 330 | contractStdProcessingLineBo.setProductName(productName); |
| 331 | - contractStdProcessingLine.setMaterialProductRatio(materialProductRatioName); | |
| 331 | + contractStdProcessingLineBo.setMaterialProductRatioName(materialProductRatioName); | |
| 332 | 332 | lineBoList.add(contractStdProcessingLineBo); |
| 333 | 333 | }); |
| 334 | 334 | |
| ... | ... | @@ -751,6 +751,55 @@ public class ContractDistributorStandardController extends DefaultBaseController |
| 751 | 751 | } |
| 752 | 752 | } |
| 753 | 753 | |
| 754 | + if (CollectionUtils.isNotEmpty(data.getContractStdProcessingLineList())) { | |
| 755 | + startRow++; | |
| 756 | + for (GetContractStdProcessingLineBo contractStdProcessingLineBo : data.getContractStdProcessingLineList()) { | |
| 757 | + setCellValue(sheet, startRow, 1, contractStdProcessingLineBo.getRawProductName() + "、" + contractStdProcessingLineBo.getRawProductGrade()); // B列 | |
| 758 | + setCellValue(sheet, startRow, 4, contractStdProcessingLineBo.getSupplyTime()); // D列 | |
| 759 | + setCellValue(sheet, startRow, 5, contractStdProcessingLineBo.getMaterialProductRatioName()); // D列 | |
| 760 | + setCellValue(sheet, startRow, 6, contractStdProcessingLineBo.getProductName()); // D列 | |
| 761 | + setCellValue(sheet, startRow, 7, contractStdProcessingLineBo.getProductGrade()); // D列 | |
| 762 | + setCellValue(sheet, startRow, 8, contractStdProcessingLineBo.getProductQuantity()); // D列 | |
| 763 | + | |
| 764 | + List<LatexFormulaExcelExporterUtil.FormulaComponent> formulaComponentList = new ArrayList<>(3); | |
| 765 | + if (contractStdProcessingLineBo.getThickness() != null) { | |
| 766 | + LatexFormulaExcelExporterUtil.FormulaComponent formulaComponent = new LatexFormulaExcelExporterUtil.FormulaComponent(); | |
| 767 | + formulaComponent.setBase(contractStdProcessingLineBo.getThickness()); | |
| 768 | + formulaComponent.setSup(contractStdProcessingLineBo.getThicknessTolPos()); | |
| 769 | + formulaComponent.setSub(contractStdProcessingLineBo.getThicknessTolNeg()); | |
| 770 | + formulaComponentList.add(formulaComponent); | |
| 771 | + } | |
| 772 | + | |
| 773 | + if (contractStdProcessingLineBo.getWidth() != null) { | |
| 774 | + LatexFormulaExcelExporterUtil.FormulaComponent formulaComponent = new LatexFormulaExcelExporterUtil.FormulaComponent(); | |
| 775 | + formulaComponent.setBase(contractStdProcessingLineBo.getWidth()); | |
| 776 | + formulaComponent.setSup(contractStdProcessingLineBo.getWidthTolPos()); | |
| 777 | + formulaComponent.setSub(contractStdProcessingLineBo.getWidthTolNeg()); | |
| 778 | + formulaComponentList.add(formulaComponent); | |
| 779 | + } | |
| 780 | + | |
| 781 | + if (contractStdProcessingLineBo.getLength() != null) { | |
| 782 | + LatexFormulaExcelExporterUtil.FormulaComponent formulaComponent = new LatexFormulaExcelExporterUtil.FormulaComponent(); | |
| 783 | + formulaComponent.setBase(contractStdProcessingLineBo.getLength()); | |
| 784 | + formulaComponent.setSup(contractStdProcessingLineBo.getLengthTolPos()); | |
| 785 | + formulaComponent.setSub(contractStdProcessingLineBo.getLengthTolNeg()); | |
| 786 | + formulaComponentList.add(formulaComponent); | |
| 787 | + } | |
| 788 | + | |
| 789 | + String latex = LatexFormulaExcelExporterUtil.convertToLatex(formulaComponentList); | |
| 790 | + if (StringUtils.isNotBlank(latex)) { | |
| 791 | + LatexFormulaExcelExporterUtil.insertLatexImageToCell(workbook, sheet, latex, startRow, 9);// E列 | |
| 792 | + } | |
| 793 | + | |
| 794 | + setCellValue(sheet, startRow, 10, contractStdProcessingLineBo.getProductStatus()); // D列 | |
| 795 | + setCellValue(sheet, startRow, 11, contractStdProcessingLineBo.getUnitPrice()); // D列 | |
| 796 | + setCellValue(sheet, startRow, 12, contractStdProcessingLineBo.getAmountExcludingTax()); // D列 | |
| 797 | + setCellValue(sheet, startRow, 13, contractStdProcessingLineBo.getTotalAmount()); // D列 | |
| 798 | + setCellValue(sheet, startRow, 14, contractStdProcessingLineBo.getDeliveryDate() != null ? | |
| 799 | + contractStdProcessingLineBo.getDeliveryDate().format(dateFormatter) : ""); // D列 | |
| 800 | + } | |
| 801 | + } | |
| 802 | + | |
| 754 | 803 | Map<String, Object> dataMap = new HashMap<>(); |
| 755 | 804 | dataMap.put("title", contractTitle); |
| 756 | 805 | dataMap.put("code", data.getCode()); | ... | ... |
No preview for this file type