Quellcode durchsuchen

截图代码修改

wyyay vor 10 Monaten
Ursprung
Commit
521f442fa3

+ 4 - 0
hazard-admin/src/main/java/com/ozs/web/controller/shotschedule/ShotPictureExecutors.java

@@ -56,8 +56,10 @@ public class ShotPictureExecutors {
                 List<SysDictData> dataList = iSysDictTypeService.selectDictDataByType("shot_switch");
                 if(CollectionUtils.isEmpty(dataList)){
                     redisCache.setCacheObject("shot_switch",2);
+                    status = redisCache.getCacheObject("shot_switch");
                 }else{
                     redisCache.setCacheObject("shot_switch",dataList.get(0).getStatus());
+                    status = redisCache.getCacheObject("shot_switch");
                 }
             }
             if(status == 1){
@@ -80,8 +82,10 @@ public class ShotPictureExecutors {
                 List<SysDictData> dataList = iSysDictTypeService.selectDictDataByType("shot_switch");
                 if(CollectionUtils.isEmpty(dataList)){
                     redisCache.setCacheObject("shot_switch",2);
+                    status = redisCache.getCacheObject("shot_switch");
                 }else{
                     redisCache.setCacheObject("shot_switch",dataList.get(0).getStatus());
+                    status = redisCache.getCacheObject("shot_switch");
                 }
             }
             if(status == 1){