瀏覽代碼

chore: lint code --fix

zhangyuhan 2 年之前
父節點
當前提交
d0e4cd16fb

+ 2 - 1
.eslintrc.js

@@ -17,6 +17,7 @@ module.exports = {
   },
   rules: {
     'no-console': process.env.NODE_ENV === 'production' ? 'warn' : 'off',
-    'no-debugger': process.env.NODE_ENV === 'production' ? 'warn' : 'off'
+    'no-debugger': process.env.NODE_ENV === 'production' ? 'warn' : 'off',
+    'eqeqeq': 'warn'
   }
 }

+ 1 - 0
src/components/article-item/ArticleItem.vue

@@ -234,6 +234,7 @@ export default {
       this.$emit('onClick')
     },
     changeCheck (e) {
+      // eslint-disable-next-line camelcase
       const { _id, area, ca_index } = this.article
       const payload = {
         id: _id,

+ 1 - 1
src/components/selector/SelectGroup.vue

@@ -186,4 +186,4 @@ export default {
     }
   }
 }
-</style>
+</style>

+ 3 - 3
src/components/subscribe-manager/powerPerson copy.vue

@@ -308,7 +308,7 @@ export default {
     },
     // 全选
     allToggle () {
-      let lengthId = 0; const nums = []
+      let lengthId = 0
       this.deal_personList.forEach(v => {
         lengthId += v.users.length
       })
@@ -491,7 +491,7 @@ export default {
       // 设置定时器
       let timer
       // 设置现在的时间
-      let now = +new Date()
+      const now = +new Date()
       // 当现在的时间减去上次点击的时间小于3s时,给出提示,并结束执行函数
       if (this.lastTime && now - this.lastTime < 3000) {
         clearTimeout(timer)
@@ -506,7 +506,7 @@ export default {
         })
         if (this.pagetype === 'manage') {
           if (delId) {
-            getDistributor({ wait_empower_id: this.selectData.wait_empower_id, ent_user_id: delId}).then(res => {
+            getDistributor({ wait_empower_id: this.selectData.wait_empower_id, ent_user_id: delId }).then(res => {
               if (res.error_code === 0) {
                 if (res.data.status == 1) {
                   this.centerDialogVisible = false

+ 2 - 2
src/components/subscribe-manager/powerPerson.vue

@@ -251,7 +251,7 @@ export default {
         })
         this.personList = res.data
         this.personSpareList = res.data
-        if (flag == 'yes') {
+        if (flag === 'yes') {
           if (this.searchVal) {
             this.allQuan = false
           }
@@ -269,7 +269,7 @@ export default {
         this.personList = {}
         this.loading = false
       }
-      if (this.searchVal == '') {
+      if (this.searchVal === '') {
         this.allQuan = true
       }
     },