From 05beaea41133a9e1bfd544a2a5d5f727bb930468 Mon Sep 17 00:00:00 2001 From: ZengTao <2773468879@qq.com> Date: 星期二, 28 五月 2024 10:18:04 +0800 Subject: [PATCH] Merge branch 'master' of http://10.153.19.25:10101/r/HangZhouMes --- UI-Project/src/views/Identify/identify.vue | 20 ++++++++++++++------ 1 files changed, 14 insertions(+), 6 deletions(-) diff --git a/UI-Project/src/views/Identify/identify.vue b/UI-Project/src/views/Identify/identify.vue index c8c0ce0..2d500f6 100644 --- a/UI-Project/src/views/Identify/identify.vue +++ b/UI-Project/src/views/Identify/identify.vue @@ -21,21 +21,17 @@ <!-- <div class="centered-text" >NG24030401B01</div> --> <div class="centered-text"> <div>{{ rect.process_id }}</div> - <div style="margin-top: 50px;margin-left: -85px;">{{ rect.width }}*{{ rect.height }}</div> + <div style="margin-top: 50px;margin-left: -85px;">{{ rect.widtha }}*{{ rect.heighta }}</div> </div> </div> <!-- 鐐瑰嚮寮瑰嚭 --> <el-dialog v-model="blind" top="30vh" width="15%" style="text-align: center;"> - <!-- <template #footer> --> - <!-- <div id="dialog-footer"> --> <el-button type="warning" plain :icon="Delete" @click="handleDamage(currentGlassId)" style="width: 120px;margin-left: 10px;"> 鐮存崯 </el-button> <el-button type="danger" plain @click="handleManualTake(currentGlassId)" style="width: 120px;margin-top: 10px;"> <el-icon class="el-icon--right"><Upload /></el-icon> 浜哄伐鎷胯蛋</el-button> - <!-- </div> --> - <!-- </template> --> </el-dialog> </div> </div> @@ -82,6 +78,8 @@ x_axis: (rect.x_axis*100) * 0.005, // 灏唜鍊奸櫎浠�3 y_axis: (rect.y_axis*100) * 0.005, width: (rect.width*100) * 0.004 , + widtha: rect.width , + heighta: rect.height , height:( rect.height*100) * 0.004 , glass_state: rect.glass_state })); @@ -113,6 +111,7 @@ ElMessage.success(response.message); // window.location.reload() blind.value = false; + updateRectStatus(currentGlassId.value, 201); } else { // 璇锋眰澶辫触锛屾樉绀洪敊璇秷鎭� ElMessage.error(response.msg); @@ -138,6 +137,7 @@ ElMessage.success(response.message); // window.location.reload() blind.value = false; + updateRectStatus(currentGlassId.value, 200); } else { // 璇锋眰澶辫触锛屾樉绀洪敊璇秷鎭� ElMessage.error(response.msg); @@ -165,7 +165,15 @@ default: return '#911005'; // 榛樿棰滆壊 } -} +} +// 鏇存柊鐭╁舰鐘舵�� +function updateRectStatus(glassId: string, status: number) { + adjustedRects.value.forEach(rect => { + if (rect.glass_id === glassId) { + rect.glass_state = status; // 鏇存柊鐭╁舰鐨勭姸鎬� + } + }); +} </script> <style scoped> -- Gitblit v1.8.0