春风项目四线(合箱线、总装线)
wujian
2024-10-23 2c65c31aceb16c1d06c692266e3fb555ecafdfb5
change-4
已添加7个文件
已修改36个文件
1207 ■■■■ 文件已修改
jcdm-main/src/main/java/com/jcdm/main/bs/beatSetting/controller/BsBeatSettingController.java 40 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
jcdm-main/src/main/java/com/jcdm/main/bs/beatSetting/domain/ProductNumTable.java 28 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
jcdm-main/src/main/java/com/jcdm/main/bs/beatSetting/mapper/ProductNumTableMapper.java 15 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
jcdm-main/src/main/java/com/jcdm/main/bs/beatSetting/service/ProductNumTableService.java 13 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
jcdm-main/src/main/java/com/jcdm/main/bs/beatSetting/service/impl/ProductNumTableServiceImpl.java 33 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
jcdm-main/src/main/java/com/jcdm/main/bs/orderScheduling/controller/BsOrderSchedulingController.java 8 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
jcdm-main/src/main/java/com/jcdm/main/bs/orderScheduling/domain/BsOrderScheduling.java 44 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
jcdm-main/src/main/java/com/jcdm/main/bs/orderScheduling/mapper/BsOrderSchedulingMapper.java 6 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
jcdm-main/src/main/java/com/jcdm/main/bs/orderScheduling/service/IBsOrderSchedulingService.java 1 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
jcdm-main/src/main/java/com/jcdm/main/bs/orderScheduling/service/impl/BsOrderSchedulingServiceImpl.java 25 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
jcdm-main/src/main/java/com/jcdm/main/da/paramCollection/controller/DaParamCollectionController.java 9 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
jcdm-main/src/main/java/com/jcdm/main/da/paramCollection/mapper/DaParamCollectionMapper.java 1 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
jcdm-main/src/main/java/com/jcdm/main/da/paramCollection/service/IDaParamCollectionService.java 1 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
jcdm-main/src/main/java/com/jcdm/main/da/paramCollection/service/impl/DaParamCollectionServiceImpl.java 10 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
jcdm-main/src/main/java/com/jcdm/main/da/passingStationCollection/controller/DaPassingStationCollectionController.java 31 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
jcdm-main/src/main/java/com/jcdm/main/da/passingStationCollection/domain/DaPassingStationCollection.java 23 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
jcdm-main/src/main/java/com/jcdm/main/da/passingStationCollection/domain/ProductNumVO.java 19 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
jcdm-main/src/main/java/com/jcdm/main/da/passingStationCollection/mapper/DaPassingStationCollectionMapper.java 1 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
jcdm-main/src/main/java/com/jcdm/main/da/passingStationCollection/service/IDaPassingStationCollectionService.java 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
jcdm-main/src/main/java/com/jcdm/main/da/passingStationCollection/service/impl/DaPassingStationCollectionServiceImpl.java 40 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
jcdm-main/src/main/java/com/jcdm/main/om/productionOrde/domain/OmProductionOrdeInfo.java 2 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
jcdm-main/src/main/java/com/jcdm/main/plcserver/conf/OPCElement.java 4 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
jcdm-main/src/main/java/com/jcdm/main/plcserver/sub/OPCUaSubscription.java 20 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
jcdm-main/src/main/resources/mapper/bs/beatSetting/ProductNumTableMapper.xml 55 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
jcdm-main/src/main/resources/mapper/bs/orderScheduling/BsOrderSchedulingMapper.xml 24 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
jcdm-main/src/main/resources/mapper/da/paramCollection/DaParamCollectionMapper.xml 21 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
jcdm-main/src/main/resources/mapper/da/passingStationCollection/DaPassingStationCollectionMapper.xml 21 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
jcdm-quartz/src/main/java/com/jcdm/quartz/task/RyTask.java 210 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
jcdm-ui/src/api/main/da/paramCollection/paramCollection.js 8 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
jcdm-ui/src/api/main/da/passingStationCollection/passingStationCollection.js 16 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
jcdm-ui/src/views/dashboard/PanelGroup.vue 32 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
jcdm-ui/src/views/main/bs/orderScheduling/index.vue 102 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
jcdm-ui/src/views/main/da/followReport/index.vue 20 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
jcdm-ui/src/views/main/da/followReport/report1.vue 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
jcdm-ui/src/views/main/da/followReport/report2.vue 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
jcdm-ui/src/views/main/da/followReport/report3.vue 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
jcdm-ui/src/views/main/da/followReport/report4.vue 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
jcdm-ui/src/views/main/da/followReport/report5.vue 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
jcdm-ui/src/views/main/da/paramCollection/index.vue 45 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
jcdm-ui/src/views/main/da/passingStationCollection/index.vue 33 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
jcdm-ui/src/views/main/da/productNum/index.vue 154 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
jcdm-ui/src/views/main/om/productionOrde/index.vue 46 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
jcdm-ui/src/views/main/om/productionOrde/planStatistics.vue 22 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
jcdm-main/src/main/java/com/jcdm/main/bs/beatSetting/controller/BsBeatSettingController.java
@@ -1,7 +1,17 @@
package com.jcdm.main.bs.beatSetting.controller;
import java.time.LocalDate;
import java.util.List;
import javax.annotation.Resource;
import javax.servlet.http.HttpServletResponse;
import cn.hutool.core.util.ObjectUtil;
import com.jcdm.common.core.domain.R;
import com.jcdm.main.bs.beatSetting.domain.ProductNumTable;
import com.jcdm.main.bs.beatSetting.service.ProductNumTableService;
import com.jcdm.main.da.passingStationCollection.domain.DaPassingStationCollection;
import com.jcdm.main.da.passingStationCollection.domain.ProductNumVO;
import com.jcdm.main.da.passingStationCollection.service.IDaPassingStationCollectionService;
import org.springframework.security.access.prepost.PreAuthorize;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
@@ -34,6 +44,12 @@
    @Autowired
    private IBsBeatSettingService bsBeatSettingService;
    @Resource
    private ProductNumTableService productNumTableService;
    @Resource
    private IDaPassingStationCollectionService daPassingStationCollectionService;
    /**
     * æŸ¥è¯¢èŠ‚拍设置列表
     */
@@ -59,6 +75,30 @@
        util.exportExcel(response, list, "节拍设置数据");
    }
    @Log(title = "节拍设置", businessType = BusinessType.EXPORT)
    @PostMapping("/productNumExport")
    public void productNumExport(HttpServletResponse response, DaPassingStationCollection daPassingStationCollection)
    {
//        LocalDate queryDate = daPassingStationCollection.getQueryDate();
//        String queryMonth = daPassingStationCollection.getQueryMonth();
//        if (ObjectUtil.isNull(queryDate) && ObjectUtil.isNull(queryMonth)){
//            return R.fail("请选择月份或者日期");
//        }
//        if (ObjectUtil.isNotEmpty(queryMonth) && ObjectUtil.isNotEmpty(queryDate)){
//            String queryDateString = queryDate.toString();
//            String queryMonthString = queryMonth.toString();
//            if (!queryDateString.contains(queryMonthString)){
//                return R.fail("请确认选择的月份和日期月份是否匹配");
//            }
//        }
        List<ProductNumVO> productNum = daPassingStationCollectionService.getProductNum(daPassingStationCollection);
        ExcelUtil<ProductNumVO> util = new ExcelUtil<ProductNumVO>(ProductNumVO.class);
        util.exportExcel(response, productNum, "产量统计数据");
    }
    /**
     * èŽ·å–节拍设置详细信息
     */
jcdm-main/src/main/java/com/jcdm/main/bs/beatSetting/domain/ProductNumTable.java
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,28 @@
package com.jcdm.main.bs.beatSetting.domain;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.jcdm.common.annotation.Excel;
import lombok.Data;
import org.springframework.format.annotation.DateTimeFormat;
import java.time.LocalDate;
@Data
public class ProductNumTable {
    private Long id;
    @JsonFormat(pattern = "yyyy-MM-dd")
    private LocalDate productTime;
    private String model;
    private Integer zzOfflineNum;
    private Integer zzOnlineNum;
    private Integer hxOnlineNum;
    private Integer productNumTheory;
}
jcdm-main/src/main/java/com/jcdm/main/bs/beatSetting/mapper/ProductNumTableMapper.java
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,15 @@
package com.jcdm.main.bs.beatSetting.mapper;
import com.jcdm.main.bs.beatSetting.domain.ProductNumTable;
import java.util.List;
public interface ProductNumTableMapper {
    public void insertProductNum(List<ProductNumTable> list);
    public void updateProductNum(ProductNumTable productNumTable);
    public List<ProductNumTable> selectProductNum(ProductNumTable productNumTable);
}
jcdm-main/src/main/java/com/jcdm/main/bs/beatSetting/service/ProductNumTableService.java
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,13 @@
package com.jcdm.main.bs.beatSetting.service;
import com.jcdm.main.bs.beatSetting.domain.ProductNumTable;
import java.util.List;
public interface ProductNumTableService {
    public void insertProductList(List<ProductNumTable> list);
    public void updateProductNum(ProductNumTable productNumTable);
    public List<ProductNumTable> selectProductList(ProductNumTable productNumTable);
}
jcdm-main/src/main/java/com/jcdm/main/bs/beatSetting/service/impl/ProductNumTableServiceImpl.java
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,33 @@
package com.jcdm.main.bs.beatSetting.service.impl;
import com.jcdm.main.bs.beatSetting.domain.ProductNumTable;
import com.jcdm.main.bs.beatSetting.mapper.ProductNumTableMapper;
import com.jcdm.main.bs.beatSetting.service.ProductNumTableService;
import org.springframework.stereotype.Service;
import javax.annotation.Resource;
import java.util.List;
@Service
public class ProductNumTableServiceImpl implements ProductNumTableService {
    @Resource
    private ProductNumTableMapper productNumTableMapper;
    @Override
    public void insertProductList(List<ProductNumTable> list){
        productNumTableMapper.insertProductNum(list);
    }
    @Override
    public void updateProductNum(ProductNumTable productNumTable) {
        productNumTableMapper.updateProductNum(productNumTable);
    }
    @Override
    public List<ProductNumTable> selectProductList(ProductNumTable productNumTable) {
       return productNumTableMapper.selectProductNum(productNumTable);
    }
}
jcdm-main/src/main/java/com/jcdm/main/bs/orderScheduling/controller/BsOrderSchedulingController.java
@@ -156,9 +156,9 @@
            WriteSheet sheet1 = EasyExcel.writerSheet(1, "拧紧数据")
                    .head(DaParamCollection.class).registerWriteHandler(new LongestMatchColumnWidthStyleStrategy())
                    .build();
            WriteSheet sheet2 = EasyExcel.writerSheet(2, "相机检测")
                    .head(DaParamCollection.class).registerWriteHandler(new LongestMatchColumnWidthStyleStrategy())
                    .build();
//            WriteSheet sheet2 = EasyExcel.writerSheet(2, "相机检测")
//                    .head(DaParamCollection.class).registerWriteHandler(new LongestMatchColumnWidthStyleStrategy())
//                    .build();
            WriteSheet sheet3 = EasyExcel.writerSheet(3, "外漏检测")
                    .head(DaParamCollection.class).registerWriteHandler(new LongestMatchColumnWidthStyleStrategy())
                    .build();
@@ -170,7 +170,7 @@
                    .build();
            excelWriter.write(followReportList.getMainList(),mainSheet);
            excelWriter.write(followReportList.getList1(),sheet1);
            excelWriter.write(followReportList.getList2(),sheet2);
