diff --git a/pages/order/components/coupon/index.js b/pages/order/components/coupon/index.js
index 07c12e9..883a94b 100644
--- a/pages/order/components/coupon/index.js
+++ b/pages/order/components/coupon/index.js
@@ -26,11 +26,7 @@ Component({
})
}
}
- },
- sourceFrom: {
- type:String,
- value:""
- },
+ }
},
/**
@@ -67,45 +63,9 @@ Component({
})
this.triggerEvent('getNewCoupon',null);
}else{
- let postList = app.globalData.postProduct || []
- let ticketList = app.globalData.list || []
- let signleProduct = app.globalData.product || null
-
- let listData = []
- if (this.properties.sourceFrom == 'cart') {
- ticketList.forEach(v=>{
- listData.push({
- sku_id: v.sku.id,
- price: v.sku.price,
- sell_price: v.sku.price,
- num: v.num,
- use_date: v.time&&v.time.sale_date?v.time.sale_date:''
- })
- })
- } else {
- if (signleProduct) {
- listData.push({
- sku_id: signleProduct.sku.id,
- price: signleProduct.sku.price,
- sell_price: signleProduct.sku.price,
- num: signleProduct.productNum,
- use_date: signleProduct.date&&signleProduct.date.date?signleProduct.date.date:''
- })
- }
- }
- postList.forEach(v=>{
- listData.push({
- sku_id: v.sku.id,
- price: v.sku.price,
- sell_price: v.sku.price,
- num: v.productNum,
- })
- })
-
- commonApi.user_post('coupon/use_max_coupon_listv2',{
+ commonApi.user_post('coupon/use_max_coupon_list',{
money:this.data.money,
- sku_ids:this.data.sku,
- cart_data: listData
+ sku_ids:this.data.sku
}).then(res=>{
if (app.globalData.couponInfo&&app.globalData.couponInfo.hasOwnProperty('SubCoupon')) {
this.setData({
diff --git a/pages/order/coupon/index.wxml b/pages/order/coupon/index.wxml
index d164d7a..7bca12b 100644
--- a/pages/order/coupon/index.wxml
+++ b/pages/order/coupon/index.wxml
@@ -1,55 +1,20 @@
-
-可使用红包 {{list.length}}张
-
-
- {{item.activity.money/100}}
-
- {{item.activity.fold}}
-
-
- {{item.activity.name}}
- {{item.end_time}}到期
-
-
- 不可用
-
+
+
+ {{item.activity.money/100}}
+
+ {{item.activity.fold}}
-
- 不可用原因
- {{item.reason}}
+
+ {{item.activity.name}}
+ {{item.end_time}}到期
-
-
-不可使用红包 {{noUseList.length}}张
-
-
- {{item.activity.money/100}}
-
- {{item.activity.fold}}
-
-
- {{item.activity.name}}
- {{item.end_time}}到期
-
-
- 不可用
-
-
-
-
- 不可用原因
- {{item.reason}}
-
-
-
-
-
-
+
+
确定
-
+
暂无优惠券
\ No newline at end of file
diff --git a/pages/order/coupon/index.wxss b/pages/order/coupon/index.wxss
index e76b95a..a8cfad0 100644
--- a/pages/order/coupon/index.wxss
+++ b/pages/order/coupon/index.wxss
@@ -2,27 +2,20 @@
page {
background: #f6f6f6;
}
-.coupon-item-box{
- width: 700rpx;
- margin: 26rpx auto;
- background: white;
- border-radius: 7rpx;
- box-sizing: border-box;
- padding:0 26rpx;
-}
-
.coupon-item {
- width: 100%;
display: flex;
align-items: center;
justify-content: space-between;
- position: relative;
+ margin: 26rpx;
+ background: white;
+ border-radius: 7rpx;
height: 136rpx;
+ padding-right: 27rpx;
}
.coupon-item .money {
color: #D62828;
font-size: 67rpx;
- width: 147rpx;
+ width: 187rpx;
text-align: center;
font-weight: 500;
flex-shrink: 0;
@@ -75,30 +68,4 @@ page {
font-size: 36rpx;
font-weight: 500;
text-align: center;
-}
-
-.no-reason{
- width: 100%;
- border-top: 1px dashed #e0e0e0;
- padding: 20rpx 0;
- color: #666;
- font-size: 24rpx;
- box-sizing: border-box;
-}
-
-.cover-no-use{
- position: absolute;
- top: 0;
- left: 0;
- bottom: 0;
- right: 0;
- width: 100%;
- height: 100;
- opacity: 0.5;
- background: white;
-}
-.coupon-title{
- padding: 26rpx 26rpx 0;
- width: 100%;
- box-sizing: border-box;
}
\ No newline at end of file