Explorar el Código

crm系统更新

xiebaomin hace 1 año
padre
commit
4238936a1c

+ 6 - 3
components/cm-share-popup/cm-seller-modal.vue

@@ -2,7 +2,7 @@
     <view class="seller-card" v-if="userId > 0">
         <view class="seller-card-mine" v-if="!modal" @click="changeModal">
             <image
-                :src="userInfo.image || 'https://static.caimei365.com/app/img/icon/default-head.png'"
+                :src="userInfo.image.length > 12 ? userInfo.image : 'https://static.caimei365.com/app/img/icon/default-head-new.png'"
                 style="width: 100%;height: 100%;object-fit: contain;border-radius: 50%;"
                 mode=""
             ></image>
@@ -29,7 +29,7 @@
                             <view class="card-head">
                                 <image
                                     :src="
-                                        userInfo.image || 'https://static.caimei365.com/app/img/icon/default-head.png'
+                                        userInfo.image.length > 12 ? userInfo.image : 'https://static.caimei365.com/app/img/icon/default-head-new.png'
                                     "
                                     mode=""
                                     class="head"
@@ -83,6 +83,9 @@ export default {
         }
     },
     mounted() {
+        if (!uni.getStorageSync('sellerCardChange')) {
+            uni.setStorageSync('sellerCardChange', 1)
+        }
         this.initData()
     },
     methods: {
@@ -91,7 +94,7 @@ export default {
             uni.setStorageSync('sellerCardChange', 2)
         },
         initData() {
-            this.userId = uni.getStorageSync('sellerUserId') || this.sellerUserId
+            this.userId = this.sellerUserId || uni.getStorageSync('sellerUserId')
             if(this.userId > 0) {
                 this.getUserInfo()
                 if (uni.getStorageSync('sellerCardChange') === 1) {

+ 1 - 4
components/cm-share-popup/cm-share-popup.vue

@@ -66,10 +66,7 @@ export default {
     methods: {
         async getUserInfo() {
             const { data } = await this.SellerService.GetSellerHome({ userId: this.userInfo.userId })
-            this.posterData.image =
-                data.image === 'undefined' || !data.image
-                    ? 'https://static.caimei365.com/app/img/icon/default-head.png'
-                    : data.image // 用户头像
+            this.posterData.image = this.posterData.image.length > 12 ? this.posterData.image : 'https://static.caimei365.com/app/img/icon/default-head-new.png' // 用户头像
             this.posterData.qrCode = data.qrCode // 用户二维码
             this.posterData.linkMan = data.linkMan // 用户名
             this.posterData.contractMobile = data.contractMobile // 用户手机号

+ 13 - 9
pages/goods/product.vue

@@ -831,13 +831,14 @@ export default {
         if (option.page == 2) {
             this.backPage = option.page
         }
+        const sellerUserId = option.sellerUserId ? option.sellerUserId : this.scene.sellerUserId ? this.scene.sellerUserId : 0
         if(!uni.getStorageSync('sellerUserId')) {
-            uni.setStorageSync('sellerUserId', option.sellerUserId ? option.sellerUserId : this.scene.sellerUserId || 0)
-        }
-        console.log(uni.getStorageSync('sellerCardChange'))
-        if (!uni.getStorageSync('sellerCardChange')) {
-            uni.setStorageSync('sellerCardChange', 1)
+            uni.setStorageSync('sellerUserId', sellerUserId)
         }
+        console.log('sellerUserId', uni.getStorageSync('sellerUserId'), sellerUserId)
+        // if (!uni.getStorageSync('sellerCardChange')) {
+        //     uni.setStorageSync('sellerCardChange', 1)
+        // }
         this.getWinHeight()
     },
     onReady() {
@@ -1615,14 +1616,17 @@ export default {
         this.isPreviewImage = false
         if (!uni.getStorageSync('spUserId')) {
             this.sellerUserId = uni.getStorageSync('sellerUserId')
-        } 
-        if (uni.getStorageSync('spUserId') === uni.getStorageSync('sellerUserId')) {
-            this.sellerUserId = uni.getStorageSync('sellerUserId')
         } else {
-            this.sellerUserId = 0
+            if (uni.getStorageSync('spUserId') === uni.getStorageSync('sellerUserId')) {
+                this.sellerUserId = uni.getStorageSync('sellerUserId')
+            } else {
+                uni.setStorageSync('sellerUserId', 0)
+                this.sellerUserId = 0
+            }
         }
         if (this.userInfo.userIdentity === 1) {
             this.sellerUserId = 0
+            uni.setStorageSync('sellerUserId', 0)
         }
     }
 }

+ 1 - 1
pages/seller/remarks/business-card.vue

@@ -5,7 +5,7 @@
             <view class="select-content">
                 <image
                     class="aov"
-                    :src="info.image || 'https://static.caimei365.com/app/img/icon/default-head.png'"
+                    :src="(info.image && info.image.length > 12 ) ? info.image : 'https://static.caimei365.com/app/img/icon/default-head-new.png'"
                     mode=""
                 ></image>
                 <text class="cell-more iconfont icon-xiayibu"></text>

+ 1 - 1
pages/seller/remarks/components/mine-card.vue

@@ -6,7 +6,7 @@
         <view class="card-contain">
             <view style="display: flex;">
                 <view class="card-head">
-                    <image :src="userInfo.image || 'https://static.caimei365.com/app/img/icon/default-head.png'" mode="" class="head"></image>
+                    <image :src="userInfo.image.length > 12 ? userInfo.image : 'https://static.caimei365.com/app/img/icon/default-head-new.png'" mode="" class="head"></image>
                 </view>
                 <view class="card-info">
                     <view class="card-info-head">

+ 2 - 0
pages/tabBar/home/index.vue

@@ -143,11 +143,13 @@ export default {
             if (uni.getStorageSync('spUserId') === uni.getStorageSync('sellerUserId')) {
                 this.sellerUserId = uni.getStorageSync('sellerUserId')
             } else {
+                uni.setStorageSync('sellerUserId', 0)
                 this.sellerUserId = 0
             }
         }
         if (this.userInfo.userIdentity === 1) {
             this.sellerUserId = 0
+            uni.setStorageSync('sellerUserId', 0)
         }
     },
     computed: {