ZengTao
2024-07-29 e9f54f71f3b0c6afb3f5e88972afbb2c5858fbf3
添加获取当前钢化开关状态
2个文件已修改
14 ■■■■ 已修改文件
hangzhoumesParent/moduleService/CacheVerticalGlassModule/src/main/java/com/mes/job/PlcSlicecage.java 10 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
hangzhoumesParent/moduleService/CacheVerticalGlassModule/src/main/resources/application.yml 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
hangzhoumesParent/moduleService/CacheVerticalGlassModule/src/main/java/com/mes/job/PlcSlicecage.java
@@ -5,6 +5,7 @@
import com.mes.bigstorage.service.BigStorageCageDetailsService;
import com.mes.bigstorage.service.BigStorageCageService;
import com.mes.common.S7object;
import com.mes.common.utils.RedisUtil;
import com.mes.device.PlcParameterObject;
import com.mes.temperingglass.entity.TemperingGlassInfo;
import com.mes.temperingglass.service.TemperingGlassInfoService;
@@ -31,6 +32,8 @@
    private BigStorageCageDetailsService bigStorageCageDetailsService;
    @Resource
    private TemperingGlassInfoService temperingGlassInfoService;
    @Resource
    private RedisUtil redisUtil;
    private JSONObject jsonObject = new JSONObject();
    public void queryDataSource1() throws InterruptedException {
@@ -56,6 +59,13 @@
        //理片笼表格信息
        jsonObject.append("bigStorageCageInfo", bigStorageCageService.querybigStorageCageDetailAll());
        //钢化开关
        boolean temperingSwitch=false;
        if(redisUtil.getCacheObject("temperingSwitch")==null){
            temperingSwitch=redisUtil.getCacheObject("temperingSwitch");
        }
        jsonObject.append("temperingSwitch", temperingSwitch);
    }
    public void queryDataSource2() throws InterruptedException {
hangzhoumesParent/moduleService/CacheVerticalGlassModule/src/main/resources/application.yml
@@ -8,8 +8,8 @@
    name: cacheVerticalGlass
mybatis-plus:
  mapper-locations: classpath*:mapper/*.xml
#  configuration:
#    log-impl: org.apache.ibatis.logging.stdout.StdOutImpl
  configuration:
    log-impl: org.apache.ibatis.logging.stdout.StdOutImpl
mes:
  sequence:
    order: false