diff --git a/app.json b/app.json
index d3bfb6a..3b04385 100644
--- a/app.json
+++ b/app.json
@@ -4,6 +4,7 @@
"pages/show_product/show_product",
"pages/address/address",
"pages/cart/cart",
+ "pages/cart/coupon",
"pages/mine/mine",
"pages/category/category",
"pages/my_assets/show"
diff --git a/pages/cart/cart.js b/pages/cart/cart.js
index 22cf9f0..5115efe 100644
--- a/pages/cart/cart.js
+++ b/pages/cart/cart.js
@@ -33,6 +33,12 @@ Page({
this.setData({address: address})
},
+ bindSelectCoupon: function() {
+ wx.navigateTo({
+ url: `coupon`
+ })
+ },
+
bindChangeQuantity: function (e) {
var cartItems = this.data.cartItems
var item = cartItems.filter(function(ele){
diff --git a/pages/cart/cart.wxml b/pages/cart/cart.wxml
index 67e7629..c954eca 100644
--- a/pages/cart/cart.wxml
+++ b/pages/cart/cart.wxml
@@ -14,7 +14,13 @@
+
+
+ 使用优惠券
+
+
+
diff --git a/pages/cart/cart.wxss b/pages/cart/cart.wxss
index 8658d4f..cd431ed 100644
--- a/pages/cart/cart.wxss
+++ b/pages/cart/cart.wxss
@@ -5,7 +5,6 @@
.address-container {
margin: 15rpx;
padding-bottom: 10rpx;
- border-bottom: 1px solid #e4e4e4;
}
.receiver {
@@ -111,4 +110,9 @@
.quantity input {
min-height: 10rpx;
height: 50rpx;
+}
+
+.separate {
+ height: 18rpx;
+ background-color: #f2f2f2;
}
\ No newline at end of file
diff --git a/pages/cart/coupon.js b/pages/cart/coupon.js
new file mode 100644
index 0000000..0e8c5a2
--- /dev/null
+++ b/pages/cart/coupon.js
@@ -0,0 +1,26 @@
+Page({
+ data: {
+
+ },
+
+ onShow: function() {
+ },
+
+ onLoad: function() {
+ this.getCoupon()
+ },
+
+ getCoupon: function() {
+ wx.request({
+ url: `${getApp().globalData.API_URL}/coupons`,
+ data: {},
+ method: 'GET',
+ success: function(res){
+ },
+ fail: function() {
+ },
+ complete: function() {
+ }
+ })
+ }
+})
\ No newline at end of file
diff --git a/pages/cart/coupon.json b/pages/cart/coupon.json
new file mode 100644
index 0000000..08f4c91
--- /dev/null
+++ b/pages/cart/coupon.json
@@ -0,0 +1,3 @@
+{
+ "navigationBarTitleText": "我的优惠券"
+}
\ No newline at end of file
diff --git a/pages/cart/coupon.wxml b/pages/cart/coupon.wxml
new file mode 100644
index 0000000..e69de29
diff --git a/pages/cart/coupon.wxss b/pages/cart/coupon.wxss
new file mode 100644
index 0000000..e69de29