buhuazhen
2026-04-27 f25369ff160772b7e866462cb10dda799d27e9fb
src/main/java/com/ruoyi/production/service/impl/ProductionProductMainServiceImpl.java
@@ -160,10 +160,15 @@
        productionProductMain.setAuditUserId(dto.getAuditUserId());
        productionProductMain.setAuditUserName(dto.getAuditUserName());
        productionProductMain.setStatus(0);
        productionProductMain.setStartTime(productWorkOrder.getStartProductTime());
        productionProductMain.setEndTime(now);
        productionProductMain.setDeviceId(productProcess.getDeviceId());
        productionProductMain.setDeviceName(productProcess.getDeviceName());
        if (ObjectUtils.isNotEmpty(dto.getStartTime())&&ObjectUtils.isNotEmpty(dto.getEndTime())) {
            productionProductMain.setStartTime(dto.getStartTime());
            productionProductMain.setEndTime(dto.getEndTime());
        }else {
            productionProductMain.setStartTime(productWorkOrder.getStartProductTime());
            productionProductMain.setEndTime(now);
        }
        productionProductMain.setDeviceId(dto.getDeviceId());
        productionProductMain.setDeviceName(dto.getDeviceName());
        productionProductMainMapper.insert(productionProductMain);
        /*新增报工投入表*/
        List<ProductStructureDto> productStructureDtos = productStructureMapper.listBybomAndProcess(productProcessRoute.getBomId(), productProcess.getId());