From df418a35e80167ae120e5840d6ff8d19676ee399 Mon Sep 17 00:00:00 2001
From: 小小儁爺 <1694218219@qq.com>
Date: 星期五, 15 五月 2026 13:37:09 +0800
Subject: [PATCH] 1.报告记录删除功能

---
 src/views/statistic/reportList.vue |   65 ++++++++++++++++++++++++--------
 1 files changed, 48 insertions(+), 17 deletions(-)

diff --git a/src/views/statistic/reportList.vue b/src/views/statistic/reportList.vue
index 8df2db0..ace6022 100644
--- a/src/views/statistic/reportList.vue
+++ b/src/views/statistic/reportList.vue
@@ -275,6 +275,24 @@
             sortable="custom"
           />
 
+          <el-table-column
+            label="鎿嶄綔"
+            width="80"
+            fixed="right"
+          >
+            <template slot-scope="{row}">
+              <div class="operationClass">
+                <el-tooltip class="item" effect="dark" content="鍒犻櫎璁板綍" placement="top">
+                  <i
+                    class="el-icon-delete"
+                    :style="{color:$store.state.settings.theme}"
+                    @click="del(row)"
+                  />
+                </el-tooltip>
+              </div>
+            </template>
+          </el-table-column>
+
         </el-table>
       </div>
       <!--鍒嗛〉-->
@@ -337,6 +355,7 @@
 import ImportPicker from '@/components/ImportPicker'
 import { handleDatetime, validateCode } from '@/utils/global'
 import {
+  DeleteMesOrderStepReport,
   GroupSalaryReportSearchUser, MesOrderStepReportExcelSearch, MesOrderStepReportSearch
 } from '@/api/ReportManager'
 import elDragDialog from '@/directive/el-drag-dialog'
@@ -553,23 +572,35 @@
     },
     // 鍒犻櫎鎸夐挳
     async del(row) {
-      // this.$confirm('鏄惁纭鍒犻櫎?', '鎻愮ず', {
-      //   confirmButtonText: '纭畾',
-      //   cancelButtonText: '鍙栨秷',
-      //   type: 'warning'
-      // }).then(() => {
-      //   DeleteOrganization({ orgid: row.code }).then(res => {
-      //     if (res.code === '200') {
-      //       this.$message.success('鍒犻櫎鎴愬姛!')
-      //       if (this.form.page > 1 && this.tableData.length === 1) {
-      //         this.form.page--
-      //       }
-      //       this.getMesOrderStepReportSearch()
-      //     }
-      //   })
-      // }).catch(() => {
-      //   this.$message.info('宸插彇娑堝垹闄�')
-      // })
+      this.$confirm('鏄惁纭鍒犻櫎?', '鎻愮ず', {
+        confirmButtonText: '纭畾',
+        cancelButtonText: '鍙栨秷',
+        type: 'warning'
+      }).then(() => {
+        const data = {
+          'id': row.id,
+          'sbid': row.sbid,
+          'wocode': row.wo_code,
+          'stepcode': row.step_code,
+          'stype': row.steptype,
+          'goodqty': row.report_qty,
+          'ngqty': row.ng_qty,
+          'laborbadqty': row.laborbad_qty,
+          'materielbadqty': row.materielbad_qty,
+          'verify': row.verify
+        }
+        DeleteMesOrderStepReport(data).then(res => {
+          if (res.code === '200') {
+            this.$message.success('鍒犻櫎鎴愬姛!')
+            if (this.form.page > 1 && this.tableData.length === 1) {
+              this.form.page--
+            }
+            this.getMesOrderStepReportSearch()
+          }
+        })
+      }).catch(() => {
+        this.$message.info('宸插彇娑堝垹闄�')
+      })
     },
     // 瀵硅瘽妗嗗叧闂簨浠�
     handleClose() {

--
Gitblit v1.9.3