From 55aa572d4750c29b1bb6b21dae800a2dbe71a9d4 Mon Sep 17 00:00:00 2001 From: wangfei <3597712270@qq.com> Date: 星期五, 13 十二月 2024 14:26:04 +0800 Subject: [PATCH] 删除废弃代码 --- UI-Project/src/views/GlassStorage/MaterialRackManagement.vue | 54 +----------------------------------------------------- 1 files changed, 1 insertions(+), 53 deletions(-) diff --git a/UI-Project/src/views/GlassStorage/MaterialRackManagement.vue b/UI-Project/src/views/GlassStorage/MaterialRackManagement.vue index 7a0d18c..9edb226 100644 --- a/UI-Project/src/views/GlassStorage/MaterialRackManagement.vue +++ b/UI-Project/src/views/GlassStorage/MaterialRackManagement.vue @@ -21,7 +21,6 @@ <el-select v-model="formData2.dzw" placeholder="璇烽�夋嫨鍚婅浣�"> <el-option label="鍚婅浣�1" value="鍚婅浣�1"></el-option> <el-option label="鍚婅浣�2" value="鍚婅浣�2"></el-option> - <!-- 鏍规嵁瀹為檯鎯呭喌娣诲姞鏇村閫夐」 --> </el-select> </el-form-item> </div> @@ -62,7 +61,6 @@ </el-tag> </template> </el-table-column> - <!-- 鎿嶄綔鍒� --> <el-table-column label="鎿嶄綔" width="250"> <template #default="{ row }"> @@ -133,7 +131,6 @@ </el-tag> </template> </el-table-column> - <!-- 鎿嶄綔鍒� --> <el-table-column label="鎿嶄綔" width="350"> <template #default="{ row }"> @@ -150,7 +147,6 @@ </el-table-column> </el-table> </el-card> - <div class="img-ypcc"> <div class="img-car1" @@ -167,7 +163,6 @@ ></div> </div> </div> - <!-- 鍏ュ簱瀵硅瘽妗� --> <el-dialog title="鍏ュ簱" @@ -354,7 +349,6 @@ const handleCurrentChange = (val) => { currentPage.value = val; }; - const formatTaskType = (row, column) => { if (row.taskType === "浠庝粨浣嶅埌鍚婅浣�") { return `浠庝粨浣�${row.shelfRack}鍒板悐瑁呬綅${row.loadRack}`; @@ -366,7 +360,6 @@ return `浠庡悐瑁呬綅${row.loadRack}鍒颁粨浣�${row.shelfRack}`; } }; - const getTagType2 = (status) => { switch (status) { case "completed": @@ -381,12 +374,10 @@ return ""; } }; - const getTagType = (status) => { return status === 1 ? "success" : "danger"; // 鏍规嵁鐘舵�佸�煎喅瀹氭爣绛剧被鍨嬶紝杩欓噷鍋囪鐘舵�佷负1鏃朵负鎴愬姛锛堢豢鑹诧級锛屽惁鍒欎负澶辫触锛堢孩鑹诧級 }; - const toggleStatus = (row) => { // 鍒囨崲鏂欐灦鐘舵�佺殑閫昏緫 row.enableState = 1 - row.enableState; // Toggle between 0 and 1 @@ -397,35 +388,25 @@ // 瀹氫箟娑堟伅澶勭悊鍑芥暟锛屾洿鏂� receivedData 鍙橀噺 const handleMessage = (data) => { // 鏇存柊 tableData 鐨勬暟鎹� - tableData.value = data.rack[0]; // 鍋囪 tableData 鏄搷搴斿紡瀵硅薄鎴栧彉閲� - tableData.value.forEach((item) => { // 鑾峰彇 createTime 鐨勬椂闂存埑 const createTimeTimestamp = item.createTime; - // 鍒涘缓鏃ユ湡瀵硅薄 const date = new Date(createTimeTimestamp); - // 鏍煎紡鍖栨棩鏈熸椂闂翠负鏈湴鏍煎紡 const formattedDateTime = date.toLocaleString(); - // 鏇挎崲鍘熸潵鐨� createTime 瀛楁涓烘牸寮忓寲鍚庣殑鏃ユ湡鏃堕棿瀛楃涓� item.createTime = formattedDateTime; }); - tasktableData.value = data.tasks[0]; // 鍋囪 tasktableData 鏄搷搴斿紡瀵硅薄鎴栧彉閲� - tasktableData.value.forEach((item) => { // 鑾峰彇 createTime 鐨勬椂闂存埑 const createTimeTimestamp = item.startTime; - // 鍒涘缓鏃ユ湡瀵硅薄 const date = new Date(createTimeTimestamp); - // 鏍煎紡鍖栨棩鏈熸椂闂翠负鏈湴鏍煎紡 const formattedDateTime = date.toLocaleString(); - // 鏇挎崲鍘熸潵鐨� createTime 瀛楁涓烘牸寮忓寲鍚庣殑鏃ユ湡鏃堕棿瀛楃涓� item.startTime = formattedDateTime; }); @@ -442,9 +423,7 @@ console.log("鍏抽棴浜�"); closeWebSocket(); }); - const tasktableData = ref([]); - const dialogVisible = ref(false); const formData = ref({ number: "", @@ -455,11 +434,9 @@ pieces: "", loadRack: 1, }); - const formData2 = ref({ dzw: "", }); - const handleDelete = (row) => { // 浣跨敤 Element UI 鐨� MessageBox.confirm 鏂规硶杩涜浜屾纭 ElMessageBox.confirm("纭畾瑕佹墽琛屽垹闄ゆ搷浣滃悧锛�", "纭鍒犻櫎", { @@ -469,12 +446,10 @@ }) .then(() => { // 鐐瑰嚮纭鎸夐挳鐨勫洖璋冿紝鎵ц鍑哄簱鎿嶄綔 - const intNumber = { id: parseInt(row.number), }; deleteRawUsage(intNumber); - console.log("鎵ц鍒犻櫎鎿嶄綔"); }) .catch(() => { @@ -482,7 +457,6 @@ console.log("鍙栨秷鍒犻櫎鎿嶄綔"); }); }; - const handleCheckout = (row) => { // 浣跨敤 Element UI 鐨� MessageBox.confirm 鏂规硶杩涜浜屾纭 ElMessageBox.confirm("纭畾瑕佹墽琛屽嚭搴撴搷浣滃悧锛�", "纭鍑哄簱", { @@ -504,17 +478,14 @@ console.log("鍙栨秷鍑哄簱鎿嶄綔"); }); }; - const handleInbound = () => { // 鎵撳紑鍏ュ簱瀵硅瘽妗� dialogVisible.value = true; }; - const storage = () => { // 鎵撳紑鍏ュ簱瀵硅瘽妗� Hidden.value = true; }; - const handleCloseDialog = () => { // 鍏抽棴瀵硅瘽妗嗘椂閲嶇疆琛ㄥ崟鏁版嵁 formData.value = { @@ -527,7 +498,6 @@ }; dialogVisible.value = false; }; - const handleConfirmInbound = () => { inStorage(formData.value); // 澶勭悊纭鍏ュ簱閫昏緫锛屽彲浠ュ湪杩欓噷鎻愪氦琛ㄥ崟鎴栬�呮墽琛屽叾浠栨搷浣� @@ -535,7 +505,6 @@ // 鍏抽棴瀵硅瘽妗� dialogVisible.value = false; }; - const dialogVisible3 = ref(false); const colors = ref([ { "0_glass_id": "Red" }, @@ -543,7 +512,6 @@ { "0_glass_id": "Blue" }, // Add more colors as needed ]); - const formData3 = ref({ selectedColor: "", wid: "", @@ -551,7 +519,6 @@ thinkness: "", num: "", }); - const addglass = () => { // 鎵撳紑鍏ュ簱瀵硅瘽妗� dialogVisible3.value = true; @@ -559,17 +526,14 @@ const handleCommand = (command) => { formData.value.selectedColor = command; }; - const clearInput = (field) => { formData.value[field] = ""; }; - const submitForm = () => { console.log("鎻愪氦鏁版嵁:", formData.value); dialogVisible3.value = false; // Add your submit logic here }; - const editdialogVisible = ref(false); const editForm = ref({ id: "", @@ -581,7 +545,6 @@ }); const editFormRef = ref(null); let currentRow = ref(null); - // 澶勭悊琛岀偣鍑讳簨浠� const edithandleRowClick = (row) => { currentRow.value = row; @@ -595,11 +558,9 @@ editdialogVisible.value = true; console.log(editForm.value); }; - // 娣诲姞淇濆瓨缂栬緫鍐呭 const editsaveEdit = () => { if (!currentRow.value) return; - // 鏇存柊褰撳墠琛屾暟鎹� currentRow.value.pieces = editForm.value.pieces; currentRow.value.batchId = editForm.value.batchId; @@ -608,11 +569,9 @@ currentRow.value.rawThickness = editForm.value.rawThickness; // 璋冪敤鏇存柊鍑芥暟锛屽苟澶勭悊鍏惰繑鍥炵殑 Promise updateRawUsage(editForm.value); - // 鍏抽棴瀵硅瘽妗� editdialogVisible.value = false; }; - // 瀵硅瘽妗嗗叧闂椂閲嶇疆缂栬緫琛ㄥ崟鍜屽綋鍓嶈鏁版嵁 const edithandleDialogClose = () => { editForm.value.pieces = ""; @@ -620,10 +579,8 @@ editForm.value.rawWidth = ""; editForm.value.rawHeight = ""; editForm.value.rawThickness = ""; - currentRow.value = null; }; - const handleRestart = (row) => { // 浣跨敤 Element UI 鐨� MessageBox.confirm 鏂规硶杩涜浜屾纭 ElMessageBox.confirm("纭畾瑕佹墽琛岄噸鏂板紑濮嬫搷浣滃悧锛�", "纭閲嶆柊寮�濮�", { @@ -637,8 +594,6 @@ Type:"閲嶆柊寮�濮�" } taskUpdate(taskdata); - - console.log("鎵ц閲嶆柊寮�濮嬫搷浣�", row); }) .catch(() => { @@ -646,7 +601,6 @@ console.log("鍙栨秷閲嶆柊寮�濮嬫搷浣�"); }); }; - const handleDeletetask = (row) => { // 浣跨敤 Element UI 鐨� MessageBox.confirm 鏂规硶杩涜浜屾纭 ElMessageBox.confirm("纭畾瑕佹墽琛屽垹闄や换鍔℃搷浣滃悧锛�", "纭鍒犻櫎浠诲姟", { @@ -668,7 +622,6 @@ console.log("鍙栨秷鍒犻櫎浠诲姟鎿嶄綔"); }); }; - const handleComplete = (row) => { // 浣跨敤 Element UI 鐨� MessageBox.confirm 鏂规硶杩涜浜屾纭 ElMessageBox.confirm("纭畾瑕佹墽琛屼换鍔″畬鎴愭搷浣滃悧锛�", "纭浠诲姟瀹屾垚", { @@ -677,7 +630,6 @@ type: "warning", }) .then(() => { - const taskdata={ id:row.id, Type:"瀹屾垚" @@ -692,7 +644,6 @@ }); }; </script> - <style scoped> #dt { display: block; @@ -710,7 +661,6 @@ text-align: center; margin-top: -15px; } - .img-ypcc { margin-left: 80px; background-image: url("../../assets/ypcc.png"); @@ -724,7 +674,6 @@ position: relative; margin-top: 0px; } - .img-car1 { background-image: url("../../assets/ypccche.png"); position: absolute; @@ -737,9 +686,8 @@ overflow: hidden; position: relative; } - .custom-dialog { max-height: 90vh; /* 鏈�澶ч珮搴︿负瑙嗗彛楂樺害鐨�90% */ overflow-y: auto; /* 瀵硅瘽妗嗗唴閮ㄥ嚭鐜板瀭鐩存粴鍔ㄦ潯 */ } -</style> +</style> \ No newline at end of file -- Gitblit v1.8.0