#
whycq
2024-01-18 78b52c20a27a02466c8af9c0c8222b9f2f3ff20c
src/main/java/com/zy/asrs/controller/MonitorController.java
@@ -7,6 +7,7 @@
import com.zy.asrs.domain.dto.WorkChartAxis;
import com.zy.asrs.domain.vo.LocChartPie;
import com.zy.asrs.mapper.ReportQueryMapper;
import com.zy.common.model.MatDto;
import com.zy.common.service.CommonService;
import com.zy.core.CrnThread;
import com.zy.core.cache.SlaveConnection;
@@ -75,50 +76,6 @@
        List<Map<String, Object>> pakoutRep = reportQueryMapper.queryPakinRep();
        return R.ok(pakinRep);
    }
    /**
     * 自动补零
@@ -205,6 +162,7 @@
                }
            }
        }
        return R.ok().add(errorMsg);
    }
@@ -318,6 +276,24 @@
                }
            }
        }
//        MatDto matDto = new MatDto();
//        matDto.setMatNo("1111");
//        matDto.setCount(100.0);
//        matDto.setMaknx("测试用料");
//        LedCommand ledCommand = new LedCommand();
//        ledCommand.setStaNo(8);
//        ledCommand.setTitle("入库启动");
//        ledCommand.setLocNo("0100101");
//        ledCommand.setWorkNo(9998);
//        ledCommand.setEmptyMk(false);
//        ledCommand.setIoType(1);
//        ledCommand.setSourceStaNo(15);
//        ArrayList<MatDto> matDtos = new ArrayList<>();
//        matDtos.add(matDto);
//        ledCommand.setMatDtos(matDtos);
//        ArrayList<LedCommand> ledCommands = new ArrayList<>();
//        ledCommands.add(ledCommand);
//        return R.ok(ledCommands);
        return R.ok().add(commandList);
    }
    /**
@@ -364,9 +340,7 @@
            }
        }
        // 获取输送线plc线程
        LedThread ledThread = (LedThread) SlaveConnection.get(SlaveType.Led, ledId);
        String ledContent = ledThread.getStringBuffer().toString();
//        ledContent = "ask的模块萨满大算了萨满大了\n 是窘境到埃及嗲家嗲\n 萨达姆打开萨满大凯撒麦当劳萨满大老师";
        return R.ok(
@@ -378,8 +352,6 @@
                        .add("yDistance", Arith.multiplys(1, Math.abs(yDistance), 1))   // 累计升降距离km
                        .add("xDuration", Arith.multiplys(1, Math.abs(xDuration), 1))    // 累计走行时长h
                        .add("yDuration", Arith.multiplys(1, Math.abs(yDuration), 1))    // 累计升降时长h
                        .add("isShow", !Cools.isEmpty(ledContent)) // 是否显示内容
                        .add("content", ledContent) // 显示内容
        );
    }