| | |
| | | const blind = ref(false) |
| | | const width = ref(); |
| | | const height = ref(); |
| | | const adjustedRects = ref([]); |
| | | const adjustedRects1 = ref([]); |
| | | const adjustedRects2 = ref([]); |
| | | const adjustedRectsa = ref([]); |
| | | const adjustedRectsb = ref([]); |
| | |
| | | const handleMessage = (data) => { |
| | | // 进炉中 |
| | | if(data.intoGlass!=null){ |
| | | adjustedRects.value = data.intoGlass[0].map(rect => { |
| | | adjustedRects1.value = data.intoGlass[0].map(rect => { |
| | | console.log( adjustedRects1.value); |
| | | let adjustedWidth, adjustedHeight, adjustedWidtha, adjustedHeighta; |
| | | let newX = rect.yCoordinate; |
| | | if (rect.angle === 0) { |
| | |
| | | heighta: adjustedHeighta, |
| | | }; |
| | | }); |
| | | }else{ |
| | | adjustedRects1.value = '' |
| | | } |
| | | if(data.intoGlass2!=null){ |
| | | adjustedRects2.value = data.intoGlass2[0].map(rect => { |
| | | let adjustedWidth, adjustedHeight, adjustedWidtha, adjustedHeighta; |
| | | console.log( adjustedRects2.value); |
| | | let adjustedWidth, adjustedHeight, adjustedWidtha, adjustedHeighta; |
| | | let newX = rect.yCoordinate; |
| | | if (rect.angle === 0) { |
| | | adjustedWidth = rect.height * 0.12; |
| | |
| | | heighta: adjustedHeighta, |
| | | }; |
| | | }); |
| | | }else{ |
| | | adjustedRects2.value = '' |
| | | } |
| | | // 进炉前 |
| | | if(data.waitingGlass!=null){ |
| | |
| | | heighta: adjustedHeighta, |
| | | }; |
| | | }); |
| | | } |
| | | }else{ |
| | | adjustedRectsa.value = '' |
| | | } |
| | | // 已出炉 |
| | | if(data.outGlass!=null){ |
| | | adjustedRectsb.value = data.outGlass[0].map(rect => { |
| | |
| | | heighta: adjustedHeighta, |
| | | }; |
| | | }); |
| | | } |
| | | }else{ |
| | | adjustedRectsb.value = '' |
| | | } |
| | | }; |
| | | onMounted(() => { |
| | | initializeWebSocket(socketUrl, handleMessage); |
| | |
| | | return '#911005'; |
| | | } |
| | | } |
| | | // if (adjustedRectsb[0].engineerId != null) { |
| | | // engineerIdDisplayb = adjustedRectsb[0].engineerId |
| | | // } |
| | | // if (adjustedRectsa[0].engineerId != null) { |
| | | // engineerIdDisplaya = adjustedRectsa[0].engineerId |
| | | // } |
| | | // if (adjustedRects2[0].engineerId != null) { |
| | | // engineerIdDisplay2 = adjustedRects2[0].engineerId |
| | | // } |
| | | // if (adjustedRects[0].engineerId != null) { |
| | | // engineerIdDisplay = adjustedRects[0].engineerId |
| | | // } |
| | | function showDialog(rect) { |
| | | currentGlassId.value = rect.glassId; |
| | | currenttemperingFeedSequence.value = rect.temperingFeedSequence; |
| | |
| | | <div v-if="dialogFormVisible" > |
| | | <el-card style="flex: 1;margin-left: 10px;margin-top: 10px;margin-right: 10px;height: 600px;" v-loading="loading"> |
| | | <div style="width: 49%;float: left;background-color: #f4f4f5;height: 550px;"> |
| | | <div v-if="adjustedRects.length > 0"> |
| | | <div style="text-align: center;">炉号:{{ adjustedRects[0].engineerId }}-{{ adjustedRects[0].temperingLayoutId }}</div> |
| | | <div v-if="adjustedRects1.length > 0"> |
| | | <!-- <div style="text-align: center;">炉号:{{ engineerIdDisplay }}-{{ adjustedRects[0].temperingLayoutId }}</div> --> |
| | | <div style="text-align: center;"> 炉号:{{ adjustedRects1[0].engineerId }}-{{ adjustedRects1[0].temperingLayoutId }} </div> |
| | | <el-scrollbar height="550px" style="background-color: #e9e9eb;"> |
| | | <div style="position: relative;max-width: 1400px;"> |
| | | <div |
| | | v-for="(rect, index) in adjustedRects" |
| | | v-for="(rect, index) in adjustedRects1" |
| | | :key="index" |
| | | @click="showDialog(rect)" |
| | | class="rect" |
| | |
| | | </div> |
| | | <div style="width: 49%;float: right;background-color: #f4f4f5;height: 550px;"> |
| | | <div v-if="adjustedRects2.length > 0"> |
| | | <div style="text-align: center;">炉号:{{ adjustedRects[0].engineerId }}-{{ adjustedRects[0].temperingLayoutId }}</div> |
| | | <div style="text-align: center;"> 炉号:{{ adjustedRects2[0].engineerId }}-{{ adjustedRects2[0].temperingLayoutId }} </div> |
| | | <!-- <div style="text-align: center;">炉号:{{ engineerIdDisplay2 }}-{{ adjustedRects[0].temperingLayoutId }}</div> --> |
| | | <el-scrollbar height="550px" style="background-color: #e9e9eb;"> |
| | | <div style="position: relative;max-width: 1400px;"> |
| | | <div |
| | | v-for="(rect, index) in adjustedRects2" |
| | | :key="index" |
| | | :key="index" |
| | | @click="showDialog(rect)" |
| | | class="rect" |
| | | :style="{ position: 'absolute', |
| | |
| | | <!-- 进炉前 --> |
| | | <el-card style="flex: 1;margin-left: 10px;margin-top: 10px;margin-right: 10px;height: 600px;" v-loading="loading"> |
| | | <div v-if="adjustedRectsa.length > 0"> |
| | | <div style="text-align: center;">炉号:{{ adjustedRects[0].engineerId }}-{{ adjustedRects[0].temperingLayoutId }}</div> |
| | | <div style="text-align: center;"> 炉号:{{ adjustedRectsa[0].engineerId }}-{{ adjustedRectsa[0].temperingLayoutId }} </div> |
| | | <!-- <div style="text-align: center;">炉号:{{ engineerIdDisplaya }}-{{ adjustedRects[0].temperingLayoutId }}</div> --> |
| | | <el-scrollbar height="550px" style="background-color: #e9e9eb;"> |
| | | <div style="position: relative;max-width: 1400px;"> |
| | | <div |
| | |
| | | <!-- 已出炉 --> |
| | | <el-card style="flex: 1;margin-left: 10px;margin-top: 10px;margin-right: 10px;height: 600px;" v-loading="loading"> |
| | | <div v-if="adjustedRectsb.length > 0"> |
| | | <div style="text-align: center;">炉号:{{ adjustedRects[0].engineerId }}-{{ adjustedRects[0].temperingLayoutId }}</div> |
| | | <div style="text-align: center;"> 炉号:{{ adjustedRectsb[0].engineerId }}-{{ adjustedRectsb[0].temperingLayoutId }} </div> |
| | | <!-- <div style="text-align: center;">炉号:{{ engineerIdDisplayb }}-{{ adjustedRects[0].temperingLayoutId }}</div> --> |
| | | <el-scrollbar height="550px" style="background-color: #e9e9eb;"> |
| | | <div style="position: relative;max-width: 1400px;"> |
| | | <div |