zhuo
2025-03-16 32bdae73e49c51b6835ef0a5c7b82c4a83a521df
inspect-server/src/main/java/com/ruoyi/inspect/service/impl/InsOrderPlanServiceImpl.java
@@ -30,6 +30,7 @@
import com.ruoyi.basic.service.StandardTemplateService;
import com.ruoyi.common.constant.DictDataConstants;
import com.ruoyi.common.constant.InsOrderTypeConstants;
import com.ruoyi.common.constant.MenuJumpPathConstants;
import com.ruoyi.common.core.domain.entity.Custom;
import com.ruoyi.common.core.domain.entity.InformationNotification;
import com.ruoyi.common.core.domain.entity.User;
@@ -55,6 +56,7 @@
import org.apache.commons.lang3.StringUtils;
import org.apache.poi.xwpf.usermodel.*;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.core.io.ClassPathResource;
import org.springframework.mock.web.MockMultipartFile;
import org.springframework.scheduling.concurrent.ThreadPoolTaskExecutor;
import org.springframework.stereotype.Service;
@@ -97,14 +99,9 @@
    private InsOrderStateMapper insOrderStateMapper;
    @Resource
    private InsProductMapper insProductMapper;
    @Resource
    private ShiftTimeMapper shiftTimeMapper;
    @Resource
    private PerformanceShiftMapper performanceShiftMapper;
    @Value("${wordUrl}")
    private String wordUrl;
    @Value("${twoCode}")
    private String twoCode;
    @Resource
    private InsReportMapper insReportMapper;
    @Resource
@@ -141,8 +138,7 @@
    private InsOrderFactoryVerifyMapper insOrderFactoryVerifyMapper;
    @Resource
    private InsOrderFactoryVerifyItemService insOrderFactoryVerifyItemService;
    @Value("${file.licenseUrl}")
    private String licenseUrl;
    @Resource
    private SpotCheckQuarterItemMapper spotCheckQuarterItemMapper;
    @Resource
@@ -780,11 +776,13 @@
            int count = 0;
            for (InsProduct product : insProducts) {
                count++;
                str += "<br/>" + count + ":" + product.getInspectionItem() + " " + product.getInspectionItemSubclass() + "<br/>";
                str +=  (count != 0 ? "\n" : "") + count + ":" +
                        product.getInspectionItemClass() + " " +
                        product.getInspectionItem() + " " +
                        product.getInspectionItemSubclass();
            }
            if (ObjectUtils.isNotEmpty(str)) {
                throw new ErrorException("<strong>存在待检验的项目:</strong><br/>" + str);
                throw new ErrorException("存在待检验的项目:" + str);
            }
        }
@@ -810,7 +808,7 @@
        info.setSenderId(userId);
        info.setConsigneeId(verifyUser);
        info.setViewStatus(false);
        info.setJumpPath("b1-inspect-orderPlan-review");
        info.setJumpPath(MenuJumpPathConstants.INSPECTION_REVIEW);
        informationNotificationService.addInformationNotification(info);
        // 6.复核人--新增检验单相关负责人
@@ -4227,7 +4225,7 @@
        FileOutputStream os = null;
        try {
            //凭证 不然切换后有水印
            InputStream is = Files.newInputStream(new File(licenseUrl).toPath());
            InputStream is = new ClassPathResource("/lib/license.xml").getInputStream();
            License license = new License();
            license.setLicense(is);
            if (!license.getIsLicensed()) {