//            excelWriter.write(followReportList.getList2(),sheet2);
            excelWriter.write(followReportList.getList3(),sheet3);
            excelWriter.write(followReportList.getList4(),sheet4);
            excelWriter.write(followReportList.getList5(),sheet5);
jcdm-main/src/main/java/com/jcdm/main/bs/orderScheduling/domain/BsOrderScheduling.java
@@ -73,106 +73,86 @@
    private String model;
    /** ç”Ÿäº§çŠ¶æ€ */
    @Excel(name = "生产状态")
    private String productionStatus;
    @ExcelProperty(value = "生产状态", index = 4)
    private String productionStatusString;
    /** å·¥æ—¶ */
    @Excel(name = "工时")
    @ExcelProperty(value = "工时", index = 5)
    @ExcelIgnore
    private String workingHours;
    @TableField(exist = false)
    private Integer workingHoursInt;
    /** å½“前工位 */
    @Excel(name = "当前工位")
    @ExcelProperty(value = "当前工位", index = 6)
    @ExcelIgnore
    private String currentWorkstation;
    /** è´¨é‡çŠ¶æ€ */
    @Excel(name = "质量状态")
    @ExcelProperty(value = "质量状态", index = 7)
    @ExcelProperty(value = "质量状态", index = 5)
    private String qualityStatus;
    /** æ˜¯å¦æ‰“印 */
    @Excel(name = "是否打印")
    private String whetherOrPrint;
    /** 10报工 */
    @Excel(name = "10报工")
    @ExcelIgnore
    private String report10;
    /** 20报工 */
    @Excel(name = "20报工")
    @ExcelIgnore
    private String report20;
    /** åˆç®±ä¸Šçº¿ */
    @Excel(name = "合箱上线")
    @ExcelIgnore
    private String combinedBoxTime;
    /** æ€»è£…下线 */
    @Excel(name = "总装下线")
    @ExcelIgnore
    private String finalAssemblyTime;
    /** æ“ä½œäºº */
    @Excel(name = "操作人")
    @ExcelProperty(value = "操作人", index = 14)
    @ExcelProperty(value = "操作人", index = 10)
    private String operator;
    /** æ“ä½œæ—¶é—´ */
    @Excel(name = "操作时间")
    @ExcelProperty(value = "操作时间", index = 15)
    @ExcelProperty(value = "操作时间", index = 11)
    private String operateTime;
    /** çŠ¶æ€ */
    @Excel(name = "状态")
    @ExcelIgnore
    private String status;
    /** é¢„留字段1 */
    @Excel(name = "预留字段1")
    @ExcelIgnore
    private String spareField1;
    /** é¢„留字段2 */
    @Excel(name = "预留字段2")
    @ExcelIgnore
    private String spareField2;
    /** é¢„留字段3 */
    @Excel(name = "预留字段3")
    @ExcelIgnore
    private String spareField3;
    /** é¢„留字段4 */
    @Excel(name = "预留字段4")
    @ExcelIgnore
    private String spareField4;
    /** åˆ›å»ºç”¨æˆ· */
    @Excel(name = "创建用户")
    @ExcelIgnore
    private String createUser;
    /** æ›´æ”¹ç”¨æˆ· */
    @Excel(name = "更改用户")
    @ExcelIgnore
    private String updateUser;
    /** å¤‡æ³¨ */
    @Excel(name = "备注")
    @ExcelIgnore
    private String remarks;
    /** CVT报工 */
    @Excel(name = "CVT报工")
    @ExcelIgnore
    private String report30;
@@ -187,42 +167,40 @@
    /** åˆç®±ä¸Šçº¿æ—¶é—´ */
    @Excel(name = "合箱上线时间")
    @ExcelProperty(value = "合箱上线时间", index = 8)
    @ExcelProperty(value = "合箱上线时间", index = 6)
    @com.alibaba.excel.annotation.format.DateTimeFormat("yyyy-MM-dd HH:mm:ss")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date boxClosingOnlineTime;
    /** åˆç®±ä¸‹çº¿æ—¶é—´ */
    @Excel(name = "合箱下线时间")
    @ExcelProperty(value = "合箱下线时间", index = 9)
    @ExcelProperty(value = "合箱下线时间", index = 7)
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date closingBoxOfflineTime;
    /** æ€»è£…上线时间 */
    @Excel(name = "总装上线时间")
    @ExcelProperty(value = "总装上线时间", index =10)
    @ExcelProperty(value = "总装上线时间", index =8)
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date finalAssemblyLaunchTime;
    /** æ€»è£…下线时间 */
    @Excel(name = "总装下线时间")
    @ExcelProperty(value = "总装下线时间", index = 11)
    @ExcelProperty(value = "总装下线时间", index = 9)
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date finalAssemblyOfflineTime;
    /** CVT上线时间 */
    @Excel(name = "CVT上线时间")
    @ExcelProperty(value = "CVT上线时间", index = 12)
    @ExcelIgnore
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date cvtLaunchTime;
    /** CVT下线时间 */
    @Excel(name = "CVT下线时间")
    @ExcelProperty(value = "CVT下线时间", index = 13)
    @ExcelIgnore
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date cvtOfflineTime;
jcdm-main/src/main/java/com/jcdm/main/bs/orderScheduling/mapper/BsOrderSchedulingMapper.java
@@ -2,7 +2,10 @@
import com.jcdm.main.bs.orderScheduling.Query.PrepareOnlineQuery;
import com.jcdm.main.bs.orderScheduling.domain.BsOrderScheduling;
import com.jcdm.main.da.passingStationCollection.domain.ProductNumVO;
import org.apache.ibatis.annotations.Param;
import java.time.LocalDate;
import java.util.List;
/**
@@ -36,6 +39,7 @@
     * @return è®¢å•æŽ’产集合
     */
    public List<BsOrderScheduling> selectBsOrderSchedulingList(BsOrderScheduling bsOrderScheduling);
    public List<BsOrderScheduling> selectBsOrderSchedulingListForNum(@Param("queryDate") String queryDate,@Param("addQueryDate") String addQueryDate);
    public List<BsOrderScheduling> selectBsOrderSchedulingPage(BsOrderScheduling bsOrderScheduling);
@@ -81,4 +85,6 @@
     * @return ç»“æžœ
     */
    public int deleteBsOrderSchedulingByIds(Long[] ids);
    public List<ProductNumVO> getProductNum(@Param("queryDate") String queryDate,@Param("addQueryDate") String addQueryDate);
}
jcdm-main/src/main/java/com/jcdm/main/bs/orderScheduling/service/IBsOrderSchedulingService.java
@@ -36,6 +36,7 @@
     * @return è®¢å•æŽ’产集合
     */
    public List<BsOrderScheduling> selectBsOrderSchedulingList(BsOrderScheduling bsOrderScheduling);
    public List<BsOrderScheduling> selectBsOrderSchedulingListForNum();
    public List<BsOrderScheduling> selectBsOrderSchedulingPage(BsOrderScheduling bsOrderScheduling);
    public FollowReportVO getFollowReportList(BsOrderScheduling bsOrderScheduling);
    public List<LineChartVO> getOffLineNum();
