diff --git a/components/NavBar/NavBar.vue b/components/NavBar/NavBar.vue index 0b00cda..ed11205 100644 --- a/components/NavBar/NavBar.vue +++ b/components/NavBar/NavBar.vue @@ -173,8 +173,8 @@ uni.navigateBack(1) return; }else{ - uni.switchTab({ - url: '/pages/home/myCellar' + uni.redirectTo({ + url:'/pages/login/login' }) } diff --git a/pages/SelectAddressActivity.vue b/pages/SelectAddressActivity.vue index 04200c9..aed6dd5 100644 --- a/pages/SelectAddressActivity.vue +++ b/pages/SelectAddressActivity.vue @@ -88,8 +88,8 @@ 门店地址:{{item.address}} - + + - - - + + - + - + + + + + {{item.goodsName}} + {{item.goodsContent}} + + + + {{item.goodsFs}} + {{item.goodsJs}} + {{item.price}} + + + + + + + + + + + + + - 绑定云菜窖 + 转赠留言 - 转赠单号 - - - - - - - - 转赠内容 - - - - - - {{item.goodsName}} - {{item.remarks}} - + {{data.remarks}} - - + + + + + + 温馨提示:您的好友赠送您一份健康蔬菜,请接收。 + + 接收 + + + + + + + + + + + + 温馨提示 + 此卡已被领取,请核对转增信息。 + + 确定 + + - - 绑定 @@ -101,7 +121,11 @@ startHeight: 0, endHeight: 0 }, - data:[] + data: { + remarks: "" + }, + codeType: false, + showModal: false } }, onLoad(options) { @@ -111,6 +135,7 @@ this.page.customerSid = getApp().globalData.sid + let info = uni.getSystemInfoSync(); this.page.startHeight = info.windowWidth * 0.6 @@ -118,17 +143,38 @@ this.getData() }, methods: { - - getData(){ - let _this = this + colseDialog() { + this.showModal = false + }, + getData() { + let _this = this _this.$api.getTransferByCode(this.page.code).then((resp) => { - _this.data = resp - + + // 1 未领取 2 已绑定 + + // 已绑定 + if ('2' == resp.state) { + + if (resp.recipientSid == _this.page.customerSid) { + uni.redirectTo({ + url: '/pages/login/login' + }) + } else { + _this.showModal = true + } + + } else { + _this.data = resp + _this.codeType = true + } + + + }).catch(e => { _this.longToast(e.msg) }) }, - + onKeyInput1(event) { this.page.code = event.target.value }, @@ -175,8 +221,8 @@ uni.navigateBack(1) return; } else { - uni.switchTab({ - url: '/pages/home/myCellar' + uni.redirectTo({ + url: '/pages/login/login' }) } @@ -194,4 +240,34 @@ width: 100vw; height: 70vw; } + + + /* 弹窗样式 */ + .model { + position: absolute; + width: 100%; + height: 100%; + background: #000; + z-index: 100000; + opacity: 0.7; + top: 0; + left: 0; + + } + + .modalDlg2 { + /* 设置超出滚动 */ + overflow: auto; + position: fixed; + z-index: 100000; + display: flex; + width: 100%; + height: 100%; + top: 0; + left: 0; + flex-direction: column; + justify-content: center; + align-items: center; + } + \ No newline at end of file diff --git a/pages/bind/bind_pickUpCard.vue b/pages/bind/bind_pickUpCard.vue index e73f872..c578d25 100644 --- a/pages/bind/bind_pickUpCard.vue +++ b/pages/bind/bind_pickUpCard.vue @@ -67,7 +67,7 @@ - 绑定 + 接收 diff --git a/pages/bind/bind_pickUpCard2.vue b/pages/bind/bind_pickUpCard2.vue index 623d9a1..574a230 100644 --- a/pages/bind/bind_pickUpCard2.vue +++ b/pages/bind/bind_pickUpCard2.vue @@ -70,7 +70,7 @@ - 绑定 + 接收 diff --git a/pages/good/reservation.vue b/pages/good/reservation.vue index e87f59f..d338994 100644 --- a/pages/good/reservation.vue +++ b/pages/good/reservation.vue @@ -63,13 +63,15 @@ + style="display: flex;flex-direction: row;align-items: center;justify-content: center;margin-top: 16px;"> 提货时间 - - + + diff --git a/pages/home/cloudCard2.vue b/pages/home/cloudCard2.vue index 4757800..67927ba 100644 --- a/pages/home/cloudCard2.vue +++ b/pages/home/cloudCard2.vue @@ -75,14 +75,15 @@ + style="width: 90px;height: 90px; border-radius: 10px; " mode="aspectFill"> + - {{item.name}} + {{item.name}} {{item.remark}} @@ -96,28 +97,32 @@ font-size: 10px;color: #EE752F; margin-left: 10px; margin-right: 10px; ">{{item.weight}}{{item.specificationUnit}}/{{item.unitName}} - + 提货截止日:{{item.periodValidity}} ¥{{item.mefenPrice}} + style="font-size: 14px;color: #FF5006;">¥{{item.mefenPrice}}元 - + - {{item.goodsNumber}} + {{item.goodsNumber}} + + @@ -161,7 +166,7 @@ style="color: #888;font-size: 10px;height: 10px;line-height: 10px;margin-top: 5px;"> ,{{data.brandVos[selectIndex2].qssl}}斤起订。 - @@ -169,7 +174,7 @@ >> - + --> @@ -306,17 +311,38 @@ - + + + + + + + + + + + + + + + + + + - 云菜窖 + 云菜窖 @@ -327,7 +353,7 @@ - + @@ -337,6 +363,7 @@ + @@ -349,6 +376,10 @@ notData: false, showModal: false, showModal1: false, + showModal4: false, + goodsItem: { + goodsNumber: "", + }, showModal2: false, newPerGiftList: [ @@ -415,9 +446,8 @@ if (getApp().globalData.isPurchase == '1') this.showModal = true - if (getApp().globalData.mobile == '') - this.showModal1 = true + this.showModal4 = true }, @@ -493,6 +523,9 @@ colseDialog2() { this.showModal2 = false }, + colseDialog4(){ + this.showModal4 = false + }, getBannerList() { let _this = this _this.$api.bannerList().then((resp) => { @@ -605,35 +638,36 @@ jian(item) { const that = this console.log("item》》》》", item) - if (Number(item.goodsNumber) == 1) { - - wx.showModal({ - content: '确定不要了吗', - cancelText: "再想想", - confirmText: "删除", - confirmColor: "#FF9900", - success(res) { - if (res.confirm) { - console.log('用户点击确定') - item.goodsNumber = 0 - item.subtotal = 0 - - that.upDateShoppCart(item) - } else if (res.cancel) { - - } - } - }) - - } else { - if (Number(item.goodsNumber) > 0) { - item.goodsNumber = Number(item.goodsNumber) - 1 - } - + // if (Number(item.goodsNumber) == 1) { + + // wx.showModal({ + // content: '确定不要了吗', + // cancelText: "再想想", + // confirmText: "删除", + // confirmColor: "#FF9900", + // success(res) { + // if (res.confirm) { + // console.log('用户点击确定') + // item.goodsNumber = 0 + // item.subtotal = 0 + + // that.upDateShoppCart(item) + // } else if (res.cancel) { + + // } + // } + // }) + + // } else { + if (Number(item.goodsNumber) > 0) { + item.goodsNumber = Number(item.goodsNumber) - 1 item.subtotal = Number(item.goodsNumber) * Number(item.mefenPrice) that.upDateShoppCart(item) } + + + // } }, jia(item) { @@ -642,6 +676,34 @@ this.upDateShoppCart(item) }, + numberClick(item) { + this.showModal1 = true + this.goodsItem = { + goodsSid: item.goodsSid, + goodsName: item.name, + goodsNumber: item.goodsNumber, + affiliation: this.data.brandVos[this.selectIndex2].id, + price: item.mefenPrice, + weight: item.weight, + customerSid: getApp().globalData.sid + } + + }, + inCart() { + let _this = this + // console.log("inCart",_this.goodsItem); + + _this.$api.addShoppingCart(_this.goodsItem).then((resp) => { + _this.getgoods() + this.goodsItem = {} + this.showModal1 = false + }).catch(e => { + _this.getgoods() + this.goodsItem = {} + this.showModal1 = false + }) + + }, getallPrice() { @@ -886,22 +948,21 @@ userSid: getApp().globalData.sid, code: e.detail.code }).then((resp) => { - _this.showModal1 = false + _this.showModal4 = false getApp().globalData.mobile = resp }).catch(e => { console.log(e); }) }, - + } }