Browse Source

Merge branch 'master' of http://62.234.61.92:3000/wjm/mec-cloud_IntelligentManufacturing_CLIENT

lph 1 năm trước cách đây
mục cha
commit
fb69b7f2ad

+ 8 - 5
zkqy-common/src/main/java/com/zkqy/common/utils/poi/ExcelUtil.java

@@ -1160,12 +1160,15 @@ public class ExcelUtil<T> {
                 if (hearKeys.size() < fields.size()) {  // 设置表头最后一个单元格夸列
                     int difference = Math.abs(hearKeys.size() - fields.size());
                     CellRangeAddress cellRange = new CellRangeAddress(i, i, hearKeys.size() - 1, fields.size() - 1);
+
                     sheet.addMergedRegion(cellRange);
-                    // 合并后,设置合并区域的边框样式
-                    RegionUtil.setBorderBottom(BorderStyle.THIN, cellRange, sheet);
-                    RegionUtil.setBorderTop(BorderStyle.THIN, cellRange, sheet);
-                    RegionUtil.setBorderLeft(BorderStyle.THIN, cellRange, sheet);
-                    RegionUtil.setBorderRight(BorderStyle.THIN, cellRange, sheet);
+                    // 合并后,设置合并区域的边框样式 -》 如果只有一个标题单元格不设置边框
+                    if (hearKeys.size() > 1) {
+                        RegionUtil.setBorderBottom(BorderStyle.THIN, cellRange, sheet);
+                        RegionUtil.setBorderTop(BorderStyle.THIN, cellRange, sheet);
+                        RegionUtil.setBorderLeft(BorderStyle.THIN, cellRange, sheet);
+                        RegionUtil.setBorderRight(BorderStyle.THIN, cellRange, sheet);
+                    }
                 }
                 integerStringMap.clear();
             }

+ 46 - 31
zkqy-custom-business/src/main/java/com/zkqy/business/controller/ProductInvoiceController.java

@@ -1,17 +1,15 @@
 package com.zkqy.business.controller;
 
+import java.util.ArrayList;
+import java.util.HashMap;
 import java.util.List;
+import java.util.Map;
 import javax.servlet.http.HttpServletResponse;
 
-import com.zkqy.common.core.domain.entity.SysRole;
-import com.zkqy.common.utils.SecurityUtils;
+import com.zkqy.business.domain.vo.ProductInvoiceFinancialExportVo;
 import io.swagger.annotations.Api;
 import io.swagger.annotations.ApiOperation;
-import org.springframework.security.access.prepost.PreAuthorize;
 import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.security.core.Authentication;
-import org.springframework.security.core.context.SecurityContextHolder;
-import org.springframework.security.core.userdetails.User;
 import org.springframework.web.bind.annotation.*;
 import com.zkqy.common.annotation.Log;
 import com.zkqy.common.core.controller.BaseController;
@@ -31,19 +29,17 @@ import com.zkqy.common.core.page.TableDataInfo;
 @RestController
 @RequestMapping("/system/ProductInvoice")
 @Api(value = "/system/ProductInvoice", description = "产品发货单-接口")
