Prechádzať zdrojové kódy

同步口袋助理会员

wjj 2 dní pred
rodič
commit
19ed7748d2

+ 9 - 0
src/api/qw/importMember.js

@@ -0,0 +1,9 @@
+import request from '@/utils/request'
+
+
+export function syncKdzlMember() {
+  return request({
+    url: '/qw/importMember/syncKdzlMember',
+    method: 'post',
+  })
+}

+ 12 - 0
src/views/qw/companyCustomer/index.vue

@@ -182,6 +182,11 @@
           >导出</el-button
         >
       </el-col>
+      <el-col :span="1.5">
+        <el-button type="primary" plain size="mini" @click="handleSync"
+          >同步</el-button
+        >
+      </el-col>
 
       <right-toolbar
         :showSearch.sync="showSearch"
@@ -538,6 +543,7 @@ import {
   getCustomer,
   exportCustomer,
 } from "@/api/qw/companyCustomer";
+import { syncKdzlMember } from "@/api/qw/importMember";
 export default {
   name: "Customer",
   data() {
@@ -601,6 +607,12 @@ export default {
     this.getList();
   },
   methods: {
+    handleSync() {
+      syncKdzlMember().then((res) => {
+        this.msgSuccess("正在同步中...");
+        this.getList();
+      });
+    },
     getList() {
       this.loading = true;
       const params = this.addDateRange(this.queryParams, this.dateRange);