瀏覽代碼

拼团详情作废券处理

tags/富茂链客4.1.0
刘晖 6 年之前
父節點
當前提交
1c979fddfd
共有 4 個文件被更改,包括 85 次插入4 次删除
  1. +20
    -1
      pages/spellDetail/index.js
  2. +13
    -3
      pages/spellDetail/index.wxml
  3. +48
    -0
      pages/spellDetail/index.wxss
  4. +4
    -0
      utils/imgurl.js

+ 20
- 1
pages/spellDetail/index.js 查看文件

@@ -12,6 +12,7 @@ Page({
tuanzhang: imgurl.tuanzhang.url,
spellBg: imgurl.spellBg.url,
position: imgurl.position.url,
close03: imgurl.close03.url,
paramData:null,
data:null,
clock: "00",
@@ -20,7 +21,8 @@ Page({
min: "00",
sec: "00",
spellStatusList: spellStatus,
isMyself:false
isMyself:false,
showAlert:false
},
gotoAgain(){
let data = this.data.data;
@@ -133,6 +135,18 @@ Page({
that.countdown(end_time);
}, 1000)
},
//关闭弹框
gotoClose(){
this.setData({
showAlert:false
})
},
//跳转拼团列表
gotoSpellList(){
wx.navigateTo({
url: '/pages/spellGroup/spellGroup',
})
},
getDetail(){
let that = this;
Http.get({
@@ -154,6 +168,11 @@ Page({
let a={};
data.userList.push(a)
}
if (res.data.couponStatus!=0){
that.setData({
showAlert: true
})
}
that.setData({
data:res.data
})


+ 13
- 3
pages/spellDetail/index.wxml 查看文件

@@ -112,8 +112,18 @@
</view>
</view>
<view class='edit'>
<button class='share user-motto' wx:if="{{data.status==10&&isMyself==true}}" id="shareBtn" open-type="share">邀请好友拼团</button>
<button class='share user-motto' wx:if="{{data.status==12||data.status==13}}" bindtap='gotoAgain'>重新拼团</button>
<button class='share user-motto' wx:if="{{data.status==11&&isMyself==true}}" bindtap='gotoUse'>去使用</button>
<button class='share user-motto' wx:if="{{data.status==10&&isMyself==true&&data.couponStatus==0}}" id="shareBtn" open-type="share">邀请好友拼团</button>
<button class='share user-motto' wx:if="{{data.status==12||data.status==13&&data.couponStatus==0}}" bindtap='gotoAgain'>重新拼团</button>
<button class='share user-motto' wx:if="{{data.status==11&&isMyself==true&&data.couponStatus==0}}" bindtap='gotoUse'>去使用</button>
</view>
<view class='alert-bg' wx:if='{{showAlert}}' bindtap='gotoClose'></view>
<view class='alert-box' wx:if='{{showAlert}}'>
<view class='alert-close' bindtap='gotoClose'>
<image src='{{close03}}'></image>
</view>
<view class='alert-title'>商品已下架</view>
<view class='alert-button'>
<button class='share user-motto' bindtap='gotoSpellList'>更多拼团商品</button>
</view>
</view>
</view>

+ 48
- 0
pages/spellDetail/index.wxss 查看文件

@@ -292,4 +292,52 @@ page {
border-radius:47rpx;
color:#333333;
margin-bottom: 50rpx;
}
.alert-bg{
width: 100%;
height: 100vh;
position: fixed;
opacity: 0.7;
background: #000;
top: 0;
left: 0;
z-index: 200;
}
.alert-box{
width: 600rpx;
height: 332rpx;
position: fixed;
z-index: 300;
background: #fff;
top: 50vh;
margin-top: -162rpx;
left: 85rpx;
border-radius:15rpx;
}
.alert-close{
position: absolute;
width: 47rpx;
height: 98rpx;
top: -98rpx;
right: 0;
}
.alert-close image{
width: 47rpx;
height: 98rpx;
}
.alert-title{
text-align: center;
font-size:30rpx;
line-height: 30rpx;
margin-top: 79rpx;
font-family:PingFang-SC-Medium;
font-weight:500;
color:rgba(51,51,51,1);
}
.alert-button .share{
width:500rpx;
height:95rpx;
background:linear-gradient(90deg,rgba(248,85,45,1) 0%,rgba(241,60,66,1) 0%,rgba(248,86,46,1) 100%);
border-radius:47rpx;
margin-top: 79rpx;
}

+ 4
- 0
utils/imgurl.js 查看文件

@@ -376,4 +376,8 @@ module.exports = {
'url': baseUrl + 'position.png',
'name': '地理位置图标'
},
'close03': {
'url': baseUrl + 'close03.png',
'name': '拼团页面关闭图标'
},
}

Loading…
取消
儲存