chenlu
2024-12-26 0b2fa1993f65d08e2046ff1d86ede98627e7b2dc
north-glass-erp/src/main/java/com/example/erp/service/pp/ReportingWorkService.java
@@ -81,6 +81,8 @@
    public Map<String, Object> AddSelectLastWorkSv(String processIdStr, String technologyStr, String process, String reportType) {
        Map<String, Object> map = new HashMap<>();
        //获取报工工序是否为复合工程
        String laminating = reportingWorkMapper.getProcessLaminating(process);
        //查询流程卡工艺流程
        String technologicalProcess = reportingWorkMapper.SelectTechnologicalProcess(processIdStr,technologyStr);
@@ -142,9 +144,10 @@
                if (retrievedData!=null){
                    Integer reviewedState = retrievedData.getReviewedState();
                    //根据审核状态查询未审核数据
                    System.out.println(laminating);
                    if (reviewedState==1){//已审核
                        //不是第一道工序,查询报工数据
                        List<Map<String,String>>  details = reportingWorkMapper.SelectReworlDetailMp(processIdStr, technologyStr, process,previousProcess);
                        List<Map<String,String>>  details = reportingWorkMapper.SelectReworlDetailMp(processIdStr, technologyStr, process,previousProcess,laminating);
                        if(process.equals("中空")){
                            String orderId = processIdStr.substring(0,10);
                            details.forEach( detail -> {
@@ -161,7 +164,7 @@
                        map.put("Detail",details );
                    }else {
                        //不是第一道工序,查询报工数据
                        List<Map<String,String>>  details = reportingWorkMapper.SelectReworlDetailMpReview(processIdStr, technologyStr, process,previousProcess);
                        List<Map<String,String>>  details = reportingWorkMapper.SelectReworlDetailMpReview(processIdStr, technologyStr, process,previousProcess,laminating);
                        if(process.equals("中空")){
                            String orderId = processIdStr.substring(0,10);
                            details.forEach( detail -> {
@@ -311,7 +314,6 @@
            //判断是否大于当前数量并且抛出异常
            if (processNum < (reportingWorkDetail.getBreakageQuantity() + reportingWorkDetail.getCompletedQuantity())) {
                System.out.println(processNum+"--"+reportingWorkDetail.getBreakageQuantity()+"--"+reportingWorkDetail.getCompletedQuantity());
                Map<String, Object> map = new HashMap<>();
                map.put("orderNumber", reportingWorkDetail.getOrderNumber());
                map.put("technologyNumber", reportingWorkDetail.getOrderNumber());