From 68b01da91442fafce48d822c0dfb677120b7fab5 Mon Sep 17 00:00:00 2001 From: F5VT98DI7XY4X12\Administrator <765199919@qq.com> Date: Wed, 11 Sep 2019 11:37:47 +0800 Subject: [PATCH] 购物车修改使用优惠券, 修改秒杀的分享 --- images/share/miao_share.png | Bin 0 -> 14342 bytes pages/cart/cart2/cart2.js | 22 +++++++++++++--------- pages/cart/cart2/cart2.wxss | 10 +++++----- pages/goods/goodsInfo/goodsInfo.js | 23 +++++++++++++++++++++-- 4 files changed, 39 insertions(+), 16 deletions(-) create mode 100644 images/share/miao_share.png diff --git a/images/share/miao_share.png b/images/share/miao_share.png new file mode 100644 index 0000000..f788197 Binary files /dev/null and b/images/share/miao_share.png differ diff --git a/pages/cart/cart2/cart2.js b/pages/cart/cart2/cart2.js index 3551374..7e1bcb8 100644 --- a/pages/cart/cart2/cart2.js +++ b/pages/cart/cart2/cart2.js @@ -940,15 +940,19 @@ Page({ a.post("/api/weshop/order/pay/createOrder", { data: dd, success: function (t) { - console.log(t); - //app.showWarning("支付成功"); - app.my_warnning("支付成功",1,th); - setTimeout(function () { - th.setData({ isclose: 0 }); - wx.navigateTo({ - url: "/pages/user/order_list/order_list" - }) - }, 1000) + //console.log(t); + if(t.data.code==0){ + app.my_warnning("支付成功",1,th); + setTimeout(function () { + th.setData({ isclose: 0 }); + wx.navigateTo({ + url: "/pages/user/order_list/order_list" + }) + }, 1000) + } + }, + fail:function () { + } }); } diff --git a/pages/cart/cart2/cart2.wxss b/pages/cart/cart2/cart2.wxss index 2342af3..f1710ad 100644 --- a/pages/cart/cart2/cart2.wxss +++ b/pages/cart/cart2/cart2.wxss @@ -279,7 +279,7 @@ border-bottom:1px solid #ddd; } .xc-coupon-frame .work-frame{ - width: 92%; + width: 94%; height: 100%; } @@ -294,7 +294,7 @@ } .xc-coupon-frame .work-frame .work{ font-size: 30rpx; line-height: 92rpx; color: #d81e06;} -.xc-right-frame{font-size: 30rpx;line-height: 92rpx; } +.xc-right-frame{font-size: 30rpx;line-height: 92rpx; margin-right: 10rpx } /* 自定义弹出窗口 */ .cx-popup{ @@ -345,7 +345,6 @@ .xc-close-frame{ margin-top:10rpx; width:1%; - display:flex; } .xc-close{ @@ -354,8 +353,9 @@ height: 46rpx; border-radius: 50%; border: 5rpx solid #a5a5a7; text-align: center; -line-height: 33rpx; -font-size: 64rpx; +line-height: 46rpx; +font-size: 34rpx; +font-weight: bolder; color: #a5a5a7; margin-top: 5rpx; diff --git a/pages/goods/goodsInfo/goodsInfo.js b/pages/goods/goodsInfo/goodsInfo.js index d3cb742..2c273f7 100644 --- a/pages/goods/goodsInfo/goodsInfo.js +++ b/pages/goods/goodsInfo/goodsInfo.js @@ -144,7 +144,7 @@ Page({ pd_xx: 0, is_normal: 0, //是否普通购买 teamgroup:null, //有多少人开团 - grounp_tatal:0, //有几个人开团 + grounp_tatal:0, //有几个人开团 timer:[], //商品的购买次数 @@ -2282,7 +2282,6 @@ Page({ //-------大图后面就不一样了----------- switch (type) { case 0: //普通商品的展示 - case 1: //秒杀商品的展示 //中间的几个字 var g_path = "../../../images/share/s_gou.png"; context.drawImage(g_path, 56 * unit, 670 * unit, 22 * unit, 22 * unit); @@ -2312,6 +2311,26 @@ Page({ //---二维吗图--- context.drawImage(vpath, 380 * unit, 736 * unit, 120 * unit, 120 * unit); break; + case 1: //秒杀商品的展示 + //---画线--- + context.setLineWidth(1 * unit) + context.moveTo(32 * unit, 670 * unit) + context.lineTo(520 * unit, 670 * unit) + context.stroke(); + + //画秒杀的图片 + var miaos_path='../../../images/share/miao_share.png'; + context.drawImage(miaos_path, 43 * unit, 700 * unit, 222 * unit, 40 * unit); + + //---文字--- + context.setFontSize(22 * unit) + context.setFillStyle("black") + context.fillText("特惠好物,限时秒杀", 40 * unit, 806 * unit); + context.fillText("长按识别二维码,立即开始抢购", 40 * unit, 846 * unit); + //---二维吗图--- + context.drawImage(vpath, 380 * unit, 736 * unit, 120 * unit, 120 * unit); + break; + case 2://会员团和商家团的展示 //---画线--- context.setLineWidth(1 * unit) -- libgit2 0.21.4