D4THYL3\long 3 年之前
父節點
當前提交
75161fe238
共有 1 個文件被更改,包括 24 次插入1 次删除
  1. 24 1
      smart/src/views/vehicleInformation/index.vue

+ 24 - 1
smart/src/views/vehicleInformation/index.vue

@@ -127,7 +127,7 @@
           >
             <i
               class="zoniot_font zoniot-icon-shanchu redText"
-              @click="deleteOne(scope.row.id)"
+              @click="deleteOne(scope.row)"
             ></i>
           </el-tooltip>
         </div>
@@ -153,6 +153,29 @@ export default {
     }
   },
   methods: {
+    // 删除
+    deleteOne (row) {
+      debugger
+      // cardId
+      // parkId
+      this.$confirm('此操作将永久删除, 是否继续?', '提示', {
+        confirmButtonText: '确定',
+        cancelButtonText: '取消',
+        type: 'warning'
+      }).then(() => {
+        this.$message({
+          type: 'success',
+          message: '删除成功!'
+        });
+        this.$http.get('/sc-community-web/parkingCar/deleteVehicleInfor', { id: row.cardId, parkId: row.parkId }).then(({ data, msg, status }) => { }).catch(() => { });
+        this.mixins_search();
+      }).catch(() => {
+        this.$message({
+          type: 'info',
+          message: '已取消删除'
+        });
+      });
+    },
     add (row) {
       console.log(row.cardId);
       this.details(row.cardId);