From c779188c939cbc3037ca18eb63267f6700d2824e Mon Sep 17 00:00:00 2001 From: zhaojs <349234519@qq.com> Date: 星期三, 21 六月 2023 08:54:21 +0800 Subject: [PATCH] no message --- uniapp/pages/goods/goodsDetail.vue | 40 ++++++++++++++++++++++++++++++++++++++-- 1 files changed, 38 insertions(+), 2 deletions(-) diff --git a/uniapp/pages/goods/goodsDetail.vue b/uniapp/pages/goods/goodsDetail.vue index 65d6aa6..a902283 100644 --- a/uniapp/pages/goods/goodsDetail.vue +++ b/uniapp/pages/goods/goodsDetail.vue @@ -225,7 +225,10 @@ </view> </view> <view class="rightbackbox btnbox colCenCen" @tap="getCouponUrl()"> - <view class="priceText"> + <view v-if="frompage=='freebuy'" class="priceText"> + 锟{optionsInfo.actualPrice}} + </view> + <view v-else class="priceText"> 锟{optionsInfo.fanli}} </view> <view class="texttips"> @@ -263,6 +266,7 @@ import pddEmpower from '../../components/pddempower.vue' import inviteCodeModel from '../../components/inviteCode.vue' import inviterModel from '../../components/inviterModel.vue' + export default { components: { empowerModel, @@ -295,7 +299,8 @@ showtar: false, platform: '', inviteCodeShow: false, - inviterShow: false + inviterShow: false, + frompage:'', }; }, onPageScroll(e) { @@ -305,6 +310,17 @@ if (this.memberId) { this.updataUser() } + + if(!getApp().globalData.hasinit) + { + console.log("鍒濆鍖�") + getApp().getAppInfo(); + } + //console.log("2222222222222222-"+getApp().globalData.hasbcinit); + if(!getApp().globalData.hasbcinit) + { + getApp().bcInit(); + } }, onLoad(options) { this.appinfo = utils.getCacheSync('appInfo') @@ -312,6 +328,10 @@ this.showtar = getApp().globalData.ifwt == 1 ? false : true; this.platform = plus.os.name // #endif + if(options.frompage) + { + this.frompage=options.frompage; + } if (options.id) { this.optionsInfo.goodsId = options.id this.pageType = this.optionsInfo.sourceType ? this.optionsInfo.sourceType : 'tb'; @@ -419,10 +439,13 @@ console.log(this.pageInfo); }) }else if(this.faction == 'd'){ + var that = this; + console.log(this.optionsInfo.goodsId); this.$u.api.getDyGoodsDetail({ goodsId: this.optionsInfo.goodsId }).then(e => { + console.log(e); var res = e.data.info; this.pageInfo = res that.optionsInfo.imgs = that.pageInfo.imgs; @@ -501,6 +524,7 @@ console.log(this.pageType) if (this.pageType == 'tb' || this.pageType == 'tmshop' || this.pageType == 'tm') { if (this.user.tb_account) { + this.getTbsrc() } else { this.empowerModel = true @@ -553,10 +577,22 @@ goodsId: this.optionsInfo.goodsId, type: 0 }).then(e => { + console.log(e) if (e.code != 0) return that.$alert(e.msg) + if(that.frompage=='freebuy') + {//0鍏冭喘鐨勮褰曞晢鍝乮d + console.log(e.data.info.itemId); + this.$u.api.updateFirstFreeBrowse({ + goodsid:that.optionsInfo.goodsId, + new_goodsId:e.data.info.itemId + }).then(e=>{ + + }); + } var res = e.data.info; var tburl = res.shortUrl // #ifdef APP-PLUS + if (plus.runtime.isApplicationExist({ pname: 'com.taobao.taobao', action: 'taobao://' -- Gitblit v1.9.3