| @@ -334,7 +334,7 @@ Page({ | |||
| } else { | |||
| that.setData({ | |||
| clock02: "00", | |||
| day02: "00", | |||
| day02: "0", | |||
| hour02: "00", | |||
| min02: "00", | |||
| sec02: "00", | |||
| @@ -43,7 +43,7 @@ | |||
| </view> | |||
| <text class="restNum fr">剩余<text>{{data.remainInventory}}件</text></text> | |||
| </view> | |||
| <view wx:if="{{showbutton1}}" style='font-size:24rpx;font-family:PingFang-SC-Medium;font-weight:500;color:rgba(0,0,0,1);'>砍价活动将于<view style='display:inline;margin:0 8rpx;color:#F74812;font-size:28rpx;font-family:PingFang-SC-Medium;font-weight:500;'>{{day02+'天'+hour02+':'+min02+':'+sec02}}</view>后准时开始</view> | |||
| <view wx:if="{{showbutton1&&data.type==8}}" style='font-size:24rpx;font-family:PingFang-SC-Medium;font-weight:500;color:rgba(0,0,0,1);'>砍价活动将于<view style='display:inline;margin:0 8rpx;color:#F74812;font-size:28rpx;font-family:PingFang-SC-Medium;font-weight:500;'>{{day02+'天'+hour02+':'+min02+':'+sec02}}</view>后准时开始</view> | |||
| <view class='rest' wx:if="{{data.validType==2}}">有效期:自领取之日起 | |||
| <text class='time'>{{validDays}}</text>天内有效<text class="use">(请在有效期内使用)</text></view> | |||
| <view class='rest' wx:if="{{data.validType==1}}">有效期: | |||
| @@ -9,6 +9,7 @@ Page({ | |||
| */ | |||
| data: { | |||
| teljpgUrl: imgurl.teljpg.url, | |||
| home: imgurl.home.url, | |||
| couponChannelId: '', | |||
| couponId: '', | |||
| data: [], | |||
| @@ -37,6 +38,11 @@ Page({ | |||
| }) | |||
| this.checkUser(options); | |||
| }, | |||
| gotoIndex(){ | |||
| wx.reLaunch({ | |||
| url: '/pages/index/index', | |||
| }) | |||
| }, | |||
| /** | |||
| * 判断用户是否已经在团中 | |||
| */ | |||
| @@ -225,7 +231,13 @@ Page({ | |||
| }) | |||
| .then(res => { | |||
| wx.hideLoading() | |||
| _this.goToOrderGroup(orderId, res.data.orderGroupId, _this) | |||
| if (!orderGroupId) { | |||
| wx.navigateTo({ | |||
| url: '/pages/order/detail/index?orderId=' + res.data.id, | |||
| }) | |||
| } else { | |||
| _this.goToOrderGroup(orderId, res.data.orderGroupId, _this) | |||
| } | |||
| }) | |||
| .catch(err => { | |||
| console.log(err); | |||
| @@ -33,8 +33,17 @@ | |||
| <view class='s-button' bindtap='gotoPartner'>去拼团</view> | |||
| </view> | |||
| </view> --> | |||
| <view class='rest' wx:if="{{data.validType==1}}">有效期: | |||
| <text class='time'>{{data.validStartDate}}至{{data.validEndDate}}<text class="use">(请在有效期内使用)</text></text> | |||
| </view> | |||
| <view class='rest'> | |||
| <text class='txt01'>限购条件:</text> | |||
| <text class='time'>每人{{data.useLimitQuantity}}张</text> | |||
| <text class='times' style='margin-left:10rpx;' wx:if="{{data.autoRefund == 0}}">(支持过期自动退款)</text> | |||
| <text class='times' style='margin-left:10rpx;' wx:if="{{data.autoRefund == 1}}">(不支持过期自动退款)</text> | |||
| </view> | |||
| <view class='p-des'> | |||
| <view class='p-title'>商品详情:</view> | |||
| <view class='p-title'>购买须知:</view> | |||
| <view class='p-list'>{{data.remark}}</view> | |||
| </view> | |||
| <view class='posi'> | |||
| @@ -51,6 +60,7 @@ | |||
| </view> | |||
| </view> | |||
| <view class='edit'> | |||
| <button class='goback' bindtap='gotoIndex'><image src='{{home}}' mode="widthFix"></image></button> | |||
| <view class='edit-left' bindtap='{{canBuyIf?"gotoBuy":""}}'> | |||
| <view class='edit-left-top'> | |||
| <view class='price'>{{data.price}}</view> | |||
| @@ -161,7 +161,7 @@ | |||
| } | |||
| .edit-left{ | |||
| float: left; | |||
| width: 330rpx; | |||
| width: 269rpx; | |||
| height: 95rpx; | |||
| background:rgba(255,169,2,1); | |||
| box-shadow:0px 8rpx 8rpx 1rpx rgba(255,169,2,0.32); | |||
| @@ -169,7 +169,7 @@ | |||
| } | |||
| .edit-right{ | |||
| float: right; | |||
| width: 330rpx; | |||
| width: 269rpx; | |||
| height: 95rpx; | |||
| line-height: 46rpx; | |||
| background:linear-gradient(90deg,rgba(236,59,45,1) 0%,rgba(248,98,52,1) 100%); | |||
| @@ -338,4 +338,77 @@ | |||
| font-weight:500; | |||
| color:rgba(255,53,53,1); | |||
| line-height: 44rpx; | |||
| } | |||
| .goback { | |||
| float:left; | |||
| width:122rpx!important; | |||
| height:95rpx; | |||
| background:rgba(255,255,255,1); | |||
| line-height:95rpx; | |||
| border:1rpx solid rgba(227,227,227,1); | |||
| box-shadow:0px 8px 8px 1px rgba(189,189,189,0.32); | |||
| border-radius:48rpx; | |||
| margin-right:25rpx; | |||
| } | |||
| .goback image{ | |||
| position:absolute; | |||
| width:60rpx; | |||
| left:0; | |||
| right:0; | |||
| top:0; | |||
| bottom:0; | |||
| margin:auto; | |||
| height: 80rpx; | |||
| } | |||
| .rest { | |||
| font-size: 24rpx; | |||
| color: #919191; | |||
| letter-spacing: 0; | |||
| height: 70rpx; | |||
| line-height: 70rpx; | |||
| /* border-bottom: 1px solid #eee; */ | |||
| border-bottom: 1px solid #f9f9f9; | |||
| } | |||
| .restNum { | |||
| font-size: 24rpx; | |||
| color: #999; | |||
| letter-spacing: 1.16rpx; | |||
| text-align: right; | |||
| } | |||
| .time { | |||
| font-size: 24rpx; | |||
| color: #333; | |||
| letter-spacing: 0; | |||
| line-height: 33rpx; | |||
| display: inline-block; | |||
| } | |||
| .txt01 { | |||
| font-size: 24rpx; | |||
| color: #919191; | |||
| letter-spacing: 0; | |||
| } | |||
| .times { | |||
| display: inline-block; | |||
| color: #ff4949; | |||
| font-weight: bold; | |||
| font-size: 26rpx; | |||
| text-align: center; | |||
| } | |||
| .times text { | |||
| display: inline-block; | |||
| margin: 6rpx; | |||
| width: 46rpx; | |||
| height: 56rpx; | |||
| text-align: center; | |||
| font-size: 28rpx; | |||
| line-height: 60rpx; | |||
| border-radius: 12rpx; | |||
| color: #fff; | |||
| font-weight: bold; | |||
| background: #ff4949; | |||
| } | |||
| @@ -232,14 +232,16 @@ Page({ | |||
| * 页面相关事件处理函数--监听用户下拉动作 | |||
| */ | |||
| onPullDownRefresh: function () { | |||
| this.getUserInfo() | |||
| this.getDetail(this.data.paramData); | |||
| this.checkUser(this.data.paramData) | |||
| }, | |||
| /** | |||
| * 页面上拉触底事件的处理函数 | |||
| */ | |||
| onReachBottom: function () { | |||
| }, | |||
| /** | |||
| * 用户点击右上角分享 | |||
| @@ -1,5 +1,6 @@ | |||
| { | |||
| "navigationBarTitleText": "拼团详情", | |||
| "usingComponents": {}, | |||
| "navigationBarBackgroundColor": "#F13C42" | |||
| "navigationBarBackgroundColor": "#F13C42", | |||
| "enablePullDownRefresh": true | |||
| } | |||
| @@ -7,6 +7,9 @@ page { | |||
| background-size: cover; | |||
| background-repeat: no-repeat; | |||
| } | |||
| .container{ | |||
| margin-bottom:40rpx; | |||
| } | |||
| .status{ | |||
| width: 690rpx; | |||
| padding:0 28rpx; | |||
| @@ -2,6 +2,7 @@ | |||
| var config = require("../../../config/config.js"); | |||
| const Http = require("../../../utils/HttpBasics"); | |||
| const imgurl = require("../../../utils/imgurl"); | |||
| const utils = require("../../../utils/util.js") | |||
| Page({ | |||
| /** | |||
| @@ -152,7 +153,9 @@ Page({ | |||
| }).then(res => { | |||
| let data = res.data; | |||
| data.price = (data.price / 100).toFixed(2) | |||
| data.salePrice = (data.salePrice / 100).toFixed(2) | |||
| data.salePrice = (data.salePrice / 100).toFixed(2); | |||
| data.validStartDate = utils.formatTime(data.validStartDate,'yyyy-MM-dd') | |||
| data.validEndDate = utils.formatTime(data.validEndDate, 'yyyy-MM-dd') | |||
| that.setData({ | |||
| data | |||
| }); | |||
| @@ -187,6 +190,7 @@ Page({ | |||
| * 支付订单更新 | |||
| */ | |||
| payOrderUpdate: (orderId, payOrderId, status, reason, _this, orderGroupId) => { | |||
| console.log(orderGroupId,7777) | |||
| let that = this; | |||
| // 支付成功 | |||
| Http.post({ | |||
| @@ -200,7 +204,13 @@ Page({ | |||
| }) | |||
| .then(res => { | |||
| wx.hideLoading() | |||
| _this.goToOrderGroup(orderId, res.data.orderGroupId, _this) | |||
| if (!orderGroupId){ | |||
| wx.navigateTo({ | |||
| url: '/pages/order/detail/index?orderId='+res.data.id, | |||
| }) | |||
| }else{ | |||
| _this.goToOrderGroup(orderId, res.data.orderGroupId, _this) | |||
| } | |||
| }) | |||
| .catch(err => { | |||
| console.log(err); | |||
| @@ -10,6 +10,15 @@ | |||
| <view class='des-peoplenum'>【拼团购】{{data.pressLimitNum}}人拼团成功,单价仅需</view> | |||
| <view class='des-saleprice'>{{data.salePriceStr}}元</view> | |||
| </view> | |||
| <view class='rest' wx:if="{{data.validType==1}}">有效期: | |||
| <text class='time'>{{data.validStartDate}}至{{data.validEndDate}}<text class="use">(请在有效期内使用)</text></text> | |||
| </view> | |||
| <view class='rest'> | |||
| <text class='txt01'>限购条件:</text> | |||
| <text class='time'>每人{{data.useLimitQuantity}}张</text> | |||
| <text class='times' style='margin-left:10rpx;' wx:if="{{data.autoRefund == 0}}">(支持过期自动退款)</text> | |||
| <text class='times' style='margin-left:10rpx;' wx:if="{{data.autoRefund == 1}}">(不支持过期自动退款)</text> | |||
| </view> | |||
| <view class='status' wx:if="{{spellData!=null}}"> | |||
| <view class='status01 st'> | |||
| <image src='{{spellData.avatarUrl}}'></image> | |||
| @@ -25,7 +34,7 @@ | |||
| </view> | |||
| </view> | |||
| <view class='p-des'> | |||
| <view class='p-title'>商品详情:</view> | |||
| <view class='p-title'>购买须知:</view> | |||
| <view class='p-list'>{{data.remark}}</view> | |||
| </view> | |||
| <view class='posi'> | |||
| @@ -316,4 +316,56 @@ | |||
| margin: auto; | |||
| width: 50rpx; | |||
| height: 50rpx; | |||
| } | |||
| .rest { | |||
| font-size: 24rpx; | |||
| color: #919191; | |||
| letter-spacing: 0; | |||
| height: 70rpx; | |||
| line-height: 70rpx; | |||
| /* border-bottom: 1px solid #eee; */ | |||
| border-bottom: 1px solid #f9f9f9; | |||
| } | |||
| .restNum { | |||
| font-size: 24rpx; | |||
| color: #999; | |||
| letter-spacing: 1.16rpx; | |||
| text-align: right; | |||
| } | |||
| .time { | |||
| font-size: 24rpx; | |||
| color: #333; | |||
| letter-spacing: 0; | |||
| line-height: 33rpx; | |||
| display: inline-block; | |||
| } | |||
| .txt01 { | |||
| font-size: 24rpx; | |||
| color: #919191; | |||
| letter-spacing: 0; | |||
| } | |||
| .times { | |||
| display: inline-block; | |||
| color: #ff4949; | |||
| font-weight: bold; | |||
| font-size: 26rpx; | |||
| text-align: center; | |||
| } | |||
| .times text { | |||
| display: inline-block; | |||
| margin: 6rpx; | |||
| width: 46rpx; | |||
| height: 56rpx; | |||
| text-align: center; | |||
| font-size: 28rpx; | |||
| line-height: 60rpx; | |||
| border-radius: 12rpx; | |||
| color: #fff; | |||
| font-weight: bold; | |||
| background: #ff4949; | |||
| } | |||