ソースを参照

[edit][detail-bug]

zhangwei 3 年 前
コミット
a330768ee8
1 ファイル変更18 行追加1 行削除
  1. 18 1
      pages/index.vue

+ 18 - 1
pages/index.vue

@@ -149,7 +149,7 @@
 						<div class="luck-time">{{ formatTime(item.receiveTimestamp) }}</div>
 					</div>
 					<div class="luck-money">
-						<img :src="item.currencyIconPath" alt />
+						<img :src="currencyIconPath" alt />
 						<div class="luck-money-txt">{{ item.amountValue || 0 }}</div>
 					</div>
 					<div class="luck-king" v-if="item.maxAmount">
@@ -318,6 +318,7 @@ export default {
 			this.show_home = true
 			switch (data.code.toString()) {
 				case '0':
+					this.getDetail()
 					if (data.data.newReceived) {
 						this.status = 'not-open'
 						setTimeout(() => {
@@ -406,6 +407,20 @@ export default {
 				postNickName: this.detail.postBizData.postUserInfo.nickName
 			};
 			Cookies.set('pickup_info', JSON.stringify(pickupInfo), { expires: 100 });
+		},
+		async getDetail() {
+			let { data } = await axios.post(`${baseURL}/denet/post/getDetail`, {
+				baseInfo: {
+					appVersionCode: this.appVersionCode,
+					mid: this.mid
+				},
+				params: {
+					postId: this.detail.postId
+				}
+			})
+			if (data.code == 0) {
+				this.detail.postBizData = JSON.parse(data.data.postBizData)
+			}
 		}
 	},
 
@@ -434,6 +449,7 @@ export default {
 		}
 	},
 
+
 	mounted() {
 		if (!this.detail.postId) {
 			return
@@ -479,6 +495,7 @@ export default {
 			// 领取任务红包
 			this.setCookieMid()
 			this.getRedPacket()
+			this.getDetail()
 			this.setPickupInfo()
 		} else {
 			this.show_home = true