hangzhoumesParent/moduleService/CacheVerticalGlassModule/src/main/java/com/mes/job/OpcPlcStorageCageNewTask.java
@@ -6,6 +6,7 @@
import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper;
import com.baomidou.mybatisplus.core.toolkit.CollectionUtils;
import com.github.xingshuangs.iot.protocol.s7.serializer.S7Serializer;
import com.github.xingshuangs.iot.protocol.s7.service.S7PLC;
import com.github.yulichang.toolkit.JoinWrappers;
import com.kangaroohy.milo.model.ReadWriteEntity;
import com.kangaroohy.milo.service.MiloService;
@@ -87,6 +88,9 @@
    @Autowired
    @Qualifier("s7SerializerDLPTwo")
    private S7Serializer s7SerializerDLPTwo;
    @Autowired
    @Qualifier("s7plcWZL")
    private S7PLC s7plcWZL;
    @Resource
    SysConfigService sysConfigService;
@@ -465,6 +469,16 @@
        Integer temperingOutTargetPosition = sysConfigService.queryConfigValue(ConstSysConfig.VERTICAL_TEMPERING_OUT_TARGET_POSITION);
        if (redisUtil.getCacheObject("temperingSwitch")) {
            try {
                int outRequest = s7plcWZL.readUInt16("DB51.8");
                if (outRequest == 0) {
                    log.info("当前未收到卧转立允许出片请求,结束出片任务");
                    return;
                }
            } catch (Exception e) {
                log.error("读取卧转立信号异常", e);
                return;
            }
            //是否允许钢化
            //是否有正在钢化的玻璃:钢化小片表关联历史任务表,筛选未出笼的玻璃信息
//            获取当前钢化任务未完成出片的玻璃信息
@@ -514,7 +528,7 @@
                List<TemperingLayoutDTO> temperingLayoutDTOS = bigStorageCageDetailsService.temperingIsAllByTemperingLayoutId(temperingEngineerId, temperingLayoutId);
                if (CollectionUtil.isNotEmpty(temperingLayoutDTOS)) {
                    List<TemperingGlassInfo> temperingGlassInfos = glassInfoService.selectJoinList(TemperingGlassInfo.class, JoinWrappers.lambda(GlassInfo.class)
                            .select("-1 as state,t.filmsid as films_id,t.glass_id,t.flow_card_id,t.glass_type,t.width,t.height" +
                            .select("-1 as state,t.filmsid as films_id,t.glass_id,t.flow_card_id,t.layer,t.glass_type,t.width,t.height" +
                                    ",t.thickness,t.ishorizontal,t.tempering_layout_id,t.tempering_feed_sequence,t.x_coordinate,t.y_coordinate," +
                                    "t.angle,t1.slot,t.engineer_id")
                            .innerJoin(BigStorageCageDetails.class, BigStorageCageDetails::getGlassId, GlassInfo::getGlassId)
@@ -912,7 +926,7 @@
            damage.setWorkingProcedure("大理片笼");
            damage.setRemark("进笼前卧转立");
            damage.setStatus(1);
            damage.setType(item.getTaskState());
            damage.setType(Const.GLASS_STATE_DAMAGE);
            damageService.insertDamage(damage);
            slotList.add(item.getTargetSlot());
        }
@@ -937,7 +951,7 @@
            damage.setWorkingProcedure("钢化前");
            damage.setRemark("进笼后卧转立");
            damage.setStatus(1);
            damage.setType(item.getTaskState());
            damage.setType(Const.GLASS_STATE_DAMAGE);
            damageService.insertDamage(damage);
            slotList.add(item.getTargetSlot());
            slotList.add(item.getStartSlot());
@@ -1011,7 +1025,7 @@
//        if (!THROUGH_SLOT.equals(list.get(0).getSlot())) {
//            临时解决方案:出片时考虑玻璃碰撞,改为一片一出
        // 界面关闭调度开关 !Const.BIG_STORAGE_BEFORE_DISPATCH.equals(taskType)
        if (list.get(0).getSlot() >= 500 && list.get(0).getThickness() > 7) {
        if (list.get(0).getSlot() >= 500 && list.get(0).getThickness() > 8) {
            outGlassList = list.subList(0, 1);
        } else {
            List<String> glassIdList = bigStorageGlassRelationInfoService.queryNeedOutGlassId(