jcdm-main/src/main/java/com/jcdm/main/bs/orderScheduling/service/impl/BsOrderSchedulingServiceImpl.java
@@ -92,6 +92,15 @@
    }
    @Override
    public List<BsOrderScheduling> selectBsOrderSchedulingListForNum() {
        LocalDate today = LocalDate.now();
        LocalDate localDate = today.plusDays(1);
        String queryDate = today.toString();
        String addQueryDate = localDate.toString();
        return bsOrderSchedulingMapper.selectBsOrderSchedulingListForNum(queryDate,addQueryDate);
    }
    @Override
    public List<BsOrderScheduling> selectBsOrderSchedulingPage(BsOrderScheduling bsOrderScheduling)
    {
        if(bsOrderScheduling.getDateConditions()!=null){
@@ -120,16 +129,26 @@
        List<DaPassingStationCollection> collect5 = new ArrayList<>();
        if (CollUtil.isNotEmpty(engineNoList)){
            allChildList = daParamCollectionMapper.getListBySfcCode(engineNoList);
            collect5 = daPassingStationCollectionMapper.getListBySfcCode(engineNoList);
            List<DaPassingStationCollection> tempCollect = daPassingStationCollectionMapper.getListBySfcCode(engineNoList);
            if (engineNoList.size()>1){
                List<DaPassingStationCollection> outCollect = new ArrayList<>();
                engineNoList.forEach(engineNo -> {
                    List<DaPassingStationCollection> collect = tempCollect.stream().filter(x -> engineNo.equals(x.getSfcCode())).collect(Collectors.toList());
                    outCollect.addAll(collect);
                });
                collect5 = outCollect;
            } else {
                collect5 = tempCollect;
            }
        }
        if (CollUtil.isNotEmpty(allChildList)){
            //拿到所有子数据
            List<DaParamCollection> collect1 = allChildList.stream().filter(x -> Constants.DATA1.equals(x.getType())).collect(Collectors.toList());
            List<DaParamCollection> collect2 = allChildList.stream().filter(x -> Constants.DATA2.equals(x.getType())).collect(Collectors.toList());
//            List<DaParamCollection> collect2 = allChildList.stream().filter(x -> Constants.DATA2.equals(x.getType())).collect(Collectors.toList());
            List<DaParamCollection> collect3 = allChildList.stream().filter(x -> Constants.DATA3.equals(x.getType())).collect(Collectors.toList());
            List<DaParamCollection> collect4 = allChildList.stream().filter(x -> Constants.DATA4.equals(x.getType())).collect(Collectors.toList());
            vo.setList1(collect1);
            vo.setList2(collect2);
//            vo.setList2(collect2);
            vo.setList3(collect3);
            vo.setList4(collect4);
        }
jcdm-main/src/main/java/com/jcdm/main/da/paramCollection/controller/DaParamCollectionController.java
@@ -1,5 +1,6 @@
package com.jcdm.main.da.paramCollection.controller;
import java.time.LocalTime;
import java.util.List;
import javax.servlet.http.HttpServletResponse;
@@ -48,6 +49,14 @@
        return getDataTable(list);
    }
    @GetMapping("/queryDaParamCollectionListForSearch")
    public TableDataInfo queryDaParamCollectionListForSearch(DaParamCollection daParamCollection)
    {
        startPage();
        List<DaParamCollection> list = daParamCollectionService.queryDaParamCollectionListForSearch(daParamCollection);
        return getDataTable(list);
    }
    /**
     * å¯¼å‡ºè®¾å¤‡äº§å“è¿‡ç¨‹å‚数采集列表
     */
jcdm-main/src/main/java/com/jcdm/main/da/paramCollection/mapper/DaParamCollectionMapper.java
@@ -27,6 +27,7 @@
     * @return è®¾å¤‡äº§å“è¿‡ç¨‹å‚数采集集合
     */
    public List<DaParamCollection> selectDaParamCollectionList(DaParamCollection daParamCollection);
    public List<DaParamCollection> queryDaParamCollectionListForSearch(DaParamCollection daParamCollection);
    public List<DaParamCollection> getListBySfcCode(@Param("engineNoList") List<String> engineNoList);
jcdm-main/src/main/java/com/jcdm/main/da/paramCollection/service/IDaParamCollectionService.java
@@ -27,6 +27,7 @@
     * @return è®¾å¤‡äº§å“è¿‡ç¨‹å‚数采集集合
     */
    public List<DaParamCollection> selectDaParamCollectionList(DaParamCollection daParamCollection);
    public List<DaParamCollection> queryDaParamCollectionListForSearch(DaParamCollection daParamCollection);
    /**
     * æ–°å¢žè®¾å¤‡äº§å“è¿‡ç¨‹å‚数采集
jcdm-main/src/main/java/com/jcdm/main/da/paramCollection/service/impl/DaParamCollectionServiceImpl.java
@@ -61,6 +61,16 @@
        return daParamCollectionMapper.selectDaParamCollectionList(daParamCollection);
    }
    @Override
    public List<DaParamCollection> queryDaParamCollectionListForSearch(DaParamCollection daParamCollection) {
        if(daParamCollection.getDateConditions()!=null){
            String[] conditions = daParamCollection.getDateConditions();
            daParamCollection.setStartTime(conditions[0]);
            daParamCollection.setEndTime(conditions[1]);
        }
        return daParamCollectionMapper.selectDaParamCollectionList(daParamCollection);
    }
    /**
     * æ–°å¢žè®¾å¤‡äº§å“è¿‡ç¨‹å‚数采集
     * 
jcdm-main/src/main/java/com/jcdm/main/da/passingStationCollection/controller/DaPassingStationCollectionController.java
@@ -1,5 +1,6 @@
package com.jcdm.main.da.passingStationCollection.controller;
import cn.hutool.core.util.ObjectUtil;
import com.jcdm.common.annotation.Log;
import com.jcdm.common.core.controller.BaseController;
import com.jcdm.common.core.domain.AjaxResult;
@@ -9,6 +10,7 @@
import com.jcdm.common.utils.DateUtils;
import com.jcdm.common.utils.poi.ExcelUtil;
import com.jcdm.main.da.passingStationCollection.domain.DaPassingStationCollection;
import com.jcdm.main.da.passingStationCollection.domain.ProductNumVO;
import com.jcdm.main.da.passingStationCollection.service.IDaPassingStationCollectionService;
import com.jcdm.main.da.passingStationCollection.service.impl.DaPassingStationCollectionServiceImpl;
import com.jcdm.main.da.passingStationCollection.vo.DaPassingStationVO;
@@ -18,6 +20,7 @@
import javax.annotation.Resource;
import javax.servlet.http.HttpServletResponse;
import java.time.LocalDate;
import java.util.List;
/**
@@ -47,6 +50,15 @@
        List<DaPassingStationCollection> list = daPassingStationCollectionService.selectDaPassingStationCollectionList(daPassingStationCollection);
        return getDataTable(list);
    }
    @GetMapping("/selectDaPassingStationCollectionForSearch")
    public TableDataInfo selectDaPassingStationCollectionForSearch(DaPassingStationCollection daPassingStationCollection)
    {
        startPage();
        List<DaPassingStationCollection> list = daPassingStationCollectionService.selectDaPassingStationCollectionForSearch(daPassingStationCollection);
        return getDataTable(list);
    }
    @GetMapping("/getTopProcess")
    public TableDataInfo getTopProcess()
@@ -152,4 +164,23 @@
//        }
//        return passingStationCollectionServiceImpl.sendMessage(message);
//    }
    @GetMapping("/getProductNum")
    public R getProductNum(DaPassingStationCollection daPassingStationCollection){
        LocalDate queryDate = daPassingStationCollection.getQueryDate();
        String queryMonth = daPassingStationCollection.getQueryMonth();
        if (ObjectUtil.isNull(queryDate) && ObjectUtil.isNull(queryMonth)){
            return R.fail("请选择月份或者日期");
        }
        if (ObjectUtil.isNotEmpty(queryMonth) && ObjectUtil.isNotEmpty(queryDate)){
            String queryDateString = queryDate.toString();
            String queryMonthString = queryMonth.toString();
            if (!queryDateString.contains(queryMonthString)){
                return R.fail("请确认选择的月份和日期月份是否匹配");
            }
        }
        List<ProductNumVO> productNum = daPassingStationCollectionService.getProductNum(daPassingStationCollection);
        return R.ok(productNum);
    }
}
jcdm-main/src/main/java/com/jcdm/main/da/passingStationCollection/domain/DaPassingStationCollection.java
@@ -1,5 +1,6 @@
package com.jcdm.main.da.passingStationCollection.domain;
import java.time.LocalDate;
import java.util.Date;
import com.alibaba.excel.annotation.ExcelIgnoreUnannotated;
@@ -51,17 +52,15 @@
    /** äº§å“ç¼–号 */
    @Excel(name = "产品编号")
    @ExcelProperty(value = "产品编号", index = 2)
    private String productCode;
    /** äº§çº¿ç¼–号 */
    @Excel(name = "产线编号")
    @ExcelProperty(value = "产线编号", index = 3)
    private String productionLine;
    /** å·¥ä½ç¼–号 */
    @Excel(name = "工位编号")
    @ExcelProperty(value = "工位编号", index = 4)
    @ExcelProperty(value = "工位编号", index = 2)
    private String locationCode;
    /** è®¾å¤‡ç¼–号 */
@@ -73,7 +72,7 @@
    @Excel(name = "入站时间")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @ExcelProperty(value = "入站时间", index = 5)
    @ExcelProperty(value = "入站时间", index = 3)
    private Date inboundTime;
    /** å‡ºç«™æ—¶é—´ */
@@ -81,7 +80,7 @@
    @Excel(name = "出站时间")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @ExcelProperty(value = "出站时间", index = 6)
    @ExcelProperty(value = "出站时间", index = 4)
    private Date outboundTime;
    @TableField(exist = false)
@@ -100,12 +99,11 @@
    /** å‡ºç«™æ˜¯å¦åˆæ ¼ */
    @Excel(name = "出站是否合格")
    @ExcelProperty(value = "是否合格", index = 7)
    @ExcelProperty(value = "是否合格", index = 5)
    private String outRsSign;
    /** å‡ºç«™NG原因 */
    @Excel(name = "出站NG原因")
    @ExcelProperty(value = "NG原因", index = 8)
    private String outMsgSign;
    /** é‡‡é›†æ—¶é—´ */
@@ -113,7 +111,7 @@
    @Excel(name = "采集时间")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @ExcelProperty(value = "采集时间", index = 9)
    @ExcelProperty(value = "采集时间", index = 6)
    private Date collectionTime;
    /** é¢„留字段1 */
@@ -130,7 +128,6 @@
    /** èŠ‚拍时间 */
    @Excel(name = "节拍时间")
    @ExcelProperty(value = "节拍时间", index = 10)
    private String beatTime;
    @TableField(exist = false)
@@ -138,6 +135,14 @@
    private Long[] ids;
    @TableField(exist = false)
    @DateTimeFormat(pattern = "yyyy-MM-dd")
    @JsonFormat(pattern = "yyyy-MM-dd")
    private LocalDate queryDate;
    @TableField(exist = false)
    private String queryMonth;
    public Long[] getIds() {
        return ids;
    }
jcdm-main/src/main/java/com/jcdm/main/da/passingStationCollection/domain/ProductNumVO.java
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,19 @@
package com.jcdm.main.da.passingStationCollection.domain;
import com.jcdm.common.annotation.Excel;
import lombok.Data;
@Data
public class ProductNumVO {
    @Excel(name = "日期")
    private String queryDate;
    @Excel(name = "机型")
    private String model;
    @Excel(name = "产量")
    private Integer num;
}
jcdm-main/src/main/java/com/jcdm/main/da/passingStationCollection/mapper/DaPassingStationCollectionMapper.java
@@ -29,6 +29,7 @@
     * @return äº§å“è¿‡ç«™é‡‡é›†é›†åˆ
     */
    public List<DaPassingStationCollection> selectDaPassingStationCollectionList(DaPassingStationCollection daPassingStationCollection);
    public List<DaPassingStationCollection> selectDaPassingStationCollectionForSearch(DaPassingStationCollection daPassingStationCollection);
    public List<DaPassingStationCollection> getListBySfcCode(@Param("engineNoList") List<String> engineNoList);
jcdm-main/src/main/java/com/jcdm/main/da/passingStationCollection/service/IDaPassingStationCollectionService.java
@@ -2,6 +2,7 @@
import com.jcdm.main.bs.orderScheduling.domain.BsOrderScheduling;
import com.jcdm.main.da.passingStationCollection.domain.DaPassingStationCollection;
import com.jcdm.main.da.passingStationCollection.domain.ProductNumVO;
import com.jcdm.main.da.passingStationCollection.vo.DaPassingStationVO;
import java.util.List;
@@ -29,6 +30,7 @@
     * @return äº§å“è¿‡ç«™é‡‡é›†é›†åˆ
     */
    public List<DaPassingStationCollection> selectDaPassingStationCollectionList(DaPassingStationCollection daPassingStationCollection);
    public List<DaPassingStationCollection> selectDaPassingStationCollectionForSearch(DaPassingStationCollection daPassingStationCollection);
    public List<DaPassingStationVO> getTopProcess(DaPassingStationCollection daPassingStationCollection);
@@ -80,4 +82,6 @@
     * @return ç»“æžœ
     */
    public String SelectSN(String SNcode,String node);
    public List<ProductNumVO> getProductNum(DaPassingStationCollection daPassingStationCollection);
}
jcdm-main/src/main/java/com/jcdm/main/da/passingStationCollection/service/impl/DaPassingStationCollectionServiceImpl.java
@@ -3,12 +3,14 @@
import cn.hutool.core.collection.CollUtil;
import cn.hutool.core.util.ObjectUtil;
import com.alibaba.fastjson2.JSONObject;
import com.jcdm.common.core.domain.R;
import com.jcdm.common.utils.DateUtils;
import com.jcdm.common.utils.StringUtils;
import com.jcdm.main.bs.orderScheduling.domain.BsOrderScheduling;
import com.jcdm.main.bs.orderScheduling.mapper.BsOrderSchedulingMapper;
import com.jcdm.main.bs.orderScheduling.service.IBsOrderSchedulingService;
import com.jcdm.main.da.passingStationCollection.domain.DaPassingStationCollection;
import com.jcdm.main.da.passingStationCollection.domain.ProductNumVO;
import com.jcdm.main.da.passingStationCollection.mapper.DaPassingStationCollectionMapper;
import com.jcdm.main.da.passingStationCollection.service.IDaPassingStationCollectionService;
import com.jcdm.main.da.passingStationCollection.vo.DaPassingStationVO;
@@ -69,6 +71,11 @@
    public List<DaPassingStationCollection> selectDaPassingStationCollectionList(DaPassingStationCollection daPassingStationCollection)
    {
        return daPassingStationCollectionMapper.selectDaPassingStationCollectionList(daPassingStationCollection);
    }
    @Override
    public List<DaPassingStationCollection> selectDaPassingStationCollectionForSearch(DaPassingStationCollection daPassingStationCollection) {
        return daPassingStationCollectionMapper.selectDaPassingStationCollectionForSearch(daPassingStationCollection);
    }
    @Override
@@ -251,6 +258,39 @@
        }
    }
    @Override
    public List<ProductNumVO> getProductNum(DaPassingStationCollection daPassingStationCollection) {
        String queryMonth = daPassingStationCollection.getQueryMonth();
        LocalDate queryLocalDate = daPassingStationCollection.getQueryDate();
        if (ObjectUtil.isNotEmpty(queryLocalDate)){
            LocalDate addQueryLocalDate = queryLocalDate.plusDays(1);
            String queryDate = queryLocalDate.toString();
            String addQueryDate = addQueryLocalDate.toString();
            List<ProductNumVO> productNum = bsOrderSchedulingMapper.getProductNum(queryDate, addQueryDate);
            if (CollUtil.isNotEmpty(productNum)){
                productNum.forEach(x -> {
                    x.setQueryDate(queryDate);
                });
            }
            return productNum;
        } else if (ObjectUtil.isNull(queryLocalDate) && ObjectUtil.isNotNull(queryMonth)){
            //按月份查询
            String s = queryMonth + "-01";
            LocalDate parse = LocalDate.parse(s);
            LocalDate localDate = parse.plusMonths(1);
            String queryDate = parse.toString();
            String addQueryDate = localDate.toString();
            List<ProductNumVO> productNum = bsOrderSchedulingMapper.getProductNum(queryDate, addQueryDate);
            if (CollUtil.isNotEmpty(productNum)){
                productNum.forEach(x -> {
                    x.setQueryDate(queryMonth);
                });
            }
            return productNum;
        }
        return new ArrayList<ProductNumVO>();
    }
