wu
2024-11-14 5780c58879296cfced72012c8831c1d3cf4dafb2
springboot-vue3/src/main/java/com/example/springboot/service/StorageCageService.java
@@ -276,6 +276,15 @@
        }
        return storageTasks;
    }
    //查询出片队列
    public List<Map> SelectOutTask() {
        return homeMapper.SelectOutTask();
    }
     //查询出片队列
     public List<Map> SelectOutLog() {
        return homeMapper.SelectOutLog();
    }
    // 查询进/出片任务
    public List<GlassInfo> SelectMeasure() {
@@ -441,6 +450,7 @@
        // 删除数据
        Map<String, Object> map = new HashMap<>();
        // QueueMapper.DeleteQueue();
        System.out.println("人工匹配ID:"+glassInfo.getMateid()+"膜系:"+glassInfo.getFilms());
        int count = homeMapper.SelectQueue();
        if (count > 0) {
            homeMapper.UpdateQueue(glassInfo.getFlowcard(), glassInfo.getWidth(), glassInfo.getHeight(),
@@ -478,6 +488,20 @@
        homeMapper.StartChange(flowcard, orderstate);
        Map<String, Object> map = new HashMap<>();
        int state = homeMapper.selectStartChange(flowcard);
        map.put("message", "200");
        return Result.success(map);
    }
    // 开始/暂停出片队列
    public Result UpdateOutTask(Integer id, Integer state) {
        homeMapper.UpdateOutTask(id, state);
        Map<String, Object> map = new HashMap<>();
        map.put("message", "200");
        return Result.success(map);
    }
    //删除出片队列
    public Result DeleteOutTask(Integer id) {
        homeMapper.DeleteOutTask(id);
        Map<String, Object> map = new HashMap<>();
        map.put("message", "200");
        return Result.success(map);
    }
@@ -529,7 +553,7 @@
                        &&
                        item.get("films") != null && item.get("base") != null && item.get("height") != null
                        && item.get("thickness") != null && item.get("quantity") != null
                        && item.get("matching") != null))
                        && item.get("matching") != null)&& item.get("Customer") != null)
                .collect(Collectors.toList());
        TypeDatas.forEach(item -> {
@@ -585,16 +609,15 @@
                glasstype = Integer.valueOf(value);
            }
            //
            homeMapper.AddGlassinfo(map.get("order").toString(), glasstype,
                    Integer.parseInt(map.get("matching").toString()) // 需要计算 配片ID
                    , map.get("order").toString() + "-" + count + "" // 需要计算 玻璃ID
                    , Integer.parseInt(map.get("tier").toString()), map.get("films").toString(),
                    Double.parseDouble(map.get("base").toString()), Double.parseDouble(map.get("height").toString()),
                    Double.parseDouble(map.get("thickness").toString()),
                    Integer.parseInt(map.get("quantity").toString()), groupby.get(tierkey));// 需要计算总层数
                    Integer.parseInt(map.get("quantity").toString()), groupby.get(tierkey),map.get("Customer").toString());// 需要计算总层数
            // 订单内总层数
            homeMapper.InsertFlowcard(map.get("order").toString(), OrderFinishedProduct.get(tierkey + "_Sum"));
            homeMapper.InsertFlowcard(map.get("order").toString(), OrderFinishedProduct.get(tierkey + "_Sum"), map.get("Customer").toString());
            count++;
        }
        Map<String, Object> ResultCode = new HashMap<>();