wu
2024-01-05 b709b0fd40283dd285eff470257b1b8dc0a42ad3
增加禁用格子玻璃出片时的提示
2个文件已修改
17 ■■■■ 已修改文件
springboot-vue3/src/main/java/com/example/springboot/component/PlcHold.java 14 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
springboot-vue3/src/main/java/com/example/springboot/mapper/SpianMapper.java 3 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
springboot-vue3/src/main/java/com/example/springboot/component/PlcHold.java
@@ -17,6 +17,7 @@
  private SpianMapper spianMapper;
  private SpianService spianService;
  int aaa;
  @Override
  public void run() {
  
@@ -63,10 +64,19 @@
        if (outnum == 0 && outstate == true && Plchome.isAllowQueue == true&&cageoutsum==0) {
          // 判断铝框出片队列表是否有待出片的玻璃
          String outglassid = spianMapper.SelectOutSlice();
            // 当有待出片的玻璃时
          if (outglassid != null) {
              // 获取该玻璃是否被禁用
              int glassdisabled = spianMapper.SelectCageGlassState(outglassid);
              //未禁用下发任务
              if (glassdisabled == 0) {
            spianService.selectout2(outglassid);
                Plchome.isQueueWarning = false;
            outstate = false;
              } else { //禁用更改状态弹出提示
                Plchome.isQueueWarning = true;
              }
          }
        }
        if (outstate == true) {// 当出片车空闲时,且出片启动为1时,任务启动改为0
@@ -142,8 +152,6 @@
        }
      }
      // if (outstate == true) { // 出片车状态空闲时
      // Integer state = spianMapper.Selectoutstate();
springboot-vue3/src/main/java/com/example/springboot/mapper/SpianMapper.java
@@ -225,4 +225,7 @@
    //获取该半区是否有执行的任务
    @Select(" select count(*) from storage_cage where state=#{state} and cage>#{cage1} and cage<#{cage2}")
    int SelectCageTask(int state,int cage1,int cage2);
    //判断玻璃是否禁用
    @Select(" select disabled from storage_cage where glass_id=#{glassid} limit 1;")
    int SelectCageGlassState(String glassid);
}