wjj 2 недель назад
Родитель
Сommit
952c2f1419
2 измененных файлов с 33 добавлено и 1 удалено
  1. 10 0
      src/api/hisStore/collection.js
  2. 23 1
      src/views/qw/collectionFully/index.vue

+ 10 - 0
src/api/hisStore/collection.js

@@ -82,3 +82,13 @@ export function getSalesHasCollectionPermission() {
     method: 'get',
   })
 }
+
+
+// 新增用户信息采集
+export function resetCIDCollection(data) {
+  return request({
+    url: '/hisStore/collection/resetCIDCollection',
+    method: 'post',
+    data: data
+  })
+}

+ 23 - 1
src/views/qw/collectionFully/index.vue

@@ -118,6 +118,15 @@
           >
             分享
           </el-button>
+          <el-button
+            v-if="scope.row.qwTag === 1"
+            size="mini"
+            type="text"
+            icon="el-icon-refresh"
+            @click="handleReset(scope.row)"
+          >
+            重置
+          </el-button>
         </template>
       </el-table-column>
     </el-table>
@@ -200,7 +209,7 @@
 
 <script>
 import {fullyCollectionInfoList, getCollectionPackageInfo} from "@/api/qw/collectionPendingSales";
-import {getWxaCodeCollectionUnLimitNew} from "@/api/hisStore/collection";
+import {getWxaCodeCollectionUnLimitNew,resetCIDCollection} from "@/api/hisStore/collection";
 import FullyCollectionInfoDialog from "./fullyCollectionInfoDialog.vue";
 import BindPackageDialog from "./BindPackageDialog.vue";
 import userDetails from '@/views/store/components/userDetails1.vue';
@@ -259,6 +268,19 @@ export default {
     this.fetchSourceList();
   },
   methods: {
+    handleReset(row){
+      const that = this
+      this.$confirm('是否确认重置该信息采集数据项?', "警告", {
+          confirmButtonText: "确定",
+          cancelButtonText: "取消",
+          type: "warning"
+        }).then(function() {
+          return resetCIDCollection(row);
+        }).then(() => {
+          this.getList();
+          this.msgSuccess("重置成功");
+        }).catch(() => {});
+    },
     // 获取状态文本
     getStatusText(status) {
       const statusMap = {