From 3048ae014effa8f8ba92395eeb1e69f18e76ebf0 Mon Sep 17 00:00:00 2001
From: wangfei <3597712270@qq.com>
Date: 星期二, 27 八月 2024 14:10:07 +0800
Subject: [PATCH] 大理片笼更改样式,时间选择器中文,钢化模块、掰片模块更新算法

---
 UI-Project/src/views/PurchaseReturn/purchaseReturn.vue |   45 ++++++++++++++++++++++++---------------------
 1 files changed, 24 insertions(+), 21 deletions(-)

diff --git a/UI-Project/src/views/PurchaseReturn/purchaseReturn.vue b/UI-Project/src/views/PurchaseReturn/purchaseReturn.vue
index d329c50..55be7f0 100644
--- a/UI-Project/src/views/PurchaseReturn/purchaseReturn.vue
+++ b/UI-Project/src/views/PurchaseReturn/purchaseReturn.vue
@@ -93,6 +93,7 @@
     // 璁$畻鏂扮殑鐭╁舰  
     const newRects = data.intoGlass2[0].map(rect => {  
       const scaleFactor =  794.67/5087; 
+      const scaleFactorY =  430/2800; 
         let adjustedWidth, adjustedHeight, adjustedWidtha, adjustedHeighta,widtha,heighta;;
         let newX = rect.yCoordinate; 
       if (rect.width < rect.height) {
@@ -104,13 +105,13 @@
       }
       if (rect.angle === 0) {  
     adjustedWidth = widtha * scaleFactor;
-    adjustedHeight = heighta * 0.1;
+    adjustedHeight = heighta * scaleFactorY;
     // adjustedWidtha = widtha;  
     // adjustedHeighta = heighta;   
     newX = 5087 - (rect.yCoordinate + widtha); 
     } else {  
     adjustedWidth = heighta * scaleFactor;  
-    adjustedHeight = widtha * 0.1;  
+    adjustedHeight = widtha * scaleFactorY;  
     // adjustedWidtha = widtha;  
     // adjustedHeighta = heighta;  
     newX = 5087 - (rect.yCoordinate + heighta); 
@@ -118,7 +119,7 @@
         return {  
         ...rect, 
         xcoordinate: newX * scaleFactor,
-        ycoordinate: rect.xCoordinate * 0.1,
+        ycoordinate: rect.xCoordinate * scaleFactorY,
         width: adjustedWidth,  
         height: adjustedHeight,  
         widtha: rect.width, 
@@ -145,6 +146,7 @@
     // 璁$畻鏂扮殑鐭╁舰  
     const newRects = data.intoGlass[0].map(rect => {  
       const scaleFactor =  794.67/5087; 
+      const scaleFactorY =  430/2800; 
       let adjustedWidth, adjustedHeight, adjustedWidtha, adjustedHeighta,widtha,heighta;;
       let newX = rect.yCoordinate; 
       if (rect.width < rect.height) {
@@ -156,13 +158,13 @@
       }
       if (rect.angle === 0) {  
     adjustedWidth = widtha * scaleFactor;
-    adjustedHeight = heighta * 0.1;
+    adjustedHeight = heighta * scaleFactorY;
     // adjustedWidtha = widtha;  
     // adjustedHeighta = heighta;  
     newX = 5087 - (rect.yCoordinate + widtha); 
     } else {  
     adjustedWidth = heighta * scaleFactor;  
-    adjustedHeight = widtha * 0.1;  
+    adjustedHeight = widtha * scaleFactorY;  
     // adjustedWidtha = widtha;  
     // adjustedHeighta = heighta;  
     newX = 5087 - (rect.yCoordinate + heighta);  
@@ -170,7 +172,7 @@
         return {  
         ...rect, 
         xcoordinate: newX * scaleFactor,
-        ycoordinate: rect.xCoordinate * 0.1,
+        ycoordinate: rect.xCoordinate * scaleFactorY,
         width: adjustedWidth,  
         height: adjustedHeight,  
         widtha: rect.width, 
@@ -196,8 +198,9 @@
     const existingRects = adjustedRectsa.value.filter(rect => newGlassIds.has(rect.glassId));  
     // 璁$畻鏂扮殑鐭╁舰  
     const newRects = data.waitingGlass[0].map(rect => {  
-      const scaleFactor =  1621.78/5190; 
-  let adjustedWidth, adjustedHeight, adjustedWidtha, adjustedHeighta,widtha,heighta;; 
+      const scaleFactor =  1390/5190; 
+      const scaleFactorY =  750/2800; 
+      let adjustedWidth, adjustedHeight, adjustedWidtha, adjustedHeighta,widtha,heighta;; 
   let newX = rect.yCoordinate; 
       if (rect.width < rect.height) {
         widtha = rect.height;
@@ -208,13 +211,13 @@
       }
   if (rect.angle === 0) {  
     adjustedWidth = widtha * scaleFactor;  
-    adjustedHeight = heighta * 0.16;
+    adjustedHeight = heighta * scaleFactorY;
     // adjustedWidtha = widtha;  
     // adjustedHeighta = heighta;  
     newX = 5190 - (rect.yCoordinate + widtha); 
     } else {  
     adjustedWidth = heighta * scaleFactor;  
-    adjustedHeight = widtha * 0.16;  
+    adjustedHeight = widtha * scaleFactorY;  
     // adjustedWidtha = widtha;  
     // adjustedHeighta = heighta;  
     newX = 5190 - (rect.yCoordinate + heighta);  
@@ -222,7 +225,7 @@
   return {  
     ...rect, 
     x: newX * scaleFactor,  
-    y: rect.xCoordinate * 0.16,  
+    y: rect.xCoordinate * scaleFactorY,  
     width: adjustedWidth,  
     height: adjustedHeight,  
     widtha: rect.width, 
@@ -248,8 +251,8 @@
     const existingRects = adjustedRectsb.value.filter(rect => newGlassIds.has(rect.glassId));  
     // 璁$畻鏂扮殑鐭╁舰  
     const newRects = data.outGlass[0].map(rect => {  
-      const scaleFactor =  1621.78/5190; 
-      const scaleFactory =  550/2800; 
+      const scaleFactor =  1390/5190; 
+      const scaleFactory =  750/2800; 
       let adjustedWidth, adjustedHeight, adjustedWidtha, adjustedHeighta,widtha,heighta,newY;
   let newX = rect.yCoordinate; 
       if (rect.width < rect.height) {
@@ -517,11 +520,11 @@
     <el-button  id="searchButton" type="info" @click="dialogFormVisiblec = true;dialogFormVisibleb = false;dialogFormVisible = false;dialogFormVisiblea = false">{{ $t('processCard.print') }}</el-button>
 <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 style="width: 50%;float: left;background-color: #f4f4f5;height: 430px;">
     <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;">
+    <el-scrollbar height="430px" style="background-color: #e9e9eb;">
     <div  style="position: relative;max-width: 1400px;">  
       <div  
       v-for="(rect, index) in adjustedRects1"
@@ -545,11 +548,11 @@
    </el-scrollbar>
    </div>
   </div>
-<div style="width: 49%;float: right;background-color: #f4f4f5;height: 550px;">
+<div style="width: 49%;float: right;background-color: #f4f4f5;height: 430px;">
     <div v-if="adjustedRects2.length > 0">
     <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;">
+    <el-scrollbar height="430px" style="background-color: #e9e9eb;">
     <div  style="position: relative;max-width: 1400px;">  
       <div  
       v-for="(rect, index) in adjustedRects2"
@@ -577,11 +580,11 @@
     </div>
 <div v-if="dialogFormVisiblea">
   <!-- 杩涚倝鍓� -->
-  <el-card style="flex: 1;margin-left: 10px;margin-top: 10px;margin-right: 10px;height: 600px;" v-loading="loading">
+  <el-card style="flex: 1;margin-left: 10px;margin-top: 10px;margin-right: 10px;height: 800px;" v-loading="loading">
     <div v-if="adjustedRectsa.length > 0">
     <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;">
+      <el-scrollbar height="750px" style="background-color: #e9e9eb;">
     <div  style="position: relative;max-width: 1400px;">  
       <div  
       v-for="(rect, index) in adjustedRectsa"  
@@ -604,11 +607,11 @@
 </div>
 <div v-if="dialogFormVisibleb">
   <!-- 宸插嚭鐐� -->
-  <el-card style="flex: 1;margin-left: 10px;margin-top: 10px;margin-right: 10px;height: 600px;" v-loading="loading">
+  <el-card style="flex: 1;margin-left: 10px;margin-top: 10px;margin-right: 10px;height: 800px;" v-loading="loading">
       <div v-if="adjustedRectsb.length > 0">
     <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;">
+      <el-scrollbar height="750px" style="background-color: #e9e9eb;">
     <div  style="position: relative;max-width: 1400px;">  
       <div  
       v-for="(rect, index) in adjustedRectsb"  

--
Gitblit v1.8.0