-public class ProductInvoiceController extends BaseController
-{
+public class ProductInvoiceController extends BaseController {
     @Autowired
     private IProductInvoiceService productInvoiceService;
 
-/**
- * 查询产品发货单列表
- */
+    /**
+     * 查询产品发货单列表
+     */
 //@PreAuthorize("@ss.hasPermi('system:ProductInvoice:list')")
-@GetMapping("/list")
-@ApiOperation(value = "查询产品发货单列表")
-    public TableDataInfo list(ProductInvoice productInvoice)
-    {
+    @GetMapping("/list")
+    @ApiOperation(value = "查询产品发货单列表")
+    public TableDataInfo list(ProductInvoice productInvoice) {
         startPage();
         List<ProductInvoice> list = productInvoiceService.selectProductInvoiceList(productInvoice);
         return getDataTable(list);
@@ -56,8 +52,7 @@ public class ProductInvoiceController extends BaseController
     @Log(title = "产品发货单", businessType = BusinessType.EXPORT)
     @PostMapping("/export")
     @ApiOperation(value = "导出产品发货单列表")
-    public void export(HttpServletResponse response, ProductInvoice productInvoice)
-    {
+    public void export(HttpServletResponse response, ProductInvoice productInvoice) {
         List<ProductInvoice> list = productInvoiceService.selectProductInvoiceList(productInvoice);
         ExcelUtil<ProductInvoice> util = new ExcelUtil<ProductInvoice>(ProductInvoice.class);
         util.exportExcel(response, list, "产品发货单数据");
@@ -69,8 +64,7 @@ public class ProductInvoiceController extends BaseController
 //    @PreAuthorize("@ss.hasPermi('system:ProductInvoice:query')")
     @GetMapping(value = "/{id}")
     @ApiOperation(value = "获取产品发货单详细信息")
-    public AjaxResult getInfo(@PathVariable("id") Long id)
-    {
+    public AjaxResult getInfo(@PathVariable("id") Long id) {
         return success(productInvoiceService.selectProductInvoiceById(id));
     }
 
@@ -81,8 +75,7 @@ public class ProductInvoiceController extends BaseController
     @Log(title = "产品发货单", businessType = BusinessType.INSERT)
     @PostMapping
     @ApiOperation(value = "新增产品发货单")
-    public AjaxResult add(@RequestBody ProductInvoice productInvoice)
-    {
+    public AjaxResult add(@RequestBody ProductInvoice productInvoice) {
         return toAjax(productInvoiceService.insertProductInvoice(productInvoice));
     }
 
@@ -93,8 +86,7 @@ public class ProductInvoiceController extends BaseController
     @Log(title = "产品发货单", businessType = BusinessType.UPDATE)
     @PutMapping
     @ApiOperation(value = "修改产品发货单")
-    public AjaxResult edit(@RequestBody ProductInvoice productInvoice)
-    {
+    public AjaxResult edit(@RequestBody ProductInvoice productInvoice) {
         return toAjax(productInvoiceService.updateProductInvoice(productInvoice));
     }
 
@@ -105,8 +97,7 @@ public class ProductInvoiceController extends BaseController
     @Log(title = "产品发货单", businessType = BusinessType.DELETE)
     @DeleteMapping("/{ids}")
     @ApiOperation(value = "删除产品发货单")
-    public AjaxResult remove(@PathVariable Long[] ids)
-    {
+    public AjaxResult remove(@PathVariable Long[] ids) {
         return toAjax(productInvoiceService.deleteProductInvoiceByIds(ids));
     }
 
@@ -114,8 +105,7 @@ public class ProductInvoiceController extends BaseController
      * 查询发货单货品信息/销售单&零售单
      */
     @GetMapping("/productInvoiceInfo")
-    public AjaxResult productInvoiceInfo(@RequestParam("saleOrderNo") String saleOrderNo)
-    {
+    public AjaxResult productInvoiceInfo(@RequestParam("saleOrderNo") String saleOrderNo) {
         return success(productInvoiceService.productInvoiceInfo(saleOrderNo));
     }
 
@@ -123,8 +113,7 @@ public class ProductInvoiceController extends BaseController
      * 查询发货单货品信息
      */
     @GetMapping("/saleStorageDetails")
-    public AjaxResult saleStorageDetails(@RequestParam("id") Long id)
-    {
+    public AjaxResult saleStorageDetails(@RequestParam("id") Long id) {
         return success(productInvoiceService.saleStorageDetails(id));
     }
 
@@ -132,9 +121,35 @@ public class ProductInvoiceController extends BaseController
      * 打印发货单、送货单、财务对账单接口
      */
     @GetMapping("/printDocuments")
-    public AjaxResult printDocuments(@RequestParam("id") Long id)
-    {
+    public AjaxResult printDocuments(@RequestParam("id") Long id) {
         return success(productInvoiceService.printDocuments(id));
     }
 
+    @GetMapping("/financialStatementList")
+    @ApiOperation(value = "查询财务对账单列表")
+    public TableDataInfo financialStatementList(ProductInvoiceFinancialExportVo productInvoiceFinancialExportVo) {
+        startPage();
+        List<Map<String, Object>> list = new ArrayList<>();
+        if (productInvoiceFinancialExportVo.getOrderType().equals("retailOrder")) {  // 零售单
+            list.addAll(productInvoiceService.financialStatementList(productInvoiceFinancialExportVo));
+        } else if (productInvoiceFinancialExportVo.getOrderType().equals("contractOrder")) {  // 合同单
+            list.addAll(productInvoiceService.financialStatementList(productInvoiceFinancialExportVo));
+        }
+        return getDataTable(list);
+    }
+
+    @PostMapping("/importFinancialStatement")
+    public void importDataOutboundDetails(HttpServletResponse response, ProductInvoiceFinancialExportVo productInvoiceFinancialExportVo) {
+        // 查询需要需要导出的待物对账单
+        List<ProductInvoiceFinancialExportVo> list = productInvoiceService.financialStatementExportList(productInvoiceFinancialExportVo);
+        if (list.size() != 0) {
+            ExcelUtil<ProductInvoiceFinancialExportVo> util = new ExcelUtil<ProductInvoiceFinancialExportVo>(ProductInvoiceFinancialExportVo.class);
+            Map<Integer, String> map = new HashMap<>();
+            map.put(0, "销售客户汇总");
+            List<Map<Integer, String>> mapList = new ArrayList<>();
+            mapList.add(map);
+            util.addCustomHeaderData(mapList);
+            util.exportExcel(response, list, "出库明细");
+        }
+    }
 }

+ 192 - 151
zkqy-custom-business/src/main/java/com/zkqy/business/domain/ProductInvoice.java

@@ -1,6 +1,7 @@
 package com.zkqy.business.domain;
 
 import java.util.Date;
+
 import com.fasterxml.jackson.annotation.JsonFormat;
 import com.zkqy.common.core.domain.BaseEntity;
 import org.apache.commons.lang3.builder.ToStringBuilder;
@@ -9,312 +10,352 @@ import com.zkqy.common.annotation.Excel;
 
 /**
  * 产品发货单对象 product_invoice
- * 
+ *
  * @author zkqy
  * @date 2024-04-11
  */
-public class ProductInvoice extends BaseEntity
-{
+public class ProductInvoice extends BaseEntity {
     private static final long serialVersionUID = 1L;
 
-    /** 编号 */
+    private String orderType;
+
+    public String getOrderType() {
+        return orderType;
+    }
+
+    public void setOrderType(String orderType) {
+        this.orderType = orderType;
+    }
+
+    /**
+     * 编号
+     */
     private Long id;
 
-    /** 通知单号 */
+    /**
+     * 通知单号
+     */
     @Excel(name = "通知单号")
     private String noticeNumber;
 
-    /** 通知日期 */
+    /**
+     * 通知日期
+     */
     @JsonFormat(pattern = "yyyy-MM-dd")
     @Excel(name = "通知日期", width = 30, dateFormat = "yyyy-MM-dd")
     private Date noticeDate;
 
-    /** 销售员 */
+    /**
+     * 销售员
+     */
     @Excel(name = "销售员")
     private String salesman;
 
-    /** 客户编号 */
+    /**
+     * 客户编号
+     */
     @Excel(name = "客户编号")
     private Long customerId;
 
-    /** 客户名称 */
+    /**
+     * 客户名称
+     */
     private String customerName;
 
-    /** 开票员 */
+    /**
+     * 开票员
+     */
     @Excel(name = "开票员")
     private String drawer;
 
-    /** 发货单备注 */
+    /**
+     * 发货单备注
+     */
     @Excel(name = "发货单备注")
     private String dispatchNoteRemark;
 
-    /** 开票类型 */
+    /**
+     * 开票类型
+     */
     @Excel(name = "开票类型")
     private String billingType;
 
-    /** 货车登记 */
+    /**
+     * 货车登记
+     */
     @Excel(name = "货车登记")
     private String truckRegistration;
 
-    /** 单据类型 */
+    /**
+     * 单据类型
+     */
     @Excel(name = "单据类型")
     private String documentType;
 
-    /** 售货单位 */
+    /**
+     * 售货单位
+     */
     @Excel(name = "售货单位")
     private String sellingUnit;
 
-    /** 计算类型(未启用) */
+    /**
+     * 计算类型(未启用)
+     */
     @Excel(name = "计算类型", readConverterExp = "未=启用")
     private String calculationType;
 
-    /** 审核意见 */
+    /**
+     * 审核意见
+     */
     @Excel(name = "审核意见")
     private String auditOpinion;
 
-    /** 状态 */
+    /**
+     * 状态
+     */
     @Excel(name = "状态")
     private String status;
 
-    /** 销售单合同号 */
+    /**
+     * 销售单合同号
+     */
     @Excel(name = "销售单合同号")
     private String saleOrderNo;
 
-    /** 备用列 */
+    /**
+     * 备用列
+     */
     @Excel(name = "备用列")
     private String spare1;
 
-    /** 备用列 */
+    /**
+     * 备用列
+     */
     @Excel(name = "备用列")
     private String spare2;
 
-    /** 备用列 */
+    /**
+     * 备用列
+     */
     @Excel(name = "备用列")
     private String spare3;
 
-    /** 备用列 */
+    /**
+     * 备用列
+     */
     @Excel(name = "备用列")
     private String spare4;
 
-    /** 删除标志(0:否;2:是) */
+    /**
+     * 删除标志(0:否;2:是)
+     */
     private String delFlag;
 
-    /** 创建者ID */
+    /**
+     * 创建者ID
+     */
     private Long createById;
 
-    /** 修改者ID */
+    /**
+     * 修改者ID
+     */
     private Long updateById;
 
-    /** 发货仓库 */
+    /**
+     * 发货仓库
+     */
     private Long deliveryWarehouse;
 
-    /** 调拨仓库 */
+    /**
+     * 调拨仓库
+     */
     private Long transferWarehouse;
 
-    /** 发货日期 */
+    /**
+     * 发货日期
+     */
     @JsonFormat(pattern = "yyyy-MM-dd")
     @Excel(name = "发货日期", width = 30, dateFormat = "yyyy-MM-dd")
     private Date deliveryDate;
 
-    /** 发货员 */
+    /**
+     * 发货员
+     */
     private String deliveryClerk;
 
-    public void setId(Long id) 
-    {
+    public void setId(Long id) {
         this.id = id;
     }
 
-    public Long getId() 
-    {
+    public Long getId() {
         return id;
     }
-    public void setNoticeNumber(String noticeNumber) 
-    {
+
+    public void setNoticeNumber(String noticeNumber) {
         this.noticeNumber = noticeNumber;
     }
 
-    public String getNoticeNumber() 
-    {
+    public String getNoticeNumber() {
         return noticeNumber;
     }
-    public void setNoticeDate(Date noticeDate) 
-    {
+
+    public void setNoticeDate(Date noticeDate) {
         this.noticeDate = noticeDate;
     }
 
-    public Date getNoticeDate() 
-    {
+    public Date getNoticeDate() {
         return noticeDate;
     }
-    public void setSalesman(String salesman) 
-    {
+
+    public void setSalesman(String salesman) {
         this.salesman = salesman;
     }
 
-    public String getSalesman() 
-    {
+    public String getSalesman() {
         return salesman;
     }
-    public void setCustomerId(Long customerId) 
-    {
+
+    public void setCustomerId(Long customerId) {
         this.customerId = customerId;
     }
 
-    public Long getCustomerId() 
-    {
+    public Long getCustomerId() {
         return customerId;
     }
-    public void setDrawer(String drawer) 
-    {
+
+    public void setDrawer(String drawer) {
         this.drawer = drawer;
     }
 
-    public String getDrawer() 
-    {
+    public String getDrawer() {
         return drawer;
     }
-    public void setDispatchNoteRemark(String dispatchNoteRemark) 
-    {
+
+    public void setDispatchNoteRemark(String dispatchNoteRemark) {
         this.dispatchNoteRemark = dispatchNoteRemark;
     }
 
-    public String getDispatchNoteRemark() 
-    {
+    public String getDispatchNoteRemark() {
         return dispatchNoteRemark;
     }
-    public void setBillingType(String billingType) 
-    {
+
+    public void setBillingType(String billingType) {
         this.billingType = billingType;
     }
 
-    public String getBillingType() 
-    {
+    public String getBillingType() {
         return billingType;
     }
-    public void setTruckRegistration(String truckRegistration) 
-    {
+
+    public void setTruckRegistration(String truckRegistration) {
         this.truckRegistration = truckRegistration;
     }
 
-    public String getTruckRegistration() 
-    {
+    public String getTruckRegistration() {
         return truckRegistration;
     }
-    public void setDocumentType(String documentType) 
-    {
+
+    public void setDocumentType(String documentType) {
         this.documentType = documentType;
     }
 
-    public String getDocumentType() 
-    {
+    public String getDocumentType() {
         return documentType;
     }
-    public void setSellingUnit(String sellingUnit) 
-    {
+
+    public void setSellingUnit(String sellingUnit) {
         this.sellingUnit = sellingUnit;
     }
 
-    public String getSellingUnit() 
-    {
+    public String getSellingUnit() {
         return sellingUnit;
     }
-    public void setCalculationType(String calculationType) 
-    {
+
+    public void setCalculationType(String calculationType) {
         this.calculationType = calculationType;
     }
 
-    public String getCalculationType() 
-    {
+    public String getCalculationType() {
         return calculationType;
     }
-    public void setAuditOpinion(String auditOpinion) 
-    {
+
+    public void setAuditOpinion(String auditOpinion) {
         this.auditOpinion = auditOpinion;
     }
 
-    public String getAuditOpinion() 
-    {
+    public String getAuditOpinion() {
         return auditOpinion;
     }
-    public void setStatus(String status) 
-    {
+
+    public void setStatus(String status) {
         this.status = status;
     }
 
-    public String getStatus() 
-    {
+    public String getStatus() {
         return status;
     }
-    public void setSaleOrderNo(String saleOrderNo) 
-    {
+
+    public void setSaleOrderNo(String saleOrderNo) {
         this.saleOrderNo = saleOrderNo;
     }
 
-    public String getSaleOrderNo() 
-    {
+    public String getSaleOrderNo() {
         return saleOrderNo;
     }
-    public void setSpare1(String spare1) 
-    {
+
+    public void setSpare1(String spare1) {
         this.spare1 = spare1;
     }
 
-    public String getSpare1() 
-    {
+    public String getSpare1() {
         return spare1;
     }
-    public void setSpare2(String spare2) 
-    {
+
+    public void setSpare2(String spare2) {
         this.spare2 = spare2;
     }
 
-    public String getSpare2() 
-    {
+    public String getSpare2() {
         return spare2;
     }
-    public void setSpare3(String spare3) 
-    {
+
+    public void setSpare3(String spare3) {
         this.spare3 = spare3;
     }
 
-    public String getSpare3() 
-    {
+    public String getSpare3() {
         return spare3;
     }
-    public void setSpare4(String spare4) 
-    {
+
+    public void setSpare4(String spare4) {
         this.spare4 = spare4;
     }
 
-    public String getSpare4() 
-    {
+    public String getSpare4() {
         return spare4;
     }
-    public void setDelFlag(String delFlag) 
-    {
+
+    public void setDelFlag(String delFlag) {
         this.delFlag = delFlag;
     }
 
-    public String getDelFlag() 
-    {
+    public String getDelFlag() {
         return delFlag;
     }
-    public void setCreateById(Long createById) 
-    {
+
+    public void setCreateById(Long createById) {
         this.createById = createById;
     }
 
-    public Long getCreateById() 
-    {
+    public Long getCreateById() {
         return createById;
     }
-    public void setUpdateById(Long updateById) 
-    {
+
+    public void setUpdateById(Long updateById) {
         this.updateById = updateById;
     }
 
-    public Long getUpdateById() 
-    {
+    public Long getUpdateById() {
         return updateById;
     }
 
@@ -360,38 +401,38 @@ public class ProductInvoice extends BaseEntity
 
     @Override
     public String toString() {
-        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
-            .append("id", getId())
-            .append("noticeNumber", getNoticeNumber())
-            .append("noticeDate", getNoticeDate())
-            .append("salesman", getSalesman())
-            .append("customerId", getCustomerId())
-            .append("customerName", getCustomerName())
-            .append("drawer", getDrawer())
-            .append("dispatchNoteRemark", getDispatchNoteRemark())
-            .append("billingType", getBillingType())
-            .append("truckRegistration", getTruckRegistration())
-            .append("documentType", getDocumentType())
-            .append("sellingUnit", getSellingUnit())
-            .append("calculationType", getCalculationType())
-            .append("auditOpinion", getAuditOpinion())
-            .append("status", getStatus())
-            .append("saleOrderNo", getSaleOrderNo())
-            .append("spare1", getSpare1())
-            .append("spare2", getSpare2())
-            .append("spare3", getSpare3())
-            .append("spare4", getSpare4())
-            .append("remark", getRemark())
-            .append("delFlag", getDelFlag())
-            .append("createBy", getCreateBy())
-            .append("createById", getCreateById())
-            .append("createTime", getCreateTime())
-            .append("updateBy", getUpdateBy())
-            .append("updateById", getUpdateById())
-            .append("updateTime", getUpdateTime())
-            .append("deliveryWarehouse", getDeliveryWarehouse())
-            .append("transferWarehouse", getTransferWarehouse())
-            .append("deliveryDate", getDeliveryDate())
-            .toString();
+        return new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE)
+                .append("id", getId())
+                .append("noticeNumber", getNoticeNumber())
+                .append("noticeDate", getNoticeDate())
+                .append("salesman", getSalesman())
+                .append("customerId", getCustomerId())
+                .append("customerName", getCustomerName())
+                .append("drawer", getDrawer())
+                .append("dispatchNoteRemark", getDispatchNoteRemark())
+                .append("billingType", getBillingType())
+                .append("truckRegistration", getTruckRegistration())
+                .append("documentType", getDocumentType())
+                .append("sellingUnit", getSellingUnit())
+                .append("calculationType", getCalculationType())
+                .append("auditOpinion", getAuditOpinion())
+                .append("status", getStatus())
+                .append("saleOrderNo", getSaleOrderNo())
+                .append("spare1", getSpare1())
+                .append("spare2", getSpare2())
+                .append("spare3", getSpare3())
+                .append("spare4", getSpare4())
+                .append("remark", getRemark())
+                .append("delFlag", getDelFlag())
+                .append("createBy", getCreateBy())
+                .append("createById", getCreateById())
+                .append("createTime", getCreateTime())
+                .append("updateBy", getUpdateBy())
+                .append("updateById", getUpdateById())
+                .append("updateTime", getUpdateTime())
+                .append("deliveryWarehouse", getDeliveryWarehouse())
+                .append("transferWarehouse", getTransferWarehouse())
+                .append("deliveryDate", getDeliveryDate())
+                .toString();
     }
 }

+ 175 - 0
zkqy-custom-business/src/main/java/com/zkqy/business/domain/vo/ProductInvoiceFinancialExportVo.java

@@ -0,0 +1,175 @@
+package com.zkqy.business.domain.vo;
+
+import com.fasterxml.jackson.annotation.JsonFormat;
+import com.zkqy.common.annotation.Excel;
+import com.zkqy.common.core.domain.BaseEntity;
+
+import java.util.Date;
+
+/**
+ * 财务对账单导出
+ */
+public class ProductInvoiceFinancialExportVo extends BaseEntity {
+    private static final long serialVersionUID = 1L;
+    /**
+     * 客户名称
+     */
+    @Excel(name = "客户名称")
+    private String customName;
+    /**
+     * 产品名称
+     */
+    @Excel(name = "产品名称")
+    private String productName;
+    /**
+     * 产品规格
+     */
+    @Excel(name = "规格")
+    private String productSpecifications;
+    /**
+     * 产品等级
+     */
+    @Excel(name = "产品等级")
+    private String levels;
+    /**
+     * 批号
+     */
+    @Excel(name = "批号")
+    private String lotNum;
+    /**
+     * 色泽
+     */
+    @Excel(name = "色泽")
+    private String productColour;
+    /**
+     * 重量
+     */
+    @Excel(name = "重量", isStatistics = true, scale = 2)
+    private String suttle;
+
+    /**
+     * 导出类型  合同单contractOrder / 零售单retailOrder
+     */
+    private String orderType;
+
+    /**
+     * 通知单号
+     */
+    private String noticeNumber;
+
+    /**
+     * 客户编号
+     */
+    private Long customerId;
+
+    /**
+     * 通知日期
+     */
+    private Date noticeDate;
+
+    @Override
+    public String toString() {
+        final StringBuilder sb = new StringBuilder("ProductInvoiceFinancialExportVo{");
+        sb.append("customName='").append(customName).append('\'');
+        sb.append(", productName='").append(productName).append('\'');
+        sb.append(", productSpecifications='").append(productSpecifications).append('\'');
+        sb.append(", levels='").append(levels).append('\'');
+        sb.append(", lotNum='").append(lotNum).append('\'');
+        sb.append(", productColour='").append(productColour).append('\'');
+        sb.append(", suttle='").append(suttle).append('\'');
+        sb.append(", orderType='").append(orderType).append('\'');
+        sb.append(", noticeNumber='").append(noticeNumber).append('\'');
+        sb.append(", customerId=").append(customerId);
+        sb.append(", noticeDate=").append(noticeDate);
+        sb.append('}');
+        return sb.toString();
+    }
+
+    public String getCustomName() {
+        return customName;
+    }
+
+    public void setCustomName(String customName) {
+        this.customName = customName;
+    }
+
+    public String getProductName() {
+        return productName;
+    }
+
+    public void setProductName(String productName) {
+        this.productName = productName;
+    }
+
+    public String getProductSpecifications() {
+        return productSpecifications;
+    }
+
+    public void setProductSpecifications(String productSpecifications) {
+        this.productSpecifications = productSpecifications;
+    }
+
+    public String getLevels() {
+        return levels;
+    }
+
+    public void setLevels(String levels) {
+        this.levels = levels;
+    }
+
+    public String getLotNum() {
+        return lotNum;
+    }
+
+    public void setLotNum(String lotNum) {
+        this.lotNum = lotNum;
+    }
+
+    public String getProductColour() {
+        return productColour;
+    }
+
+    public void setProductColour(String productColour) {
+        this.productColour = productColour;
+    }
+
+    public String getSuttle() {
+        return suttle;
+    }
+
+    public void setSuttle(String suttle) {
+        this.suttle = suttle;
+    }
+
+    public String getOrderType() {
+        return orderType;
+    }
+
+    public void setOrderType(String orderType) {
+        this.orderType = orderType;
+    }
+
+    public String getNoticeNumber() {
+        return noticeNumber;
+    }
+
+    public void setNoticeNumber(String noticeNumber) {
+        this.noticeNumber = noticeNumber;
+    }
+
+    public Long getCustomerId() {
+        return customerId;
+    }
+
+    public void setCustomerId(Long customerId) {
+        this.customerId = customerId;
+    }
+
+    public Date getNoticeDate() {
+        return noticeDate;
+    }
+
+    public void setNoticeDate(Date noticeDate) {
+        this.noticeDate = noticeDate;
+    }
+}

+ 27 - 9
zkqy-custom-business/src/main/java/com/zkqy/business/mapper/ProductInvoiceMapper.java

@@ -1,19 +1,21 @@
 package com.zkqy.business.mapper;
 
 import java.util.List;
+import java.util.Map;
+
 import com.zkqy.business.domain.ProductInvoice;
+import com.zkqy.business.domain.vo.ProductInvoiceFinancialExportVo;
 
 /**
  * 产品发货单Mapper接口
- * 
+ *
  * @author zkqy
  * @date 2024-04-11
  */
-public interface ProductInvoiceMapper 
-{
+public interface ProductInvoiceMapper {
     /**
      * 查询产品发货单
-     * 
+     *
      * @param id 产品发货单主键
      * @return 产品发货单
      */
@@ -21,7 +23,7 @@ public interface ProductInvoiceMapper
 
     /**
      * 查询产品发货单列表
-     * 
+     *
      * @param productInvoice 产品发货单
      * @return 产品发货单集合
      */
@@ -29,7 +31,7 @@ public interface ProductInvoiceMapper
 
     /**
      * 新增产品发货单
-     * 
+     *
      * @param productInvoice 产品发货单
      * @return 结果
      */
@@ -37,7 +39,7 @@ public interface ProductInvoiceMapper
 
     /**
      * 修改产品发货单
-     * 
+     *
      * @param productInvoice 产品发货单
      * @return 结果
      */
@@ -45,7 +47,7 @@ public interface ProductInvoiceMapper
 
     /**
      * 删除产品发货单
-     * 
+     *
      * @param id 产品发货单主键
      * @return 结果
      */
@@ -53,7 +55,7 @@ public interface ProductInvoiceMapper
 
     /**
      * 批量删除产品发货单
-     * 
+     *
      * @param ids 需要删除的数据主键集合
      * @return 结果
      */
@@ -74,4 +76,20 @@ public interface ProductInvoiceMapper
      * @return 结果
      */
     int deleteProductInvoiceBySaleOrderNo(String saleOrderNo);
+
+    /**
+     * 查询财务对账单列表 -》导出
+     *
+     * @param productInvoiceFinancialExportVo 财务对账单
+     * @return 对账列表集合
+     */
+    public List<Map<String, Object>> financialStatementList(ProductInvoiceFinancialExportVo productInvoiceFinancialExportVo);
+
+    /**
+     * 查询财务对账单列表
+     *
+     * @param productInvoiceFinancialExportVo 财务对账单
+     * @return 对账列表集合
+     */
+    public List<ProductInvoiceFinancialExportVo> financialStatementExportList(ProductInvoiceFinancialExportVo productInvoiceFinancialExportVo);
 }

+ 27 - 9
zkqy-custom-business/src/main/java/com/zkqy/business/service/IProductInvoiceService.java

@@ -5,19 +5,19 @@ import java.util.Map;
 
 import com.zkqy.business.domain.ProductInventory;
 import com.zkqy.business.domain.ProductInvoice;
+import com.zkqy.business.domain.vo.ProductInvoiceFinancialExportVo;
 import com.zkqy.business.domain.vo.ProductInvoiceVO;
 
 /**
  * 产品发货单Service接口
- * 
+ *
  * @author zkqy
  * @date 2024-04-11
  */
-public interface IProductInvoiceService 
-{
+public interface IProductInvoiceService {
     /**
      * 查询产品发货单
-     * 
+     *
      * @param id 产品发货单主键
      * @return 产品发货单
      */
@@ -25,7 +25,7 @@ public interface IProductInvoiceService
 
     /**
      * 查询产品发货单列表
-     * 
+     *
      * @param productInvoice 产品发货单
      * @return 产品发货单集合
      */
@@ -33,7 +33,7 @@ public interface IProductInvoiceService
 
     /**
      * 新增产品发货单
-     * 
+     *
      * @param productInvoice 产品发货单
      * @return 结果
      */
@@ -41,7 +41,7 @@ public interface IProductInvoiceService
 
     /**
      * 修改产品发货单
-     * 
+     *
      * @param productInvoice 产品发货单
      * @return 结果
      */
@@ -49,7 +49,7 @@ public interface IProductInvoiceService
 
     /**
      * 批量删除产品发货单
-     * 
+     *
      * @param ids 需要删除的产品发货单主键集合
      * @return 结果
      */
@@ -57,7 +57,7 @@ public interface IProductInvoiceService
 
     /**
      * 删除产品发货单信息
-     * 
+     *
      * @param id 产品发货单主键
      * @return 结果
      */
@@ -65,6 +65,7 @@ public interface IProductInvoiceService
 
     /**
      * 查询发货单详情/销售单
+     *
      * @param saleOrderNo 销售单编号
      * @return
      */
@@ -72,6 +73,7 @@ public interface IProductInvoiceService
 
     /**
      * 查询通知单货品信息
+     *
      * @param id 通知单编号
      * @return
      */
@@ -87,10 +89,26 @@ public interface IProductInvoiceService
 
     /**
      * 打印发货单、送货单、财务对账单接口
+     *
      * @return
      */
     ProductInvoiceVO printDocuments(Long id);
 
+    /**
+     * 查询财务对账单列表-》导出
+     *
+     * @param productInvoiceFinancialExportVo 财务对账单
+     * @return 对账列表集合
+     */
+    public List<Map<String, Object>>  financialStatementList(ProductInvoiceFinancialExportVo productInvoiceFinancialExportVo);
+
+    /**
+     * 查询财务对账单列表
+     *
+     * @param productInvoiceFinancialExportVo 财务对账单
+     * @return 对账列表集合
+     */
+    public List<ProductInvoiceFinancialExportVo> financialStatementExportList(ProductInvoiceFinancialExportVo productInvoiceFinancialExportVo);
 
 
 }

+ 11 - 0
zkqy-custom-business/src/main/java/com/zkqy/business/service/impl/ProductInvoiceServiceImpl.java

@@ -8,6 +8,7 @@ import java.util.stream.Collectors;
 
 import com.zkqy.business.domain.*;
 import com.zkqy.business.domain.vo.ProductCodeListVO;
+import com.zkqy.business.domain.vo.ProductInvoiceFinancialExportVo;
 import com.zkqy.business.domain.vo.ProductInvoiceVO;
 import com.zkqy.business.mapper.*;
 import com.zkqy.common.utils.DateUtils;
@@ -251,6 +252,16 @@ public class ProductInvoiceServiceImpl implements IProductInvoiceService
         return vo;
     }
 
+    @Override
+    public List<Map<String, Object>>  financialStatementList(ProductInvoiceFinancialExportVo productInvoiceFinancialExportVo) {
+        return productInvoiceMapper.financialStatementList(productInvoiceFinancialExportVo);
+    }
+
+    @Override
+    public List<ProductInvoiceFinancialExportVo> financialStatementExportList(ProductInvoiceFinancialExportVo productInvoiceFinancialExportVo) {
+        return null;
+    }
+
     //保留两位小数
     public Double handlingWeight(Double weight){
         DecimalFormat df = new DecimalFormat("0.00");

+ 73 - 0
zkqy-custom-business/src/main/resources/mapper/business/ProductInvoiceMapper.xml

@@ -183,4 +183,77 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
         update {DBNAME}.product_invoice set del_flag = '2' where sale_order_no = #{saleOrderNo}
     </update>
 
+    <select id="financialStatementList"  resultType="map">
+        select so.id,
+        so.sale_no,
+        so.sale_date,
+        c.custom_name,
+        so.sale_order_estimated_time,
+        so.sale_lead_time,
+        so.sale_amount_in_words,
+        so.sale_pay_type,
+        so.salesman,
+        so.sale_leader,
+        so.finance,
+        so.production,
+        so.sale_approver,
+        so.status,
+        so.order_type,
+        so.delivery_date,
+        so.remark
+        from `huaxian`.sale_order so
+        left join `huaxian`.customer c on
+        so.sale_custom_no = c.custom_no
+        where so.del_flag = '0'
+        and c.del_flag = '0'
+        and so.status = 6
+        <if test="noticeNumber != null  and noticeNumber != ''">and so.notice_number = #{noticeNumber}</if>
+        <if test="customerId != null  and customerId != ''">and c.id = #{customerId}</if>
+        <if test="noticeDate != null ">and so.notice_date = #{noticeDate}</if>
+        order by so.id desc
+    </select>
+    <select id="financialStatementExportList" resultType="com.zkqy.business.domain.vo.ProductInvoiceFinancialExportVo">
+        select
+        pi2.notice_number ,
+        c.custom_name,
+        p.product_specifications ,
+        por.levels ,
+        por.lot_num ,
+        por.tube_color ,
+        sum(por.suttle) as suttle
+        from
+        {DBNAME}.product_invoice pi2
+        inner join
+        {DBNAME}.product_outbound_record por on
+        pi2.notice_number = por.notice_number
+        left join {DBNAME}.customer c on
+        c.id = pi2.customer_id
+        left join {DBNAME}.sale_products sp on
+        sp.sale_order_no = pi2.sale_order_no
+        left join {DBNAME}.production p on
+        p.product_no = sp.product_no
+        and p.del_flag = 0
+        left join {DBNAME}.sale_order so on
+        so.sale_no = pi2.sale_order_no
+        and so.del_flag = 0 and so.status = 6
+        <if test="orderType == 'contractOrder'   ">
+            and so.sale_order_technology_no != 'retailOrder'
+        </if>
+        <if test="orderType == 'retailOrder'   ">
+            and so.sale_order_technology_no == 'retailOrder'
+        </if>
+        where pi2.del_flag = 0
+        and pi2.status = 2
+        <if test="noticeNumber != null  and noticeNumber != ''">and pi.notice_number = #{noticeNumber}</if>
+        <if test="customerId != null  and customerId != ''">and c.id = #{customerId}</if>
+        <if test="noticeDate != null ">and pi.notice_date = #{noticeDate}</if>
+        group by
+        por.lot_num ,
+        por.product_id ,
+        por.levels ,
+        por.product_colour
+        order by
+        pi2.create_time
+    </select>
+
 </mapper>

+ 9 - 0
zkqy-ui/src/api/system/ProductInvoice.js

@@ -9,6 +9,15 @@ export function listProductInvoice(query) {
   })
 }
 
+// 查询产品财务对账单列表
+export function financialStatementList(query) {
+  return request({
+    url: '/system/ProductInvoice/financialStatementList',
+    method: 'get',
+    params: query
+  })
+}
+
 // 查询产品发货单详细
 export function getProductInvoice(id) {
   return request({

+ 46 - 30
zkqy-ui/src/views/orderMange/financialReconciliation/index.vue

@@ -6,8 +6,26 @@
       size="small"
       :inline="true"
       v-show="showSearch"
-      label-width="68px"
+      label-width="80px"
     >
+      <el-form-item label="订单类型" prop="customerId">
+        <el-select
+          v-model="queryParams.orderType"
+          placeholder="订单类型"
+          @keyup.enter.native.prevent
+          @change="handleQuery">
+          <el-option
+            key="contractOrder"
+            label="合同单"
+            value="false">
+          </el-option>
+          <el-option
+            key="retailOrder"
+            label="零售单"
+            value="true">
+          </el-option>
+        </el-select>
+      </el-form-item>
       <el-form-item label="通知单号" prop="noticeNumber">
         <el-input
           v-model="queryParams.noticeNumber"
@@ -46,12 +64,6 @@
       </el-form-item> -->
 
       <el-form-item label="客户" prop="customerId">
-        <!-- <el-input
-          v-model="queryParams.customerId"
-          placeholder="请输入客户编号"
-          clearable
-          @keyup.enter.native="handleQuery"
-        /> -->
         <el-select
           v-model="queryParams.customerId"
           placeholder="请选择客户"
@@ -68,16 +80,19 @@
           </el-option>
         </el-select>
       </el-form-item>
+
       <el-form-item>
         <el-button
           type="primary"
           icon="el-icon-search"
           size="mini"
           @click="handleQuery"
-          >搜索</el-button
+        >搜索
+        </el-button
         >
         <el-button icon="el-icon-refresh" size="mini" @click="resetQuery"
-          >重置</el-button
+        >重置
+        </el-button
         >
       </el-form-item>
     </el-form>
@@ -118,6 +133,7 @@
           >删除</el-button
         >
       </el-col>
+      -->
       <el-col :span="1.5">
         <el-button
           type="warning"
@@ -126,9 +142,10 @@
           size="mini"
           @click="handleExport"
           v-hasPermi="['system:ProductInvoice:export']"
-          >导出</el-button
+        >导出
+        </el-button
         >
-      </el-col> -->
+      </el-col>
       <right-toolbar
         :showSearch.sync="showSearch"
         @queryTable="getList"
@@ -152,7 +169,7 @@
           <span>{{ parseTime(scope.row.noticeDate, "{y}-{m}-{d}") }}</span>
         </template>
       </el-table-column>
-      <el-table-column label="通知单号" align="center" prop="noticeNumber" />
+      <el-table-column label="通知单号" align="center" prop="noticeNumber"/>
 
       <!-- <el-table-column label="销售员" align="center" prop="salesman" />
       <el-table-column label="客户编号" align="center" prop="customerId" />
@@ -172,7 +189,7 @@
       <el-table-column label="售货单位" align="center" prop="sellingUnit" />
       <el-table-column label="计算类型" align="center" prop="calculationType" />
       <el-table-column label="审核意见" align="center" prop="auditOpinion" /> -->
-      <el-table-column label="客户名称" align="center" prop="customerName" />
+      <el-table-column label="客户名称" align="center" prop="customerName"/>
       <!-- <el-table-column label="状态" align="center" prop="status">
         <template slot-scope="scope">{{ scope.row.status }}</template>
       </el-table-column> -->
@@ -199,12 +216,9 @@
                 >
               </el-dropdown-item> -->
               <el-dropdown-item>
-                <el-button
-                  type="text"
-                  size="mini"
-                  @click="handleSendOrder(scope.$index, scope.row)"
-                  >打印对账单</el-button
-                >
+                <el-button type="text" size="mini" @click="handleSendOrder(scope.$index, scope.row)">
+                  打印对账单
+                </el-button>
               </el-dropdown-item>
             </el-dropdown-menu>
           </el-dropdown>
@@ -225,7 +239,7 @@
 
 <script>
 import {
-  listProductInvoice,
+  financialStatementList,
   getProductInvoice,
   delProductInvoice,
   addProductInvoice,
@@ -238,7 +252,7 @@ import {
   queryDropDownBoxData,
   printDocuments,
 } from "@/api/tablelist/commonTable";
-import { mapState } from "vuex";
+import {mapState} from "vuex";
 
 export default {
   name: "ProductInvoice",
@@ -280,6 +294,7 @@ export default {
         calculationType: null,
         auditOpinion: null,
         status: 2,
+        orderType: "contractOrder"  // 零售单/合同单
       },
       // 表单参数
       form: {},
@@ -318,7 +333,7 @@ export default {
     },
     // 打印发货单回调
     async handleDeliverOrder(index, row) {
-      let { saleOrderNo } = row;
+      let {saleOrderNo} = row;
       if (!saleOrderNo) {
         this.$message.error("数据异常,暂无saleOrderNo");
       }
@@ -335,7 +350,7 @@ export default {
           printUser: this.username,
         });
         deliverOrderPrint(
-          { ...row, ...printData, printUser: this.username },
+          {...row, ...printData, printUser: this.username},
           "printDom"
         );
       } else {
@@ -346,7 +361,7 @@ export default {
     },
     // 打印送货单回调
     async handleSendOrder(index, row) {
-      let { saleOrderNo } = row;
+      let {saleOrderNo} = row;
       if (!saleOrderNo) {
         this.$message.error("数据异常,暂无saleOrderNo");
       }
@@ -354,7 +369,7 @@ export default {
         saleOrderNo: saleOrderNo,
       };
       // let res = await productInvoiceInfo(payload);
-      let res = await printDocuments({ id: row.id });
+      let res = await printDocuments({id: row.id});
       if (res.code == 200) {
         let printData = res.data;
         console.log("printData", {
@@ -363,7 +378,7 @@ export default {
           printUser: this.username,
         });
         sendOrderPrint(
-          { ...row, ...printData, printUser: this.username },
+          {...row, ...printData, printUser: this.username},
           "printDom"
         );
       } else {
@@ -374,7 +389,7 @@ export default {
     /** 查询产品发货单列表 */
     getList() {
       this.loading = true;
-      listProductInvoice(this.queryParams).then((response) => {
+      financialStatementList(this.queryParams).then((response) => {
         this.ProductInvoiceList = response.rows;
         this.total = response.total;
         this.loading = false;
@@ -482,16 +497,17 @@ export default {
           this.getList();
           this.$modal.msgSuccess("删除成功");
         })
-        .catch(() => {});
+        .catch(() => {
+        });
     },
     /** 导出按钮操作 */
     handleExport() {
       this.download(
-        "system/ProductInvoice/export",
+        "/system/ProductInvoice/importFinancialStatement",
         {
           ...this.queryParams,
         },
-        `ProductInvoice_${new Date().getTime()}.xlsx`
+        `客户销售汇总_${new Date().getTime()}.xlsx`
       );
     },
   },

+ 73 - 23
zkqy-ui/src/views/orderMange/outStock/index.vue

@@ -8,18 +8,20 @@
           @click="handleRefresh"
           :icon="loading ? 'el-icon-loading' : 'el-icon-refresh'"
           :disabled="loading"
-          >刷新</el-button
+        >刷新
+        </el-button
         >
 
         <el-table
           :data="leftTableData"
           border
           stripe
+          @selection-change="handleSelectionChange"
           @cell-click="cellClick"
           highlight-current-row
         >
           <!-- <el-table-column type="selection" width="55" /> -->
-          <el-table-column type="index" label="序号" width="50" />
+          <el-table-column type="index" label="序号" width="50"/>
           <el-table-column align="center" prop="customerName" label="客户名称">
           </el-table-column>
           <el-table-column align="center" prop="noticeNumber" label="通知单号">
@@ -123,22 +125,23 @@
             </el-col>
             <el-form-item>
               <el-button type="primary" @click="outStockHandler"
-                >出库</el-button
+              >出库
+              </el-button
               >
               <el-button @click="refreshHandler">刷新</el-button>
             </el-form-item>
           </el-form>
         </el-row>
-        <el-table width="100%" :data="saleProductInfoList" border stripe>
+        <!--        :span-method="objectSpanMethod"-->
+        <!--        :header-cell-style="{'text-align':'center'}"-->
+        <!--        :cell-style="{'text-align':'center'}" ref="tableRef"-->
+        <el-table :data="saleProductInfoList" border stripe
+        >
           <el-table-column align="center" label="编码" prop="productCode">
           </el-table-column>
           <el-table-column align="center" label="品名" prop="productName">
           </el-table-column>
-          <el-table-column
-            align="center"
-            label="规格"
-            prop="productSpecifications"
-          >
+          <el-table-column align="center" label="规格" prop="productSpecifications">
           </el-table-column>
           <el-table-column align="center" label="色泽" prop="productColor">
           </el-table-column>
@@ -169,7 +172,8 @@ import {
   queryDropDownBoxData,
   noticeOutStorage,
 } from "@/api/tablelist/commonTable";
-import { mapState } from "vuex";
+import {mapState} from "vuex";
+
 export default {
   name: "OutStock",
   props: [],
@@ -177,6 +181,7 @@ export default {
   components: {},
   data() {
     return {
+      spanArr: [], // 用于记录每个 productCode 的跨行信息
       loading: false,
       currentIndex: "",
       form: {
@@ -200,18 +205,55 @@ export default {
       saleProductInfoList: [],
       rules: {
         deliveryDate: [
-          { required: true, message: "请选择发货日期", trigger: "change" },
+          {required: true, message: "请选择发货日期", trigger: "change"},
         ],
         deliveryWarehouse: [
-          { required: true, message: "请选择发货仓库", trigger: "change" },
+          {required: true, message: "请选择发货仓库", trigger: "change"},
         ],
         transferWarehouse: [
-          { required: true, message: "请选择调拨仓库", trigger: "change" },
+          {required: true, message: "请选择调拨仓库", trigger: "change"},
         ],
       },
     };
   },
   methods: {
+    // objectSpanMethod({row, column, rowIndex, columnIndex}) {
+    //   if (this.saleProductInfoList.length == 1 || this.saleProductInfoList.length == 0) {
+    //     console.log("当前长度不满足:" + this.saleProductInfoList.length);
+    //     return [1, 1];
+    //   }
+    //   console.log("当前长度满足le:" + this.saleProductInfoList.length);
+    //   if (columnIndex == 6) {
+    //     if (!this.spanArr[rowIndex]) {
+    //       this.spanArr[rowIndex] = {
+    //         rowspan: 1,
+    //         end: false,
+    //       };
+    //     }
+    //     console.log(this.saleProductInfoList);
+    //     console.log(rowIndex);
+    //     let duixiang = this.saleProductInfoList[rowIndex];
+    //     console.log(duixiang)
+    //     console.log(row.productCode === duixiang.productCode)
+    //     console.log(row.productCode, "----", duixiang.productCode)
+    //     if (rowIndex < this.saleProductInfoList.length - 1 && row.productCode === duixiang.productCode) {
+    //       if (!this.spanArr[rowIndex].end) {
+    //         this.spanArr[rowIndex].rowspan += 1;
+    //         this.spanArr[rowIndex + 1] = {
+    //           rowspan: 0,
+    //           end: false,
+    //         };
+    //       }
+    //     } else {
+    //       this.spanArr[rowIndex].end = true;
+    //     }
+    //     if (this.spanArr[rowIndex].rowspan >= 1) {
+    //       console.log([this.spanArr[rowIndex].rowspan, 1])
+    //       return [this.spanArr[rowIndex].rowspan, 1];
+    //     }
+    //   }
+    //
+    // },
     // 刷新回调
     async handleRefresh() {
       this.loading = true;
@@ -240,8 +282,7 @@ export default {
             type: "warning",
           })
             .then(async () => {
-              let payLoad = { ...this.form };
-              console.log(this.form);
+              let payLoad = {...this.form};
               if (!this.form.id) {
                 return;
               }
@@ -267,7 +308,8 @@ export default {
         }
       });
     },
-    handleSelectionChange() {},
+    handleSelectionChange() {
+    },
     // 初始化仓库选项数据
     async initWarehouse() {
       try {
@@ -288,7 +330,7 @@ export default {
           throw new Error(res.msg);
         }
       } catch (error) {
-        console.log(error);
+
       }
     },
     // 初始化数据
@@ -309,7 +351,7 @@ export default {
           throw new Error(res.msg);
         }
       } catch (error) {
-        console.log(error);
+
       }
     },
     // 根据字典获取文件类型
@@ -329,8 +371,6 @@ export default {
         id = this.leftTableData[this.currentIndex].id;
         customerName = this.leftTableData[this.currentIndex].customerName;
       }
-      console.log(this.leftTableData[this.currentIndex]);
-      console.log(id);
       if (!id) {
         //重置表单数据
         Object.assign(this.form, {
@@ -345,12 +385,10 @@ export default {
           deliveryClerk: "", //发货员
           id: "",
         });
-        console.log(this.form);
         return;
       }
       try {
         let res = await saleStorageDetails(id);
-        console.log(res);
         if (res.code == 200) {
           let {
             noticeNumber, //通知单号
@@ -365,6 +403,10 @@ export default {
           } = res.data;
           let documentTypeName = this.getdocumentTypeName(documentType);
           this.saleProductInfoList = saleProductInfoList;
+
+          // this.$nextTick(() => {
+          //   this.$refs.tableRef.doLayout();
+          // });
           Object.assign(this.form, {
             noticeNumber, //通知单号
             documentType, //通知单类型
@@ -379,7 +421,6 @@ export default {
           this.form.deliveryClerk = this.nickName;
         }
       } catch (error) {
-        console.log(error);
       }
     },
   },
@@ -398,14 +439,23 @@ export default {
 <style scoped lang="scss">
 .app-container {
   display: flex;
+
   .table-area {
     width: 600px;
   }
+
   .form-area {
     flex: 1;
   }
 }
+
 ::v-deep .el-table__body tr.current-row > td.el-table__cell {
   background-color: #55e905 !important;
 }
+
+.table-data > > > .gutter {
+  display: table-cell !important
+}
+
+
 </style>