caiyuqin 4 hónapja
szülő
commit
6fe482fa0d
1 módosított fájl, 14 hozzáadás és 15 törlés
  1. 14 15
      pages/store/newSettings.vue

+ 14 - 15
pages/store/newSettings.vue

@@ -135,8 +135,8 @@ export default {
       nameStatus: {
         status: null
       }, //门店名称审核状态
-      renovationStatusAll:null , //装修审核状态
-      renovationStatus:null,
+      renovationStatusAll: null, //装修审核状态
+      renovationStatus: [],
       typeArr: [{
         type: 0,
         name: '待审核'
@@ -167,8 +167,8 @@ export default {
       return [
         {
           title: '店铺logo',
-          content: data.logo || '去配置',
-          class: `${data.logo ? 'active' : 'item-p'}`,
+          content: `${this.renovationStatus.length? '已配置' : '去配置'}`,
+          class: `${this.renovationStatus.length ? 'active' : 'item-p'}`,
           status: false, //是否有状态
           isMore: true, //是否显示更多 
           status: this.filterType(this.renovationStatusAll),
@@ -242,7 +242,7 @@ export default {
       this.indexOption.shopStatus = this.shopStatus
       this.indexOption.nameStatus = this.nameStatus
       this.indexOption.renovationStatus = this.renovationStatus
-      
+
 
       const queryString = encodeURIComponent(JSON.stringify(this.indexOption))
       if (item.type == 1) {
@@ -262,7 +262,7 @@ export default {
           })
         }
       } else if (item.type == 3) {
-        if ( this.renovationStatusAll == 1 && this.indexOption.localMerchantInfoExamine.status == 1) {
+        if (this.renovationStatusAll == 1 && this.indexOption.localMerchantInfoExamine.status == 1) {
           this.selectedBus = this.businessShowList.filter((e => e.value == this.indexOption.merchantStatus))
           this.businessShow = true
         } else {
@@ -376,7 +376,7 @@ export default {
     //0:待审核,1:通过,2:驳回
     filterType(type) {
 
-      if (this.typeArr && type != undefined && type != null && type!=1) {
+      if (this.typeArr && type != undefined && type != null && type != 1) {
         return this.typeArr.find(item => item.type == type).name;
       }
 
@@ -401,19 +401,18 @@ export default {
         params: { merchantId: this.merchantId }
       })
       this.renovationStatus = res.data.result || []
-      this.renovationStatusAll=this.getPriorityStatus(res.data.result || [])
-      console.log( this.renovationStatusAll)
+      this.renovationStatusAll = this.getPriorityStatus(res.data.result || [])
     },
     async editInfo(params) {
       params.id = this.merchantId
       let res = await this.$http.post('/merchant/register/updateInfo', params)
     },
-     getPriorityStatus(arr) {
-        if (arr.some(item => item.status === 2)) return 2;
-        if (arr.some(item => item.status === 0)) return 0;
-        if (arr.some(item => item.status === 1)) return 1;
-        return null;
-      },
+    getPriorityStatus(arr) {
+      if (arr.some(item => item.status === 2)) return 2;
+      if (arr.some(item => item.status === 0)) return 0;
+      if (arr.some(item => item.status === 1)) return 1;
+      return null;
+    },
     //营业状态
     async openSure(val) {
       await this.editInfo({ merchantStatus: this.selectedBus[0].value })