//    public String sendMessage(String message) throws Exception{
//        Map<String,Object> map = new HashMap<>();
//
jcdm-main/src/main/java/com/jcdm/main/om/productionOrde/domain/OmProductionOrdeInfo.java
@@ -139,11 +139,9 @@
    /** ä¿®æ”¹äºº */
    @Excel(name = "修改人")
    private String updateUser;
    /** å¤‡æ³¨ */
    @Excel(name = "备注")
    private String remarks;
    /** æµæ°´å· */
jcdm-main/src/main/java/com/jcdm/main/plcserver/conf/OPCElement.java
@@ -1,5 +1,7 @@
package com.jcdm.main.plcserver.conf;
import java.time.LocalDateTime;
/**
 * @ClassName: OPCElement
 * @Description: PC和PLC通信使用的OPCserver上的标记名称列表
@@ -32,7 +34,7 @@
    public static final String OP120_ZZ_CODE_CHECK = OP120_ITEM_ZZ + "CodeCheck";//请求保存
    public static final String OP060_HX_CODE_CHECK = OP060_ITEM_ZZ + "CodeCheck";//请求保存
    public static final String OP020_HX_CODE_CHECK = OP020_ITEM_HX + "CodeCheck";//请求保存
    public static final String OP121_ZZ_CODE_CHECK = OP121_ITEM_ZZ + "CodeCheckFeed";//请求保存
    public static final String OP121_ZZ_CODE_CHECK = OP120_ITEM_ZZ + "CodeCheckFeed";//请求保存
    public static final String OP050_HX_CODE_CHECK = "CFL4HX.OP050.CodeCheck";//请求保存
    //返修监听点位-465
jcdm-main/src/main/java/com/jcdm/main/plcserver/sub/OPCUaSubscription.java
@@ -316,6 +316,23 @@
                }
                logger.info("-----返回codeCheckFeed-----,{}",a);
//                String a="1";
                //zz上线工位查询hx线是否过站合格
                if (OPCElement.OP120_ZZ_CODE_CHECK.equals(Node)){
                    //过站记录
                    DaPassingStationCollection PassingStationCollection=new DaPassingStationCollection();
                    PassingStationCollection.setSfcCode(SNCode);
                    PassingStationCollection.setLocationCode("OP160");
                    List<DaPassingStationCollection> ZZOP120PassCheck = passingStationCollectionServiceImpl.selectDaPassingStationCollectionList(PassingStationCollection);
                    if (CollUtil.isEmpty(ZZOP120PassCheck)){
                        a = "";
                    } else {
                        DaPassingStationCollection passingStationCollection = ZZOP120PassCheck.get(0);
                        String outRsSign = passingStationCollection.getOutRsSign();
                        if (!OPCElement.QUALIFIED.equals(outRsSign)){
                            a = "";
                        }
                    }
                }
                // 1:OK可生产 2:NG不可生产 3:NG可返工 4:PC检索失败(无记录)5:PC检索失败(软件)
                if (StrUtil.isNotBlank(a)){
                    int input = Integer.parseInt(a);
@@ -621,7 +638,7 @@
                                ParamCollection.setParamValue(readWriteEntityList.get(i).getValue().toString());
                            }
                            ParamCollection.setSfcCode(SNCode);
                            ParamCollection.setParamName(list.get(i).getCollectParameterName());
                            ParamCollection.setParamName(list.get(i).getParameterSetName());
                            ParamCollection.setParamUpper(list.get(i).getParamUpper());
                            ParamCollection.setParamLower(list.get(i).getParamLower());
                            ParamCollection.setUnit(list.get(i).getCollectParameterUnit());
@@ -654,6 +671,7 @@
            }
            DaPassingStationCollection PassingStationCollection=new DaPassingStationCollection();
            PassingStationCollection.setSfcCode(SNCode);
            PassingStationCollection.setProductCode(bsOrderScheduling.getModel());
            PassingStationCollection.setLocationCode(parts[1]);
            PassingStationCollection.setOutboundTime(new Date());
            PassingStationCollection.setInboundTime(new Date(new Date().getTime()-beatTime*1000));
jcdm-main/src/main/resources/mapper/bs/beatSetting/ProductNumTableMapper.xml
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,55 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.jcdm.main.bs.beatSetting.mapper.ProductNumTableMapper">
    <resultMap type="ProductNumTable" id="ProductNumTableResult">
        <result property="id"    column="id"    />
        <result property="zzOfflineNum"    column="zz_offline_num"    />
        <result property="zzOnlineNum"    column="zz_online_num"    />
        <result property="hxOnlineNum"    column="hx_online_num"    />
        <result property="productTime"    column="product_time"    />
        <result property="model"    column="model"    />
        <result property="productNumTheory"    column="product_num_theory"    />
    </resultMap>
    <sql id="selectProductNumVo">
        select id, zz_offline_num, zz_online_num, hx_online_num, product_time, model from product_num_table
    </sql>
    <insert id="insertProductNum">
        INSERT INTO product_num_table (id, zz_offline_num,zz_online_num,hx_online_num,product_time,model,product_num_theory )
        VALUES
        <foreach collection="list" item="item" index="index" separator=",">
            (#{item.id}, #{item.zzOfflineNum}, #{item.zzOnlineNum}, #{item.hxOnlineNum}, #{item.productTime},#{item.model},#{item.productNumTheory})
        </foreach>
    </insert>
    <update id="updateProductNum">
        update product_num_table
        <trim prefix="SET" suffixOverrides=",">
            <if test="zzOfflineNum != null">zz_offline_num = #{zzOfflineNum},</if>
            <if test="zzOnlineNum != null">zz_online_num = #{zzOnlineNum},</if>
            <if test="hxOnlineNum != null ">hx_online_num = #{hxOnlineNum},</if>
            <if test="productTime != null">product_time = #{productTime},</if>
            <if test="model != null and model != ''">model = #{model},</if>
            <if test="productNumTheory != null">product_num_theory = #{productNumTheory},</if>
        </trim>
        where id = #{id}
    </update>
    <select id="selectProductNum" parameterType="ProductNumTable" resultMap="ProductNumTableResult">
        <include refid="selectProductNumVo"/>
        <where>
            <if test="id != null  and id != ''"> and id = #{id}</if>
            <if test="zzOfflineNum != null  and zzOfflineNum != ''"> and zz_offline_num = #{zzOfflineNum}</if>
            <if test="zzOnlineNum != null  and zzOnlineNum != ''"> and zz_online_num = #{zzOnlineNum}</if>
            <if test="hxOnlineNum != null  and hxOnlineNum != ''"> and hx_online_num = #{hxOnlineNum}</if>
            <if test="productTime != null "> and product_time = #{productTime}</if>
            <if test="model != null  and model != ''"> and model = #{model}</if>
        </where>
    </select>
</mapper>
jcdm-main/src/main/resources/mapper/bs/orderScheduling/BsOrderSchedulingMapper.xml
@@ -172,6 +172,28 @@
        select count(*) from bs_order_scheduling
        where ${queryField} BETWEEN #{startTime} AND #{endTime}
    </select>
    <select id="getProductNum" resultType="com.jcdm.main.da.passingStationCollection.domain.ProductNumVO">
        SELECT model,count(*) as num FROM bs_order_scheduling
        <where>
            <if test="queryDate != null and queryDate != ''">
             final_assembly_offline_time between #{queryDate} and #{addQueryDate}
            </if>
        </where>
        GROUP BY model
    </select>
    <select id="selectBsOrderSchedulingListForNum"
            parameterType="BsOrderScheduling" resultMap="BsOrderSchedulingResult">
        select model,final_assembly_offline_time,final_assembly_launch_time,box_closing_online_time
        from bs_order_scheduling
        <where>
            <if test="queryDate != null and queryDate != ''">
                final_assembly_offline_time between #{queryDate} and #{addQueryDate}
        or final_assembly_launch_time between #{queryDate} and #{addQueryDate}
        or box_closing_online_time between #{queryDate} and #{addQueryDate}
            </if>
        </where>
    </select>
    <insert id="insertBsOrderScheduling" parameterType="BsOrderScheduling" useGeneratedKeys="true" keyProperty="id">
@@ -297,4 +319,6 @@
            #{id}
        </foreach>
    </delete>
</mapper>
jcdm-main/src/main/resources/mapper/da/paramCollection/DaParamCollectionMapper.xml
@@ -35,6 +35,27 @@
        select id, work_order_no, sfc_code, product_code, production_line, location_code, equipment_no, param_code, param_value, param_upper, param_lower, param_standard, collection_time, spare_field_1, spare_field_2, create_user, create_time, update_user, update_time, state, param_name, unit, type, repair_flag from da_param_collection
    </sql>
    <sql id="queryDaParamCollectionForSearch">
        select id, work_order_no, sfc_code, product_code, location_code, param_code, param_value, param_upper, param_lower, collection_time, state, param_name, unit, type from da_param_collection
    </sql>
    <select id="queryDaParamCollectionListForSearch" parameterType="DaParamCollection" resultMap="DaParamCollectionResult">
        <include refid="queryDaParamCollectionForSearch"/>
        <where>
            <if test="workOrderNo != null  and workOrderNo != ''"> and work_order_no = #{workOrderNo}</if>
            <if test="type != null  and type != ''"> and type = #{type}</if>
            <if test="sfcCode != null  and sfcCode != ''"> and sfc_code = #{sfcCode}</if>
            <if test="productCode != null  and productCode != ''"> and product_code = #{productCode}</if>
            <if test="productionLine != null  and productionLine != ''"> and production_line = #{productionLine}</if>
            <if test="locationCode != null  and locationCode != ''"> and location_code = #{locationCode}</if>
            <if test="equipmentNo != null  and equipmentNo != ''"> and equipment_no = #{equipmentNo}</if>
            <if test="paramCode != null  and paramCode != ''"> and param_code = #{paramCode}</if>
            <if test="paramValue != null  and paramValue != ''"> and param_value = #{paramValue}</if>
            <if test="dateConditions != null  and dateConditions != ''"> and collection_time BETWEEN #{startTime} AND #{endTime}</if>
        </where>
        ORDER BY id DESC
    </select>
    <select id="selectDaParamCollectionList" parameterType="DaParamCollection" resultMap="DaParamCollectionResult">
        <include refid="selectDaParamCollectionVo"/>
        <where>  
jcdm-main/src/main/resources/mapper/da/passingStationCollection/DaPassingStationCollectionMapper.xml
@@ -33,6 +33,27 @@
        select id, work_order_no, sfc_code, product_code, production_line, location_code, equipment_no, inbound_time, outbound_time, in_rs_sign, in_msg_sign, out_rs_sign, out_msg_sign, collection_time, spare_field_1, spare_field_2, create_user, create_time, update_user, update_time, beat_time, repair_flag from da_passing_station_collection
    </sql>
    <sql id="selectDaPassingStationCollectionForSearch">
        select id, work_order_no, sfc_code, product_code, location_code, inbound_time, outbound_time, out_rs_sign, collection_time from da_passing_station_collection
    </sql>
    <select id="selectDaPassingStationCollectionForSearch" parameterType="DaPassingStationCollection" resultMap="DaPassingStationCollectionResult">
        <include refid="selectDaPassingStationCollectionForSearch"/>
        <where>
            <if test="workOrderNo != null  and workOrderNo != ''"> and work_order_no = #{workOrderNo}</if>
            <if test="sfcCode != null  and sfcCode != ''"> and sfc_code = #{sfcCode}</if>
            <if test="productCode != null  and productCode != ''"> and product_code = #{productCode}</if>
            <if test="productionLine != null  and productionLine != ''"> and production_line = #{productionLine}</if>
            <if test="locationCode != null  and locationCode != ''"> and location_code = #{locationCode}</if>
            <if test="equipmentNo != null  and equipmentNo != ''"> and equipment_no = #{equipmentNo}</if>
            <if test="inboundTime != null "> and CAST(inbound_time as DATE) = #{inboundTime}</if>
            <if test="outboundTime != null "> and CAST(outbound_time as DATE) = #{outboundTime}</if>
            <if test="outRsSign != null "> and out_rs_sign = #{outRsSign}</if>
            <if test="outRsSign != null "> and out_rs_sign = #{outRsSign}</if>
            <if test="startTime != null and startTime != '' and endTime != null and endTime != ''"> and outbound_time between #{startTime} and #{endTime}</if>
        </where>
    </select>
    <select id="selectDaPassingStationCollectionList" parameterType="DaPassingStationCollection" resultMap="DaPassingStationCollectionResult">
        <include refid="selectDaPassingStationCollectionVo"/>
        <where>  
jcdm-quartz/src/main/java/com/jcdm/quartz/task/RyTask.java
@@ -1,6 +1,12 @@
package com.jcdm.quartz.task;
import cn.hutool.core.collection.CollUtil;
import cn.hutool.core.util.ObjectUtil;
import cn.hutool.core.util.StrUtil;
import com.jcdm.main.bs.beatSetting.domain.BsBeatSetting;
import com.jcdm.main.bs.beatSetting.domain.ProductNumTable;
import com.jcdm.main.bs.beatSetting.service.IBsBeatSettingService;
import com.jcdm.main.bs.beatSetting.service.ProductNumTableService;
import com.jcdm.main.bs.orderScheduling.domain.BsOrderScheduling;
import com.jcdm.main.bs.orderScheduling.service.IBsOrderSchedulingService;
import com.jcdm.main.da.passingStationCollection.service.IDaPassingStationCollectionService;
@@ -15,8 +21,11 @@
import org.slf4j.LoggerFactory;
import javax.annotation.Resource;
import java.util.List;
import java.util.Map;
import java.time.Duration;
import java.time.LocalDate;
import java.time.LocalDateTime;
import java.time.temporal.ChronoUnit;
import java.util.*;
import java.util.stream.Collectors;
/**
@@ -34,6 +43,12 @@
    @Resource
    private OmProductionOrdeInfoServiceImpl omProductionOrdeInfoService;
    @Resource
    private IBsBeatSettingService bsBeatSettingService;
    @Resource
    private ProductNumTableService productNumTableService;
    private static final Logger logger = LoggerFactory.getLogger("sys-user");
@@ -87,6 +102,7 @@
    public void workReportingTasks(){
        report10();
        report20();
        updateProductNum();
    }
    public void report10(){
@@ -171,6 +187,196 @@
        }
    }
    public void updateProductNum(){
        LocalDate now = LocalDate.now();
        ProductNumTable productNumTableQuery = new ProductNumTable();
        productNumTableQuery.setProductTime(now);
        //已存在的统计数据
        List<ProductNumTable> productNumTableList = productNumTableService.selectProductList(productNumTableQuery);
        String actModel;
        //获取当天所有生产数据
        List<BsOrderScheduling> bsOrderSchedulingList = bsOrderSchedulingService.selectBsOrderSchedulingListForNum();
        if (CollUtil.isNotEmpty(bsOrderSchedulingList)){
            List<BsOrderScheduling> tempList = bsOrderSchedulingList.stream()
                    .filter(x -> ObjectUtil.isNotNull(x.getFinalAssemblyOfflineTime()))
                    .collect(Collectors.toList());
            List<BsOrderScheduling> collect2 = tempList.stream()
                    .sorted(Comparator.comparing(BsOrderScheduling::getFinalAssemblyOfflineTime).reversed())
                    .collect(Collectors.toList());
            if (CollUtil.isNotEmpty(collect2)){
                BsOrderScheduling bsOrderScheduling = collect2.get(0);
                actModel = bsOrderScheduling.getModel();
            } else {
                actModel = null;
            }
            List<String> modelList = tempList.stream().map(BsOrderScheduling::getModel).distinct().collect(Collectors.toList());
            Integer modelNum = 0;
            if (CollUtil.isNotEmpty(modelList)){
                modelNum = modelList.size();
            }
            Integer productNumTheory = caculateProductNumTheory(actModel, now, modelNum);
            List<ProductNumTable> saveDate = new ArrayList<>();
            Map<String, List<BsOrderScheduling>> collect = bsOrderSchedulingList.stream().collect(Collectors.groupingBy(BsOrderScheduling::getModel));
            for (String s : collect.keySet()) {
                List<BsOrderScheduling> bsOrderSchedulingList1 = collect.get(s);
                //合箱上线
                long count1 = bsOrderSchedulingList1.stream().filter(x -> ObjectUtil.isNotNull(x.getBoxClosingOnlineTime())).count();
                //总装上线
                long count2 = bsOrderSchedulingList1.stream().filter(x -> ObjectUtil.isNotNull(x.getFinalAssemblyLaunchTime())).count();
                //总装下线
                long count3 = bsOrderSchedulingList1.stream().filter(x -> ObjectUtil.isNotNull(x.getFinalAssemblyOfflineTime())).count();
                //检查判断是更新还是插入
                List<ProductNumTable> collect1 = productNumTableList.stream().filter(x -> s.equals(x.getModel())).collect(Collectors.toList());
                if (CollUtil.isEmpty(collect1)){
                    //插入
                    ProductNumTable productNumTable = new ProductNumTable();
                    UUID uuid = UUID.randomUUID();
                    productNumTable.setId(uuid.getMostSignificantBits());
                    productNumTable.setModel(s);
                    productNumTable.setHxOnlineNum((int) count1);
                    productNumTable.setZzOnlineNum((int) count2);
                    productNumTable.setZzOfflineNum((int) count3);
                    productNumTable.setProductTime(now);
                    productNumTable.setProductNumTheory(productNumTheory);
                    saveDate.add(productNumTable);
                } else {
                    //更新
                    //判断是否需要更新
                    ProductNumTable productNumTable = collect1.get(0);
                    Integer hxOnlineNum = productNumTable.getHxOnlineNum();
                    Integer zzOnlineNum = productNumTable.getZzOnlineNum();
                    Integer zzOfflineNum = productNumTable.getZzOfflineNum();
                    if (!hxOnlineNum.equals((int)count1) || !zzOnlineNum.equals((int) count2) || !zzOfflineNum.equals((int)count3)){
                        //更新
                        productNumTable.setHxOnlineNum((int) count1);
                        productNumTable.setZzOnlineNum((int) count2);
                        productNumTable.setZzOfflineNum((int) count3);
                        productNumTable.setProductNumTheory(productNumTheory);
                        productNumTableService.updateProductNum(productNumTable);
                    }
                }
            }
            if (CollUtil.isNotEmpty(saveDate)){
                productNumTableService.insertProductList(saveDate);
            }
        }
    }
    private Integer caculateProductNumTheory(String actModel, LocalDate now,Integer modelNum) {
        long l = System.currentTimeMillis();
        System.out.println("开始:----"+l);
        //计算总产量数据
        String beat = "";
        List<BsBeatSetting> bsBeatSettings = bsBeatSettingService.selectBsBeatSettingList(new BsBeatSetting());
        if (ObjectUtil.isNotNull(actModel)){
            List<BsBeatSetting> collect = bsBeatSettings.stream().filter(x -> actModel.contains(x.getProductCode())).collect(Collectors.toList());
            if (CollUtil.isNotEmpty(collect)){
                BsBeatSetting bsBeatSetting = collect.get(0);
                beat = bsBeatSetting.getBeat();
            }
        }
        LocalDateTime nowTime = LocalDateTime.now();
        long workTime = 0;
        LocalDateTime time1 = now.atTime(0, 0, 0);
        LocalDateTime time_rest = now.atTime(0, 30, 0);
        LocalDateTime time2 = now.atTime(3, 0, 0);
        LocalDateTime time3 = now.atTime(3, 10, 0);
        LocalDateTime time4 = now.atTime(5, 0, 0);
        LocalDateTime time5 = now.atTime(5, 10, 0);
        LocalDateTime time6 = now.atTime(7, 0, 0);
        LocalDateTime time7 = now.atTime(8, 0, 0);
        LocalDateTime time8 = now.atTime(10, 0, 0);
        LocalDateTime time9 = now.atTime(10, 10, 0);
        LocalDateTime time10 = now.atTime(11, 10, 0);
        LocalDateTime time11 = now.atTime(12, 10, 0);
        LocalDateTime time12 = now.atTime(15, 0, 0);
        LocalDateTime time13 = now.atTime(15, 10, 0);
        LocalDateTime time14 = now.atTime(20, 0, 0);
        LocalDateTime time15 = now.atTime(20, 10, 0);
        LocalDateTime time16 = now.atTime(22, 0, 0);
        LocalDateTime time17 = now.atTime(22, 10, 0);
        LocalDateTime time18 = now.atTime(23, 59, 59);
        if (nowTime.isBefore(time_rest)){
            //0-0.30
            workTime = 0;
        } else if (nowTime.isBefore(time2)){
            //0-3
            workTime = ChronoUnit.SECONDS.between(time1,nowTime)  - 1800;
        } else if (nowTime.isBefore(time3)){
            //0-3.10
            workTime = ChronoUnit.SECONDS.between(time1,time2)  - 1800;
        } else if (nowTime.isBefore(time4)){
            //0-5
            workTime = ChronoUnit.SECONDS.between(time1,nowTime)  - 2400;
        } else if (nowTime.isBefore(time5)){
            //0-5.10
            workTime = ChronoUnit.SECONDS.between(time1,time4)  - 2400;
        } else if (nowTime.isBefore(time6)){
            //0-7
            workTime = ChronoUnit.SECONDS.between(time1,nowTime)  - 3000;
        } else if (nowTime.isBefore(time7)){
            //0-8
            workTime = ChronoUnit.SECONDS.between(time1,time6)  - 3000;
        } else if (nowTime.isBefore(time8)){
            //0-10
            workTime = ChronoUnit.SECONDS.between(time1,nowTime)  - 6600;
        } else if (nowTime.isBefore(time9)){
            //0-10.10
            workTime = ChronoUnit.SECONDS.between(time1,time8)  - 6600;
        } else if (nowTime.isBefore(time10)){
            //0-11.10
            workTime = ChronoUnit.SECONDS.between(time1,nowTime)  - 7200;
        } else if (nowTime.isBefore(time11)){
            //0-12.10
            workTime = ChronoUnit.SECONDS.between(time1,time10)  - 7200;
        }  else if (nowTime.isBefore(time12)){
            //0-15
            workTime = ChronoUnit.SECONDS.between(time1,nowTime)  - 7200 - 3600;
        } else if (nowTime.isBefore(time13)){
            //0-15.10
            workTime = ChronoUnit.SECONDS.between(time1,time12)  - 7200 - 3600;
        } else if (nowTime.isBefore(time14)){
            //0-20
            workTime = ChronoUnit.SECONDS.between(time1,nowTime)  - 7200 - 3600 - 600;
        } else if (nowTime.isBefore(time15)){
            //0-20.10
            workTime = ChronoUnit.SECONDS.between(time1,time14)  - 7200 - 3600 - 600;
        } else if (nowTime.isBefore(time16)){
            //0-22
            workTime = ChronoUnit.SECONDS.between(time1,nowTime)  - 7200 - 3600 - 600 - 600;
        } else if (nowTime.isBefore(time17)){
            //0-22.10
            workTime = ChronoUnit.SECONDS.between(time1,time16)  - 7200 - 3600 - 600 - 600;
        } else if (nowTime.isBefore(time18)){
            //0-24
            workTime = ChronoUnit.SECONDS.between(time1,nowTime)  - 7200 - 3600 - 600 - 600 - 600;
        }
        if (modelNum > 1){
            workTime = workTime - 1800L *(modelNum-1);
            if (workTime <0){
                workTime = 0;
            }
        }
        System.out.println(workTime+"---------");
        long l2 = System.currentTimeMillis();
        System.out.println("结束:----"+l2);
        long l1 = l2 - l;
        System.out.println("耗费时间:----"+l1);
        //理论产量
        Integer productNumTheory = 0;
        if (StrUtil.isNotBlank(beat)){
            int i = Integer.parseInt(beat);
            Integer workTimeInt = (int) workTime;
            productNumTheory = Math.floorDiv(workTimeInt, i);
        }
        return productNumTheory;
    }
    public static String getProductionPlanInformationXml(String orderNo,String location){
        String content = "<soapenv:Envelope xmlns:soapenv=\"http://schemas.xmlsoap.org/soap/envelope/\" xmlns:urn=\"urn:sap-com:document:sap:rfc:functions\">\n" +
                "   <soapenv:Header/>\n" +
jcdm-ui/src/api/main/da/paramCollection/paramCollection.js
@@ -9,6 +9,14 @@
  })
}
export function queryDaParamCollectionListForSearch(query) {
  return request({
    url: '/main/paramCollection/queryDaParamCollectionListForSearch',
    method: 'get',
    params: query
  })
}
// æŸ¥è¯¢è®¾å¤‡äº§å“è¿‡ç¨‹å‚数采集详细
export function getParamCollection(id) {
  return request({
jcdm-ui/src/api/main/da/passingStationCollection/passingStationCollection.js
@@ -8,6 +8,14 @@
    params: query
  })
}
export function selectDaPassingStationCollectionForSearch(query) {
  return request({
    url: '/da/passingStationCollection/selectDaPassingStationCollectionForSearch',
    method: 'get',
    params: query
  })
}
//查询首页top五数据
export function getTopProcess() {
  return request({
@@ -75,3 +83,11 @@
    method: 'delete'
  })
}
export function getProductNum(query) {
  return request({
    url: '/da/passingStationCollection/getProductNum',
    method: 'get',
    params: query
  })
}
jcdm-ui/src/views/dashboard/PanelGroup.vue
@@ -39,22 +39,22 @@
            <span class="nextLine">{{data4}}</span>
          </div>
        </div>
        <div class="transition-box" style="background-color: green">
          <i class="el-icon-upload2"></i>
          <el-divider direction="vertical" content-position="left" style="height: 20px"></el-divider>
          <div>
            <span style="margin-left: 20px">CVT上线</span>
            <span class="nextLine">{{data5}}</span>
          </div>
        </div>
        <div class="transition-box" style="background-color: darkslategray">
          <i class="el-icon-finished"></i>
          <el-divider direction="vertical" content-position="left" style="height: 20px"></el-divider>
          <div>
            <span style="margin-left: 20px">CVT下线</span>
            <span class="nextLine">{{data6}}</span>
          </div>
        </div>
<!--        <div class="transition-box" style="background-color: green">-->
<!--          <i class="el-icon-upload2"></i>-->
<!--          <el-divider direction="vertical" content-position="left" style="height: 20px"></el-divider>-->
<!--          <div>-->
<!--            <span style="margin-left: 20px">CVT上线</span>-->
<!--            <span class="nextLine">{{data5}}</span>-->
<!--          </div>-->
<!--        </div>-->
<!--        <div class="transition-box" style="background-color: darkslategray">-->
<!--          <i class="el-icon-finished"></i>-->
<!--          <el-divider direction="vertical" content-position="left" style="height: 20px"></el-divider>-->
<!--          <div>-->
<!--            <span style="margin-left: 20px">CVT下线</span>-->
<!--            <span class="nextLine">{{data6}}</span>-->
<!--          </div>-->
<!--        </div>-->
      </div>
jcdm-ui/src/views/main/bs/orderScheduling/index.vue
@@ -90,14 +90,6 @@
            />
          </el-select>
        </el-form-item>
        <el-form-item label="CVT报工" prop="report30">
          <el-input
            v-model="queryParams.report30"
            placeholder="请输入CVT报工"
            clearable
            @keyup.enter.native="handleQuery"
          />
        </el-form-item>
        <br/>
        <el-form-item label="操作时间" prop="operateTime">
          <el-date-picker
@@ -178,11 +170,11 @@
          <el-table-column label="发动机号" align="center" prop="engineNo" width="150">
          </el-table-column>
          <el-table-column label="产品类型" align="center" prop="productType">
            <template slot-scope="scope">
              <dict-tag :options="dict.type.material_type" :value="scope.row.productType"/>
            </template>
          </el-table-column>
<!--          <el-table-column label="产品类型" align="center" prop="productType">-->
<!--            <template slot-scope="scope">-->
<!--              <dict-tag :options="dict.type.material_type" :value="scope.row.productType"/>-->
<!--            </template>-->
<!--          </el-table-column>-->
          <el-table-column label="机型" align="center" prop="model">
          </el-table-column>
@@ -219,11 +211,6 @@
            </template>
          </el-table-column>
          <el-table-column label="CVT报工" align="center" prop="report30">
          </el-table-column>
          <el-table-column label="报工异常" align="center" prop="report30">
          </el-table-column>
          <el-table-column label="合箱上线时间" align="center" prop="boxClosingOnlineTime" width="160">
            <template slot-scope="scope">
@@ -243,16 +230,6 @@
          <el-table-column label="总装下线时间" align="center" prop="finalAssemblyOfflineTime" width="160">
            <template slot-scope="scope">
              <span>{{ parseTime(scope.row.finalAssemblyOfflineTime, '{y}-{m}-{d} {h}:{i}:{s}') }}</span>
            </template>
          </el-table-column>
          <el-table-column label="CVT上线时间" align="center" prop="cvtLaunchTime" width="160">
            <template slot-scope="scope">
              <span>{{ parseTime(scope.row.cvtLaunchTime, '{y}-{m}-{d} {h}:{i}:{s}') }}</span>
            </template>
          </el-table-column>
          <el-table-column label="CVT下线时间" align="center" prop="cvtOfflineTime" width="160">
            <template slot-scope="scope">
              <span>{{ parseTime(scope.row.cvtOfflineTime, '{y}-{m}-{d} {h}:{i}:{s}') }}</span>
            </template>
          </el-table-column>
          <el-table-column label="操作人" align="center" prop="operator">
@@ -287,11 +264,11 @@
        <el-form-item label="发动机号" prop="engineNo">
          <el-input v-model="form.engineNo" placeholder="请输入发动机号" />
        </el-form-item>
        <el-form-item label="产品类型" prop="productType">
          <el-select v-model="form.productType" placeholder="请选择产品类型">
<!--        <el-form-item label="产品类型" prop="productType">-->
<!--          <el-select v-model="form.productType" placeholder="请选择产品类型">-->
          </el-select>
        </el-form-item>
<!--          </el-select>-->
<!--        </el-form-item>-->
        <el-form-item label="机型" prop="model">
          <el-input v-model="form.model" placeholder="请输入机型" />
        </el-form-item>
@@ -304,25 +281,44 @@
        </el-form-item>
        <el-form-item label="是否打印" prop="whetherOrPrint">
          <el-input v-model="form.whetherOrPrint" placeholder="请输入是否打印" >
            <template></template>
          </el-input>
          <el-select style="width: 93%" v-model="form.whetherOrPrint" placeholder="请选择是否打印">
            <el-option
              v-for="item in printOptions"
              :key="item.value"
              :label="item.label"
              :value="item.value">
            </el-option>
          </el-select>
        </el-form-item>
        <el-form-item label="合箱报工" prop="report10">
          <el-input v-model="form.report10" placeholder="请输入合箱报工" />
          <el-select style="width: 93%" v-model="form.report10" placeholder="请选择合箱报工">
            <el-option
              v-for="item in reportOptions"
              :key="item.value"
              :label="item.label"
              :value="item.value">
            </el-option>
          </el-select>
        </el-form-item>
        <el-form-item label="总装报工" prop="report20">
          <el-input v-model="form.report20" placeholder="请输入总装报工" />
          <el-select style="width: 93%" v-model="form.report20" placeholder="请选择总装报工">
            <el-option
              v-for="item in reportOptions"
              :key="item.value"
              :label="item.label"
              :value="item.value">
            </el-option>
          </el-select>
        </el-form-item>
        <el-form-item label="30报工" prop="report20">
          <el-input v-model="form.report30" placeholder="请输入30报工" />
        </el-form-item>
<!--        <el-form-item label="30报工" prop="report20">-->
<!--          <el-input v-model="form.report30" placeholder="请输入30报工" />-->
<!--        </el-form-item>-->
        <el-form-item label="操作人" prop="operator">
          <el-input v-model="form.operator" placeholder="请输入操作人" />
        </el-form-item>
        <el-form-item label="状态" prop="status">
          <el-select v-model="form.status" placeholder="请选择">
          <el-select v-model="form.productionStatus" placeholder="请选择">
            <el-option
              v-for="item in statusOptions"
              :key="item.value"
@@ -349,6 +345,30 @@
  dicts: ['order_scheduling_produce_status','quality_status','print_status','material_type','workreportingstatus'],
  data() {
    return {
      printOptions: [
        {
          label:'是',
          value: "1"
        },
        {
          label:'否',
          value: "0"
        },
      ],
      reportOptions: [
        {
          label:'已报工',
          value: "1"
        },
        {
          label:'报工异常',
          value: "3"
        },
        {
          label:'待报工',
          value: "0"
        },
      ],
      // é®ç½©å±‚
      loading: true,
      titleName: "",
jcdm-ui/src/views/main/da/followReport/index.vue
@@ -59,9 +59,9 @@
<!--            <el-table-column label="工时" align="center" prop="workingHours">-->
<!--            </el-table-column>-->
            <el-table-column label="工位编号" align="center" prop="currentWorkstation">
<!--            <el-table-column label="工位编号" align="center" prop="currentWorkstation">-->
            </el-table-column>
<!--            </el-table-column>-->
            <el-table-column label="质量状态" align="center" prop="qualityStatus">
              <template slot-scope="scope">
                <dict-tag :options="dict.type.quality_status" :value="scope.row.qualityStatus"/>
@@ -75,10 +75,10 @@
            </el-table-column>
            <el-table-column label="总装下线时间" align="center" prop="finalAssemblyOfflineTime" width="160">
            </el-table-column>
            <el-table-column label="CVT上线时间" align="center" prop="cvtLaunchTime" width="160">
            </el-table-column>
            <el-table-column label="CVT下线时间" align="center" prop="cvtOfflineTime" width="160">
            </el-table-column>
<!--            <el-table-column label="CVT上线时间" align="center" prop="cvtLaunchTime" width="160">-->
<!--            </el-table-column>-->
<!--            <el-table-column label="CVT下线时间" align="center" prop="cvtOfflineTime" width="160">-->
<!--            </el-table-column>-->
            <el-table-column label="操作人" align="center" prop="operator">
            </el-table-column>
@@ -103,10 +103,10 @@
          <span slot="label"><i class="el-icon-date"></i>拧紧数据</span>
          <report1 :list1 = this.list1></report1>
        </el-tab-pane>
        <el-tab-pane>
          <span slot="label"><i class="el-icon-date"></i>相机检测</span>
          <report2 :list2 = this.list2></report2>
        </el-tab-pane>
<!--        <el-tab-pane>-->
<!--          <span slot="label"><i class="el-icon-date"></i>相机检测</span>-->
<!--          <report2 :list2 = this.list2></report2>-->
<!--        </el-tab-pane>-->
        <el-tab-pane>
          <span slot="label"><i class="el-icon-date"></i>外漏检测</span>
          <report3 :list3 = this.list3></report3>
jcdm-ui/src/views/main/da/followReport/report1.vue
@@ -53,9 +53,9 @@
    <el-table-column
      prop="address"
      align="center"
      label="时间"
      label="采集时间"
      show-overflow-tooltip>
      <template slot-scope="scope">{{ scope.row.createTime }}</template>
      <template slot-scope="scope">{{ scope.row.collectionTime }}</template>
    </el-table-column>
  </el-table>
</template>
jcdm-ui/src/views/main/da/followReport/report2.vue
@@ -53,9 +53,9 @@
    <el-table-column
      prop="address"
      align="center"
      label="时间"
      label="采集时间"
      show-overflow-tooltip>
      <template slot-scope="scope">{{ scope.row.createTime }}</template>
      <template slot-scope="scope">{{ scope.row.collectionTime }}</template>
    </el-table-column>
  </el-table>
</template>
jcdm-ui/src/views/main/da/followReport/report3.vue
@@ -53,9 +53,9 @@
    <el-table-column
      prop="address"
      align="center"
      label="时间"
      label="采集时间"
      show-overflow-tooltip>
      <template slot-scope="scope">{{ scope.row.createTime }}</template>
      <template slot-scope="scope">{{ scope.row.collectionTime }}</template>
    </el-table-column>
  </el-table>
</template>
jcdm-ui/src/views/main/da/followReport/report4.vue
@@ -52,10 +52,10 @@
    </el-table-column>
    <el-table-column
      prop="address"
      label="时间"
      label="采集时间"
      align="center"
      show-overflow-tooltip>
      <template slot-scope="scope">{{ scope.row.createTime }}</template>
      <template slot-scope="scope">{{ scope.row.collectionTime }}</template>
    </el-table-column>
  </el-table>
</template>
jcdm-ui/src/views/main/da/followReport/report5.vue
@@ -35,8 +35,8 @@
    <el-table-column label="是否合格" align="center" prop="outRsSign">
    </el-table-column>
    <el-table-column label="NG原因" align="center" prop="outMsgSign">
    </el-table-column>
<!--    <el-table-column label="NG原因" align="center" prop="outMsgSign">-->
<!--    </el-table-column>-->
    <el-table-column label="采集时间" align="center" prop="collectionTime" width="160">
      <template slot-scope="scope">
        <span>{{ parseTime(scope.row.collectionTime, '{y}-{m}-{d} {h}:{i}:{s}') }}</span>
jcdm-ui/src/views/main/da/paramCollection/index.vue
@@ -18,6 +18,19 @@
          @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item label="日期范围" prop="dateConditions">
        <el-date-picker
          v-model="queryParams.dateConditions"
          type="daterange"
          align="right"
          unlink-panels
          range-separator="至"
          start-placeholder="开始日期"
          end-placeholder="结束日期"
          value-format="yyyy-MM-dd"
          @change="handleDateChange">
        </el-date-picker>
      </el-form-item>
      <el-form-item style="float: right">
        <el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
        <el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button>
@@ -77,10 +90,10 @@
      <el-table-column label="发动机编码" align="center" width="160" prop="sfcCode" ></el-table-column>
<!--      <el-table-column label="产品编号" align="center" prop="productCode"></el-table-column>-->
<!--      <el-table-column label="产线编号" align="center" prop="productionLine"></el-table-column>-->
      <el-table-column label="工位编号" align="center" prop="locationCode"></el-table-column>
<!--      <el-table-column label="设备编号" align="center" prop="equipmentNo"></el-table-column>-->
      <el-table-column label="参数编码" align="center" prop="paramCode"></el-table-column>
      <el-table-column label="参数名称" align="center" prop="paramName" width="150" ></el-table-column>
      <el-table-column label="参数值" align="center" prop="paramValue"></el-table-column>
      <el-table-column label="工位编号" align="center" prop="locationCode"></el-table-column>
      <el-table-column label="参数上限" align="center" prop="paramUpper"></el-table-column>
      <el-table-column label="参数下限" align="center" prop="paramLower"></el-table-column>
      <el-table-column label="采集时间" align="center" prop="collectionTime" width="160">
@@ -89,7 +102,7 @@
        </template>
      </el-table-column>
      <el-table-column label="状态" align="center" prop="state"></el-table-column>
      <el-table-column label="参数名称" align="center" prop="paramName" width="150" ></el-table-column>
      <el-table-column label="参数编码" align="center" prop="paramCode"></el-table-column>
      <el-table-column label="单位" align="center" prop="unit"></el-table-column>
      <el-table-column label="类型" align="center" prop="type"></el-table-column>
      <el-table-column fixed="right" width="200" label="操作" align="center" class-name="small-padding fixed-width" >
@@ -188,11 +201,13 @@
<script>
import { listParamCollection, getParamCollection, delParamCollection, addParamCollection, updateParamCollection } from "@/api/main/da/paramCollection/paramCollection";
import {queryDaParamCollectionListForSearch} from "../../../../api/main/da/paramCollection/paramCollection";
export default {
  name: "ParamCollection",
  data() {
    return {
      maxDate: '',
      // é®ç½©å±‚
      loading: true,
      // é€‰ä¸­æ•°ç»„
@@ -213,6 +228,7 @@
      open: false,
      // æŸ¥è¯¢å‚æ•°
      queryParams: {
        dateConditions: [],
        pageNum: 1,
        pageSize: 10,
        workOrderNo: null,
@@ -258,16 +274,33 @@
    // this.getList();
  },
  methods: {
    handleDateChange(value) {
      if (value && value.length === 2) {
        const startDate = value[0];
        const endDate = value[1];
        const dayCount = this.daysBetween(startDate, endDate);
        if (dayCount + 1 > 7) {
          this.$message.error('请选择连续的7天!');
          this.queryParams.dateConditions = []; // é‡ç½®æ—¥æœŸèŒƒå›´
        }
      }
    },
    daysBetween(startDate, endDate) {
      const oneDay = 24 * 60 * 60 * 1000; // æ¯å¤©çš„毫秒数
      const startTime = new Date(startDate).getTime();
      const endTime = new Date(endDate).getTime();
      return Math.round(Math.abs((startTime - endTime) / oneDay));
    },
    /** æŸ¥è¯¢è®¾å¤‡äº§å“è¿‡ç¨‹å‚数采集列表 */
    getList() {
      this.loading = true;
      if (this.queryParams.sfcCode == null || this.queryParams.sfcCode == ''){
      if ((this.queryParams.sfcCode == null || this.queryParams.sfcCode === '') && this.queryParams.dateConditions.length === 0){
        this.$message({
          message: '请输入发动机号码',
          message: '请输入发动机号码或者选择查询日期',
          type: 'info'
        });
      } else {
        listParamCollection(this.queryParams).then(response => {
        queryDaParamCollectionListForSearch(this.queryParams).then(response => {
          this.paramCollectionList = response.rows;
          this.total = response.total;
          this.loading = false;
jcdm-ui/src/views/main/da/passingStationCollection/index.vue
@@ -76,14 +76,14 @@
    <el-table v-loading="loading" border :data="passingStationCollectionList" @selection-change="handleSelectionChange" v-if="passingStationCollectionList.length > 0">
      <el-table-column type="selection" width="55" align="center" />
      <el-table-column label="工单编号" align="center" prop="workOrderNo">
      <el-table-column label="工单编号" align="center" width="150" prop="workOrderNo">
      </el-table-column>
      <el-table-column label="发动机编码" align="center" prop="sfcCode" width="150">
      </el-table-column>
      <el-table-column label="产品编号" align="center" prop="productCode">
      </el-table-column>
      <el-table-column label="产线编号" align="center" prop="productionLine">
      </el-table-column>
<!--      <el-table-column label="产线编号" align="center" prop="productionLine">-->
<!--      </el-table-column>-->
      <el-table-column label="工位编号" align="center" prop="locationCode">
      </el-table-column>
      <el-table-column label="入站时间" align="center" prop="inboundTime" width="160">
@@ -99,8 +99,8 @@
      <el-table-column label="是否合格" align="center" prop="outRsSign">
      </el-table-column>
      <el-table-column label="NG原因" align="center" prop="outMsgSign">
      </el-table-column>
<!--      <el-table-column label="NG原因" align="center" prop="outMsgSign">-->
<!--      </el-table-column>-->
      <el-table-column label="采集时间" align="center" prop="collectionTime" width="180">
        <template slot-scope="scope">
          <span>{{ parseTime(scope.row.collectionTime, '{y}-{m}-{d} {h}:{i}:{s}') }}</span>
@@ -156,15 +156,15 @@
        <el-form-item label="产品编号" prop="productCode">
          <el-input v-model="form.productCode" type="textarea" placeholder="请输入内容" />
        </el-form-item>
        <el-form-item label="产线编号" prop="productionLine">
          <el-input v-model="form.productionLine" type="textarea" placeholder="请输入内容" />
        </el-form-item>
<!--        <el-form-item label="产线编号" prop="productionLine">-->
<!--          <el-input v-model="form.productionLine" type="textarea" placeholder="请输入内容" />-->
<!--        </el-form-item>-->
        <el-form-item label="工位编号" prop="locationCode">
          <el-input v-model="form.locationCode" type="textarea" placeholder="请输入内容" />
        </el-form-item>
        <el-form-item label="设备编号" prop="equipmentNo">
          <el-input v-model="form.equipmentNo" type="textarea" placeholder="请输入内容" />
        </el-form-item>
<!--        <el-form-item label="设备编号" prop="equipmentNo">-->
<!--          <el-input v-model="form.equipmentNo" type="textarea" placeholder="请输入内容" />-->
<!--        </el-form-item>-->
        <el-form-item label="入站时间" prop="inboundTime">
          <el-date-picker clearable
            v-model="form.inboundTime"
@@ -184,9 +184,9 @@
        <el-form-item label="是否合格" prop="outRsSign">
          <el-input v-model="form.outRsSign" placeholder="请输入出站是否合格" />
        </el-form-item>
        <el-form-item label="NG原因" prop="outMsgSign">
          <el-input v-model="form.outMsgSign" type="textarea" placeholder="请输入内容" />
        </el-form-item>
<!--        <el-form-item label="NG原因" prop="outMsgSign">-->
<!--          <el-input v-model="form.outMsgSign" type="textarea" placeholder="请输入内容" />-->
<!--        </el-form-item>-->
        <el-form-item label="采集时间" prop="collectionTime">
          <el-date-picker clearable
            v-model="form.collectionTime"
@@ -209,6 +209,9 @@
<script>
import { listPassingStationCollection, getPassingStationCollection, delPassingStationCollection, addPassingStationCollection, updatePassingStationCollection } from "@/api/main/da/passingStationCollection/passingStationCollection";
import {
  selectDaPassingStationCollectionForSearch
} from "../../../../api/main/da/passingStationCollection/passingStationCollection";
export default {
  name: "PassingStationCollection",
@@ -262,7 +265,7 @@
    /** æŸ¥è¯¢äº§å“è¿‡ç«™é‡‡é›†åˆ—表 */
    getList() {
      this.loading = true;
      listPassingStationCollection(this.queryParams).then(response => {
      selectDaPassingStationCollectionForSearch(this.queryParams).then(response => {
        this.passingStationCollectionList = response.rows;
        this.total = response.total;
        this.loading = false;
jcdm-ui/src/views/main/da/productNum/index.vue
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,154 @@
<template>
  <div class="app-container">
    <el-card class="box-card">
      <el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="100px">
        <el-form-item label="按月份统计" prop="queryMonth">
          <el-date-picker
            v-model="queryParams.queryMonth"
            type="month"
            @change = changeMonth
            value-format="yyyy-MM"
            placeholder="选择月份">
          </el-date-picker>
        </el-form-item>
        <el-form-item label="按日期统计" prop="queryDate">
          <el-date-picker
            v-model="queryParams.queryDate"
            type="date"
            @change = changeDate
            value-format="yyyy-MM-dd"
            placeholder="选择日期">
          </el-date-picker>
        </el-form-item>
        <el-form-item>
          <el-button type="primary" icon="el-icon-download" style="background-color: #6dbf6d;" @click="exportReport">导出报表</el-button>
        </el-form-item>
      </el-form>
      <el-table v-loading="loading" border :data="productNumList" v-if="productNumList.length > 0">
        <el-table-column label="机型" align="center" prop="model">
        </el-table-column>
        <el-table-column label="产量" align="center" prop="num" width="150">
        </el-table-column>
      </el-table>
      <el-empty v-else>
        <span slot="description">暂无数据</span>
      </el-empty>
    </el-card>
  </div>
</template>
<script>
import {
  getProductNum
} from "../../../../api/main/da/passingStationCollection/passingStationCollection";
export default {
  name: "productNum",
  data() {
    return {
      // é®ç½©å±‚
      loading: true,
      queryParams: {
        queryDate: '',
        queryMonth: '',
        pageNum: 1,
        pageSize: 10,
      },
      // è¡¨å•å‚æ•°
      form: {},
      showSearch: true,
      productNumList: [],
      // æ€»æ¡æ•°
      total: 0,
    };
  },
  created() {
    const date = new Date();
    const year = date.getFullYear();
    let month = date.getMonth() + 1;
    let day = date.getDate();
    month = (month > 9) ? month : ("0" + month);
    day = (day < 10) ? ("0" + day) : day;
    this.queryParams.queryDate = year + "-" + month + "-" + day;
    this.queryParams.queryMonth = year + "-" + month;
    this.getList();
  },
  methods: {
    //导出
    exportReport(){
      this.download('bs/beatSetting/productNumExport', {
        ...this.queryParams
      }, `产量报表_${new Date().getTime()}.xlsx`)
    },
    /** æŸ¥è¯¢äº§å“è¿‡ç«™é‡‡é›†åˆ—表 */
    getList: function () {
      this.loading = true;
      getProductNum(this.queryParams).then(response => {
        console.log('res', response)
        this.productNumList = response.data;
        this.loading = false;
      });
    },
    changeMonth (){
      this.queryParams.queryDate = ''
      this.getList()
    },
    changeDate(){
      console.log('000000')
      if (this.queryParams.queryDate !== null && this.queryParams.queryDate !==''){
        let split = this.queryParams.queryDate.split('-');
        this.queryParams.queryMonth = split[0]+"-"+split[1]
      }
      this.getList()
    },
    // å–消按钮
    cancel() {
      this.open = false;
      this.reset();
    },
    // è¡¨å•é‡ç½®
    reset() {
      this.form = {
        id: null,
        workOrderNo: null,
        sfcCode: null,
        productCode: null,
        productionLine: null,
        locationCode: null,
        equipmentNo: null,
        inboundTime: null,
        outboundTime: null,
        inRsSign: null,
        inMsgSign: null,
        outRsSign: null,
        outMsgSign: null,
        collectionTime: null,
        spareField1: null,
        spareField2: null,
        createUser: null,
        createTime: null,
        updateUser: null,
        updateTime: null,
        beatTime: null
      };
      this.resetForm("form");
    },
    /** æœç´¢æŒ‰é’®æ“ä½œ */
    handleQuery() {
      this.queryParams.pageNum = 1;
      this.getList();
    },
    /** é‡ç½®æŒ‰é’®æ“ä½œ */
    resetQuery() {
      this.resetForm("queryForm");
      this.handleQuery();
    },
  }
};
</script>
<style scoped>
</style>
jcdm-ui/src/views/main/om/productionOrde/index.vue
@@ -59,6 +59,16 @@
    <el-row :gutter="10" class="mb8">
      <el-col :span="1.5">
        <el-button
          type="primary"
          plain
          icon="el-icon-plus"
          size="mini"
          @click="handleAdd"
          v-hasPermi="['om:productionOrde:add']"
        >新增</el-button>
      </el-col>
      <el-col :span="1.5">
        <el-button
          type="success"
          plain
          icon="el-icon-edit"
@@ -179,21 +189,24 @@
        <i class="el-icon-s-order"></i>
        {{titleName}}
      </span>
      <el-form ref="form" inline :model="form" :rules="rules" label-width="80px">
        <el-form-item label="工单号" prop="workOrderNo">
          <el-input v-model="form.workOrderNo" disabled placeholder="请输入生产订单" />
      <el-form ref="form" inline :model="form" :rules="rules" label-width="100px">
        <el-form-item label="生产通知单" prop="productionNotice">
          <el-input v-model="form.productionNotice" :disabled="editFlag" placeholder="请输入生产通知单" />
        </el-form-item>
        <el-form-item label="订单编号" prop="productionNotice">
          <el-input v-model="form.productionNotice" disabled placeholder="请输入订单编号" />
        <el-form-item label="生产订单" prop="workOrderNo">
          <el-input v-model="form.workOrderNo" :disabled="editFlag" placeholder="请输入生产订单" />
        </el-form-item>
        <el-form-item label="产品编号" prop="productCode">
          <el-input v-model="form.productCode" disabled placeholder="请输入产品编号" />
          <el-input v-model="form.productCode" :disabled="editFlag" placeholder="请输入产品编号" />
        </el-form-item>
        <el-form-item label="产品名称" prop="productName">
          <el-input v-model="form.productName" disabled placeholder="请输入产品名称" />
        <el-form-item label="成品描述" prop="productName">
          <el-input v-model="form.productName" :disabled="editFlag" placeholder="请输入成品描述" />
        </el-form-item>
        <el-form-item label="种类" prop="productName">
          <el-input v-model="form.typeZ" disabled placeholder="请输入种类" />
        <el-form-item label="机型" prop="productName">
          <el-input v-model="form.typeZ" :disabled="editFlag" placeholder="请输入机型" />
        </el-form-item>
        <el-form-item label="需求数量" prop="planQty">
          <el-input v-model="form.planQty" :disabled="editFlag" placeholder="请输入需求数量" />
        </el-form-item>
        <el-form-item label="工单状态" prop="orderStatus">
          <el-select style="width: 93%" v-model="form.orderStatus" placeholder="请选择工单状态">
@@ -213,14 +226,14 @@
      </div>
    </el-dialog>
    <el-dialog v-dialogpop-up :title="title" :visible.sync="Createopen" width="500px" append-to-body>
    <el-dialog v-dialogpop-up :title="title" :visible.sync="Createopen" width="600px" append-to-body>
       <span slot="title">
        <i class="el-icon-s-order"></i>
        {{titleName}}
      </span>
      <el-form ref="form" inline  :model="form" :rules="CreateRules" label-width="100px">
      <el-form ref="form" inline  :model="form" :rules="CreateRules" label-width="120px">
        <el-form-item   label="机型" prop="typeZ">
          <el-input disabled v-model="form.typeZ"  placeholder="请输入机型" />
          <el-input disabled v-model="form.typeZ" style="font-size: 18px"  placeholder="请输入机型" />
        </el-form-item>
        <el-form-item  label="日期" prop="dateTime">
          <el-date-picker clearable
@@ -234,10 +247,10 @@
          <el-input v-model="form.dateTimeRule"/>
        </el-form-item>
        <el-form-item   label="起始编号" prop="startCode">
          <el-input type="number"   :maxlength="3"  :pattern="'[0-9]{3}'" v-model="form.startCode"  placeholder="请输入起始编号" @input="handleCodeChangeStart"/>
          <el-input type="number" style="font-size: 18px"  :maxlength="3"  :pattern="'[0-9]{3}'" v-model="form.startCode"  placeholder="请输入起始编号" @input="handleCodeChangeStart"/>
        </el-form-item>
        <el-form-item   label="起止编号" prop="startEndCode">
          <el-input type="textarea" disabled v-model="form.startEndCode"/>
          <el-input type="textarea" style="font-size: 18px;width: 250px" disabled v-model="form.startEndCode"/>
        </el-form-item>
      </el-form>
      <div slot="footer" class="dialog-footer">
@@ -278,6 +291,7 @@
  },
  data() {
    return {
      editFlag: false,
      statuOptions:[
        {
          label:"待下达",
@@ -696,6 +710,7 @@
    handleAdd() {
      this.initWorkshop();
      this.reset();
      this.editFlag = false
      this.open = true;
      this.titleName = "添加生产订单";
    },
@@ -736,6 +751,7 @@
    handleUpdate(row) {
      this.initWorkshop();
      this.reset();
      this.editFlag = true
      const id = row.id || this.ids
      getProductionOrde(id).then(response => {
        console.log(response.data)
jcdm-ui/src/views/main/om/productionOrde/planStatistics.vue
@@ -2,7 +2,7 @@
  <div class="app-container">
    <el-card class="box-card">
    <el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="68px">
      <el-form-item label-width="100" label="生产通知单" prop="productName">
      <el-form-item label-width="100" label="生产通知单" prop="productionNotice">
        <el-input v-model="queryParams.productionNotice" placeholder="请输入生产通知单" clearable @keyup.enter.native="handleQuery"/>
      </el-form-item>
      <el-form-item label-width="80" label="生产订单" prop="workOrderNo">
@@ -47,16 +47,16 @@
        </el-table-column>
        <el-table-column label="需求数量" align="center" prop="planQty">
        </el-table-column>
        <el-table-column label="工作中" align="center">
        </el-table-column>
        <el-table-column label="已完成" width="160" align="center" prop="actualQty">
        </el-table-column>
        <el-table-column label="已报废" width="160" align="center" prop="scrapQty">
        </el-table-column>
        <el-table-column label="完成率" width="160" align="center">
        </el-table-column>
        <el-table-column label="合格率" width="160" align="center">
        </el-table-column>
<!--        <el-table-column label="工作中" align="center">-->
<!--        </el-table-column>-->
<!--        <el-table-column label="已完成" width="160" align="center" prop="actualQty">-->
<!--        </el-table-column>-->
<!--        <el-table-column label="已报废" width="160" align="center" prop="scrapQty">-->
<!--        </el-table-column>-->
<!--        <el-table-column label="完成率" width="160" align="center">-->
<!--        </el-table-column>-->
<!--        <el-table-column label="合格率" width="160" align="center">-->
<!--        </el-table-column>-->
      </el-table>
    </el-card>