Selaa lähdekoodia

修改名片夹 分类显示2个字

achao 2 vuotta sitten
vanhempi
commit
bcd70ca90a
1 muutettua tiedostoa jossa 5 lisäystä ja 8 poistoa
  1. 5 8
      xiaochengxu/pages/cardHolder/cardHolder.vue

+ 5 - 8
xiaochengxu/pages/cardHolder/cardHolder.vue

@@ -216,7 +216,7 @@
 								<image src="../../static/imgs/card/home.png" mode="widthFix"
 									style="width: 32rpx;height: auto;" @click="toHome(item)"></image>
 								<text @click='switchType(item)'
-									style="color: #fff;font-size: 36rpx;font-weight: 700;">{{item.classify?item.classifyName:'默'}}</text>
+									style="color: #fff;font-size: 36rpx;font-weight: 700;">{{item.classify?item.classifyName:'默'}}</text>
 								<image v-if='item.shareCard==1' src="../../static/imgs/card/share.png" mode="widthFix"
 									style="width: 35rpx;height: auto;" @click="share(item)"></image>
 
@@ -561,12 +561,9 @@
 			},
 			async getPhoneNumber(e) {
 				that.userInfo = await this.$request.wxlogin()
-				this.$nextTick(function() {
-					that.userInfo.phone = that.$request.getPhone(e, that.userInfo)
-					that.showAuthorizePhone = false
-					that.showAuthorizeUser = true
-				});
-				
+				that.userInfo.phone = await this.$request.getPhone(e, that.userInfo)
+				this.showAuthorizePhone = false
+				this.showAuthorizeUser = true
 
 			},
 			delVal() {
@@ -1072,7 +1069,7 @@
 							for (var i = 0; i < res.data.items.length; i++) {
 								res.data.items[i].checked = false
 								if (res.data.items[i].classify) {
-									res.data.items[i].classifyName = res.data.items[i].classify[0]
+									res.data.items[i].classifyName = res.data.items[i].classify.substring(0,2)
 								}
 							}
 							this.cardHolderList = res.data.items