Browse Source

TBtools-下拉框选词扣费

panyong 4 years ago
parent
commit
3ddc927983
1 changed files with 17 additions and 0 deletions
  1. 17 0
      htmldev/TBTools/src/views/modules/tools/tools-starkeysearch.vue

+ 17 - 0
htmldev/TBTools/src/views/modules/tools/tools-starkeysearch.vue

@@ -82,11 +82,28 @@ export default {
               value: item[0],
               resource: resource
             }))
+            this.funPayment(encodeURIComponent(api))
           }
           this.dataListLoading = false
         })
       })
     },
+    // 扣费接口
+    funPayment (api = '') {
+      this.$http({
+        url: this.$http.adornUrl('/user/apicut'),
+        method: 'get',
+        params: this.$http.adornParams({
+          path: api
+        })
+      }).then(({ data }) => {
+        if (data.status) {
+          return
+        }
+        this.$message.error(data.msg)
+      }).catch(() => {
+      })
+    },
     // 导出表格所用
     exportExcel (id) {
       var wb = XLSX.utils.table_to_book(document.querySelector('#' + id))