Commit e66d74d6 authored by zhengke's avatar zhengke

修改

parent b0bbdd6e
...@@ -12,7 +12,7 @@ ...@@ -12,7 +12,7 @@
@click="previewImage" @click="previewImage"
></u-swiper> ></u-swiper>
<!-- TODO 分销价格未做 is_share_price --> <!-- TODO 分销价格未做 is_share_price -->
<view class="is_share" v-if="g.share > 0"> <view class="is_share" v-if="g.share > 0" style="top:240px;">
<image <image
src="@/static/images/icon/WechatIMG424.png" src="@/static/images/icon/WechatIMG424.png"
style="width: 20px; margin-left: 12px; opacity: 1;" style="width: 20px; margin-left: 12px; opacity: 1;"
...@@ -32,6 +32,26 @@ ...@@ -32,6 +32,26 @@
<Text>{{ g.share }}</Text> <Text>{{ g.share }}</Text>
</view> </view>
</view> </view>
<view class="is_share" v-if="g.myBuyCommission>0">
<image
src="@/static/images/icon/WechatIMG424.png"
style="width: 20px; margin-left: 12px; opacity: 1;"
mode="widthFix"
/>
<view
style="
display: flex;
flex-direction: column;
margin-left: 8px;
font-size: 11px;
color: #fff;
opacity: 1;
"
>
<Text>自购最高返利</Text>
<Text>{{ g.myBuyCommission }}</Text>
</view>
</view>
</view> </view>
<view class="g-info"> <view class="g-info">
<view class="g-name u-skeleton-rect">{{ g.name }}</view> <view class="g-name u-skeleton-rect">{{ g.name }}</view>
...@@ -330,17 +350,19 @@ export default { ...@@ -330,17 +350,19 @@ export default {
uni.setStorageSync("pid", { pid: option.user_id }); uni.setStorageSync("pid", { pid: option.user_id });
} }
this.u = uni.getStorageSync("mall_UserInfo"); this.u = uni.getStorageSync("mall_UserInfo");
if (!this.u) { // if (!this.u) {
this.u = { // this.u = {
nickName: "未登录", // nickName: "未登录",
avatarUrl: "", // avatarUrl: "",
}; // };
this.showAuth = true; // this.showAuth = true;
} else { // } else {
this.init(); // this.init();
this.initPage(); // this.initPage();
} // }
this.init();
this.initPage();
this.mc = this.$uiConfig.mainColor; this.mc = this.$uiConfig.mainColor;
this.secondary = this.$uiConfig.secondary; this.secondary = this.$uiConfig.secondary;
...@@ -465,9 +487,13 @@ export default { ...@@ -465,9 +487,13 @@ export default {
// ); // );
this.detailContent = richtext; this.detailContent = richtext;
this.loading = false; this.loading = false;
this.initComments();
//登录在调用评论接口
if (this.u) {
this.initComments();
this.setFootMarkInfo(res.data.goods.id);
}
this.initRecommend(); this.initRecommend();
this.setFootMarkInfo(res.data.goods.id);
} else { } else {
this.isExsitGoods = false; this.isExsitGoods = false;
} }
...@@ -506,6 +532,7 @@ export default { ...@@ -506,6 +532,7 @@ export default {
(res) => { (res) => {
console.log(res, "pinglun"); console.log(res, "pinglun");
this.comments = res.data.pageData; this.comments = res.data.pageData;
// this.initRecommend(); // this.initRecommend();
} }
); );
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment