From 22915517347e3efca047856946700a036dc5f6fa Mon Sep 17 00:00:00 2001 From: yangsanTT <812952667@qq.com> Date: Sun, 15 Aug 2021 20:45:00 +0800 Subject: [PATCH] =?UTF-8?q?1.=E4=BF=AE=E6=94=B9=E9=A1=B5=E9=9D=A2=E6=A0=B7?= =?UTF-8?q?=E5=BC=8F=202.=E6=96=B0=E5=A2=9E=E4=BF=AE=E6=94=B9=E5=AF=86?= =?UTF-8?q?=E7=A0=81=EF=BC=8C=E8=AE=BE=E7=BD=AE=E5=AF=86=E7=A0=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Utils/Api.js | 14 +- components/sanshui-modal/index.vue | 224 ++++++ components/sanshui-payment-password/index.vue | 639 ++++++++++++++++ components/wyb-popup/wyb-popup.vue | 2 +- pages.json | 25 + pages/goods/coupon-details/coupon-details.vue | 66 +- pages/goods/goods-list/goods-list.vue | 4 +- pages/goods/goods.vue | 228 +++--- pages/goods/recording/recording.vue | 2 +- pages/goods/refuel/refuel.vue | 28 - pages/goods/store-list/store-details.vue | 222 +++--- pages/login/updatePas/resetPas.vue | 103 +++ pages/login/updatePas/updatePas.vue | 90 +++ pages/order/confirmation.vue | 693 +++++++++++------- pages/pay/payment/payment.vue | 145 ++-- pages/pay/success/success.vue | 73 +- pages/tabBar/home/home.vue | 10 +- pages/tabBar/user/user.vue | 30 +- pages/user/coupon/coupon.vue | 6 +- pages/user/mineCoupons/mineCoupons.vue | 6 +- .../mineCouponsDestails.vue | 4 +- pages/user/order_details/order_details.vue | 54 +- pages/user/order_list/order_list.vue | 45 +- static/img/jt.png | Bin 0 -> 824 bytes static/img/pas.png | Bin 0 -> 1081 bytes uni.scss | 18 + 26 files changed, 2036 insertions(+), 695 deletions(-) create mode 100644 components/sanshui-modal/index.vue create mode 100644 components/sanshui-payment-password/index.vue create mode 100644 pages/login/updatePas/resetPas.vue create mode 100644 pages/login/updatePas/updatePas.vue create mode 100644 static/img/jt.png create mode 100644 static/img/pas.png diff --git a/Utils/Api.js b/Utils/Api.js index dfbf883..daba217 100644 --- a/Utils/Api.js +++ b/Utils/Api.js @@ -17,7 +17,15 @@ export const GetPhoneNumber = params => { //获取用户授权信息 export const getUserInfo = params => { return POST('GET', `${base}/wechat/getUserInfo`, params).then(res => res.data); -} +} +// 设置用户积分支付密码 +export const setUserPayPwd = params => { + return POST('POST', `${base}/highUser/setUserPayPwd`, params).then(res => res.data); +} +// 修改用户积分支付密码 +export const updateUserPayPwd = params => { + return POST('POST', `${base}/highUser/updateUserPayPwd`, params).then(res => res.data); +} //获取用户信息 export const findUser = params => { @@ -59,11 +67,11 @@ export const addOrder = params => { export const orderToPay = params => { return POST('POST', `${base}/order/orderToPay`, params).then(res => res.data); } -//金币支付 +//积分支付 export const orderToGoldPay = params => { return POST('POST', `${base}/order/orderToGoldPay`, params).then(res => res.data); } -//查询用户金币使用情况 +//查询用户积分使用情况 export const getUserGoldRecList = params => { return POST('GET', `${base}/highGoldRec/getUserGoldRecList`, params).then(res => res.data); } diff --git a/components/sanshui-modal/index.vue b/components/sanshui-modal/index.vue new file mode 100644 index 0000000..0837d1e --- /dev/null +++ b/components/sanshui-modal/index.vue @@ -0,0 +1,224 @@ + + + + + diff --git a/components/sanshui-payment-password/index.vue b/components/sanshui-payment-password/index.vue new file mode 100644 index 0000000..aa08a71 --- /dev/null +++ b/components/sanshui-payment-password/index.vue @@ -0,0 +1,639 @@ + + + + + diff --git a/components/wyb-popup/wyb-popup.vue b/components/wyb-popup/wyb-popup.vue index 2ca14fa..f93c12a 100644 --- a/components/wyb-popup/wyb-popup.vue +++ b/components/wyb-popup/wyb-popup.vue @@ -147,7 +147,7 @@ if (this.type === 'left' || this.type === 'right') { return '100%' } else { - return 'auto' + return '400px' } } } diff --git a/pages.json b/pages.json index 57f05d8..7077c2f 100644 --- a/pages.json +++ b/pages.json @@ -175,6 +175,7 @@ "navigationBarTitleText": "", "navigationBarBackgroundColor": "#0083f5", "backgroundColorTop": "#0083f5", + "navigationBarTitleText": "详情", "navigationBarTextStyle": "white", "onReachBottomDistance": 50, "h5": { @@ -439,6 +440,30 @@ } } + ,{ + "path" : "pages/login/updatePas/updatePas", + "style" : + { + "enablePullDownRefresh": false, + "navigationBarTitleText": "设置密码", + "backgroundTextStyle": "light", + "navigationBarBackgroundColor": "#0083f5", + "backgroundColorTop": "#0083f5", + "navigationBarTextStyle": "white" + } + } ,{ + "path" : "pages/login/updatePas/resetPas", + "style" : + { + "enablePullDownRefresh": false, + "navigationBarTitleText": "修改密码", + "backgroundTextStyle": "light", + "navigationBarBackgroundColor": "#0083f5", + "backgroundColorTop": "#0083f5", + "navigationBarTextStyle": "white" + } + + } ], "globalStyle": { diff --git a/pages/goods/coupon-details/coupon-details.vue b/pages/goods/coupon-details/coupon-details.vue index 9e444d0..161d8b2 100644 --- a/pages/goods/coupon-details/coupon-details.vue +++ b/pages/goods/coupon-details/coupon-details.vue @@ -2,34 +2,60 @@ - + 已使用 未使用 已过期 + {{couponDesInfo.couponInfo.couponName}} + 领取时间:{{oneTime | formatDate('-')}} + 使用有效期:{{twoTime | formatDate('-')}} + 消费时间:{{threeTime | formatDate('-')}} - {{couponDesInfo.couponInfo.couponName}} - 领取时间:{{oneTime | formatDate('-')}} - 使用有效期:{{twoTime | formatDate('-')}} - 消费时间:{{threeTime | formatDate('-')}} + - + + + 使用流程: + + + 1: + 客户使用积分兑换或者工会卡购买。 + + + 2: + 兑换成功后中石化给客户发送一张同等面额的码商券,保存在”加油中石化“APP中。 + + + 3: + 客户登录”加油中石化“APP,查看码商券详情。 + + + 4: + 客户选择中石化任意加油站加油,加完油后,在加油中石化“APP中查看订单,选择支付,支付时选择码商券抵用。支付完成即可。 + + + 请出示核销码(商户扫客户) - + - {{couponDesInfo.couponCodeInfo.codeKey}} + {{couponDesInfo.couponCodeInfo.codeKey}} - - 门店信息 + + + 门店信息 + {{store.storeName}} - {{store.address}} + {{store.address}} @@ -39,8 +65,8 @@ - + @@ -71,7 +97,6 @@ this.couDesId = option.id; this.menddesId = option.mendId; this.getUserCouponDetail(); - this.getStoreListByCoupon(); }, filters: { //过滤器 用于格式化时间 @@ -106,10 +131,17 @@ getUserCouponDetail(params).then(res => { if (res.return_code == '000000') { this.couponDesInfo = res.return_data; + uni.hideLoading(); + if (res.return_data.couponInfo.couponSource == 4) { + this.oneTime = res.return_data.highUserCoupon.createTime; + this.twoTime = res.return_data.highUserCoupon.useEndTime; + this.threeTime = res.return_data.highUserCoupon.consumeTime; + return; + } + this.getStoreListByCoupon(); this.oneTime = res.return_data.highUserCoupon.createTime; this.twoTime = res.return_data.highUserCoupon.useEndTime; this.threeTime = res.return_data.highUserCoupon.consumeTime; - uni.hideLoading() } else { uni.hideLoading() } @@ -209,7 +241,7 @@ } .couhedcout { - margin-left: 200rpx; + margin-left: 210rpx; } .couStu { @@ -235,7 +267,7 @@ .stoCont { border-bottom: 1px solid #f6f6f6; - height: 170rpx; + height: 160rpx; } .loading-text { diff --git a/pages/goods/goods-list/goods-list.vue b/pages/goods/goods-list/goods-list.vue index bacd07b..214b917 100644 --- a/pages/goods/goods-list/goods-list.vue +++ b/pages/goods/goods-list/goods-list.vue @@ -23,7 +23,7 @@ - + {{row.couponName}} 限购{{row.limitNumber}}件 @@ -93,7 +93,7 @@ } if (option.id == 2) { uni.setNavigationBarTitle({ - title: '金币列表' + title: '积分列表' }); } this.getCouponListArea(); diff --git a/pages/goods/goods.vue b/pages/goods/goods.vue index c75fb9a..8e9de05 100644 --- a/pages/goods/goods.vue +++ b/pages/goods/goods.vue @@ -24,7 +24,7 @@ - + {{currentSwiper+1}}/{{swiperList.length}} @@ -54,42 +54,18 @@ - {{goodsData[0].couponName}} 有效期至: {{goodsData[0].salesEndTime | formatDate('-')}} - 库存 : {{goodsData[0].stockCount}}件 - - - - + - + + + + 赠送卡券 + + + + @@ -126,6 +110,37 @@ + + 赠送卡券 + + + + + {{ product.highCouponModel.couponName }} + 有效期至:201-05-15 22:59:59(待改) + + ¥{{ product.highCouponModel.discountPrice}} + + ¥{{ product.highCouponModel.salesPrice}} + + + + + {{ product.highCouponModel.discountPrice*100}} + + + + {{ product.highCouponModel.salesPrice*100}} + + + + + @@ -137,10 +152,12 @@ getUserInfo } from "../../Utils/Api.js"; import authorize from '../../components/Authorize.vue' + import wybPopup from '../../components/wyb-popup/wyb-popup.vue'; let app = getApp() export default { components: { - authorize + authorize, + wybPopup }, data() { return { @@ -204,18 +221,7 @@ onReady() { // this.calcAnchor(); //计算锚点高度,页面数据是ajax加载时,请把此行放在数据渲染完成事件中执行以保证高度计算正确 }, - onPageScroll(e) { - //锚点切换 - // this.selectAnchor = e.scrollTop >= this.anchorlist[2].top ? 2 : e.scrollTop >= this.anchorlist[1].top ? 1 : 0; - //导航栏渐变 - // let tmpY = 375; - // e.scrollTop = e.scrollTop > tmpY ? 375 : e.scrollTop; - // this.afterHeaderOpacity = e.scrollTop * (1 / tmpY); - // this.beforeHeaderOpacity = 1 - this.afterHeaderOpacity; - //切换层级 - // this.beforeHeaderzIndex = e.scrollTop > 0 ? 10 : 11; - // this.afterHeaderzIndex = e.scrollTop > 0 ? 11 : 10; - }, + onPageScroll(e) {}, //上拉加载,需要自己在page.json文件中配置"onReachBottomDistance" onReachBottom() { // uni.showToast({ title: '触发上拉加载' }); @@ -243,6 +249,10 @@ } }) }, + //显示弹出 + showPopup() { + this.$refs.popup.show(); + }, //查看大图 perImage(item) { uni.previewImage({ @@ -299,15 +309,7 @@ }, //获取登陆信息 getuserinfo() { - // uni.showLoading({ - // title: '提交中...' - // }); let that = this; - // wx.login({ - // success(res) { - // if (res.code) { - //发起网络请求 - // var code = res.code; // 获取微信用户信息 uni.getUserProfile({ desc: '登录中...', @@ -357,37 +359,20 @@ }); } }) - // } else { - // uni.showToast({ - // title: "微信登录授权失败", - // icon: "none" - // }); - // } - // } - // }) }, buy() { let that = this; - // if (that.goodsData[0].stockCount && that.goodsData[0].couponSource == 4) { - uni.showToast({ - title: '提交订单...', - icon: 'none', - duration: 2000, - success() { - uni.navigateTo({ - url: '../order/confirmation?id=' + that.goodsData[0].id - }) - } - }) - // } else { - // uni.showToast({ - // title: '卡券数量不足', - // icon: 'none', - // duration: 2000 - // }) - // } - + uni.showToast({ + title: '提交订单...', + icon: 'none', + duration: 2000, + success() { + uni.navigateTo({ + url: '../order/confirmation?id=' + that.goodsData[0].id + }) + } + }) }, //跳转评论列表 @@ -493,55 +478,47 @@ background-color: #f8f8f8; } - .product-list { - width: 92%; - padding: 0 4% 3vw 4%; + .jtcs { + width: 40rpx; + height: 40rpx; + margin-top: 40rpx; + } + + .tccs { + box-shadow: 0rpx 0rpx 10rpx rgba(0, 0, 0, 0.2); + border: 1px solid #f6f6f6; + border-radius: 8px; + align-items: center; display: flex; - justify-content: space-between; - flex-wrap: wrap; - .product { - width: 48%; - border-radius: 20upx; - background-color: #fff; - margin: 0 0 15upx 0; - box-shadow: 0upx 5upx 25upx rgba(0, 0, 0, 0.1); + image { + width: 170rpx; + max-height: 170rpx; + } + } - image { - width: 100%; - border-radius: 20upx 20upx 0 0; - } + .tcrig { + margin-left: 20rpx; + } - .name { - width: 92%; - padding: 8upx 4%; - display: -webkit-box; - -webkit-box-orient: vertical; - -webkit-line-clamp: 1; - text-align: justify; - overflow: hidden; - font-size: 30upx; - } + .info { + display: flex; + justify-content: space-between; + align-items: flex-end; + width: 92%; - .info { - display: flex; - justify-content: space-between; - align-items: flex-end; - width: 92%; - padding: 10upx 4% 10upx 4%; - - .price { - color: #e65339; - font-size: 15px; - font-weight: 600; - } + .price { + color: #e65339; + font-size: 15px; + font-weight: 600; + display: flex; + align-items: center; + } - .slogan { - color: #807c87; - font-size: 24upx; - text-decoration: line-through; - } - } + .slogan { + color: #807c87; + font-size: 24upx; + text-decoration: line-through; } } @@ -748,16 +725,11 @@ .swiper-box { position: relative; width: 100%; - height: 100vw; - swiper { width: 100%; - height: 100vw; - swiper-item { image { width: 100%; - height: 100vw; } } } @@ -780,9 +752,9 @@ .info-box { width: 92%; - padding: 4%; - background-color: #fff; - margin-bottom: 20rpx; + padding: 4%; + background-color: #fff; + margin-bottom: 20rpx; } .goods-info { diff --git a/pages/goods/recording/recording.vue b/pages/goods/recording/recording.vue index e9f027f..e620591 100644 --- a/pages/goods/recording/recording.vue +++ b/pages/goods/recording/recording.vue @@ -8,7 +8,7 @@ - 金币充值 + 积分充值 +{{recod.gold}} diff --git a/pages/goods/refuel/refuel.vue b/pages/goods/refuel/refuel.vue index 1ca57b1..fd67420 100644 --- a/pages/goods/refuel/refuel.vue +++ b/pages/goods/refuel/refuel.vue @@ -104,34 +104,6 @@ imgadres2:'xiala.png', imgadres3:'noorder.png', menuList: [ - // { - // 'title': '品牌', - // 'key': 'single', - // 'isMutiple': false, - // 'detailTitle': '请选择(单选)', - // 'reflexTitle': true, - // 'defaultSelectedIndex': 0, - // 'detailList': [{ - // 'title': '全部品牌', - // 'value': '' - // }, { - // 'title': '中石化', - // 'value': '中石化' - // }, { - // 'title': '中石油', - // 'value': '中石油' - // }, { - // 'title': '亮牌', - // 'value': '亮牌' - // }, { - // 'title': '其他', - // 'value': '其他' - // }, - - // ] - - // }, - { 'title': '油号', 'key': 'single2', diff --git a/pages/goods/store-list/store-details.vue b/pages/goods/store-list/store-details.vue index 4995733..f55e6e8 100644 --- a/pages/goods/store-list/store-details.vue +++ b/pages/goods/store-list/store-details.vue @@ -1,52 +1,41 @@ @@ -65,23 +63,27 @@ orderToPay, orderToGoldPay } from '../../../Utils/Api.js' + import ssPaymentPassword from '../../../components/sanshui-payment-password' let app = getApp(); // #ifdef H5 var jweixin = require('jweixin-module'); // #endif export default { + components: { + ssPaymentPassword + }, data() { return { amount: 0, - orderName: '', imagewxUrl: app.globalData.imageWxImg, - imgadres:'wxpay.png', + imgadres: 'wxpay.png', pryType: '', paytype: '', //支付类型 orderNo: '', user: '', couponId: '', - jumpType:'' + jumpType: '', + PaymentPassword: '' }; }, onLoad(e) { @@ -98,26 +100,13 @@ this.paytype = '' } this.amount = parseFloat(e.amount).toFixed(2); - uni.getStorage({ - key: 'paymentOrder', - success: (e) => { - if (e.data.length > 1) { - this.orderName = '多商品合并支付' - } else { - this.orderName = e.data[0].name; - } - uni.removeStorage({ - key: 'paymentOrder' - }) - } - }) }, methods: { //获取订单数据 orderToPay() { let that = this; if (that.paytype == 'wxpay') { - + let params = { "orderId": that.orderNo, "openId": app.globalData.openId, @@ -141,7 +130,7 @@ uni.showToast({ title: '支付成功' }) - if(that.jumpType == 4){ + if (that.jumpType == 4) { uni.reLaunch({ url: '/pages/tabBar/user/user' }); @@ -171,43 +160,13 @@ } }) } else if (that.paytype == 'jinbi') { - uni.showModal({ - title: '金币支付', - content: '确认是否用金币支付?', - success: (res) => { - if (res.confirm) { - uni.showLoading({ - title: '支付中...' - }) - let params = { - "orderId": that.orderNo - } - orderToGoldPay(params).then(res => { - if (res.return_code == '000000') { - uni.hideLoading(); - uni.showToast({ - title: '支付成功' - }) - if(that.jumpType == 4){ - uni.reLaunch({ - url: '/pages/tabBar/user/user' - }); - return; - } - uni.reLaunch({ - url: '../success/success?id=' + that.couponId - }); - - } else { - uni.showToast({ - title: res.return_msg, - icon: 'none' - }) - } - }) - } else if (res.cancel) {} - } - }); + if(!that.user.isSetPayPwd){ + uni.navigateTo({ + url: '../../login/updatePas/updatePas' + }) + return; + } + that.$refs.paymentPassword.modalFun('show'); } else { uni.showToast({ title: '请选择支付方式', @@ -216,6 +175,46 @@ }) } }, + submitHandle(e) { + this.PaymentPassword = e.value; + uni.showLoading({ + title: '支付中...' + }) + let params = { + "orderId": this.orderNo, + "password": this.PaymentPassword + } + orderToGoldPay(params).then(res => { + uni.hideLoading(); + if (res.return_code == '000000') { + uni.showToast({ + title: '支付成功' + }) + if (this.jumpType == 4) { + uni.reLaunch({ + url: '/pages/tabBar/user/user' + }); + return; + } + uni.reLaunch({ + url: '../success/success?id=' + this.couponId + }); + + } + if (res.return_code == '102130') { + uni.navigateTo({ + url: '../../login/updatePas/updatePas' + }) + return; + } + + uni.showToast({ + title: res.return_msg, + icon: 'none' + }) + + }) + }, payRequest: function(self) { uni.showLoading({ title: '支付中...' @@ -232,16 +231,16 @@ jweixin.ready(function() { jweixin.checkJsApi({ jsApiList: ['chooseWXPay'], // 需要检测的JS接口列表,所有JS接口列表见附录2, - success: function(res) { - }, - fail: function(res) { - } + success: function(res) {}, + fail: function(res) {} }); jweixin.chooseWXPay({ appId: self.return_data.appId, - timestamp: self.return_data.timeStamp, // 支付签名时间戳,注意微信jssdk中的所有使用timestamp字段均为小写。但最新版的支付后台生成签名使用的timeStamp字段名需大写其中的S字符 + timestamp: self.return_data + .timeStamp, // 支付签名时间戳,注意微信jssdk中的所有使用timestamp字段均为小写。但最新版的支付后台生成签名使用的timeStamp字段名需大写其中的S字符 nonceStr: self.return_data.nonceStr, // 支付签名随机串,不长于 32 位 - package: self.return_data.package, // 统一支付接口返回的prepay_id参数值,提交格式如:prepay_id=***) + package: self.return_data + .package, // 统一支付接口返回的prepay_id参数值,提交格式如:prepay_id=***) signType: 'MD5', // 签名方式,默认为'SHA1',使用新版支付需传入'MD5' paySign: self.return_data.sign, // 支付签名 success: function(res) { @@ -249,7 +248,7 @@ uni.showToast({ title: '支付成功' }) - if(that.jumpType == 4){ + if (that.jumpType == 4) { uni.reLaunch({ url: '/pages/tabBar/user/user' }); @@ -259,10 +258,8 @@ url: '../success/success?id=' + that.couponId }); }, - cancel: function(r) { - }, - fail: function(res) { - } + cancel: function(r) {}, + fail: function(res) {} }); }); @@ -390,4 +387,4 @@ } } } - + diff --git a/pages/pay/success/success.vue b/pages/pay/success/success.vue index 7dcb664..1e33938 100644 --- a/pages/pay/success/success.vue +++ b/pages/pay/success/success.vue @@ -22,29 +22,56 @@ 消费时间:{{threeTime | formatDate('-')}} + - 核销码(商户扫客户) - 请告知加油员用码商支付 - - + + + 使用流程: + + + 1: + 客户使用积分兑换或者工会卡购买。 + + + 2: + 兑换成功后中石化给客户发送一张同等面额的码商券,保存在”加油中石化“APP中。 + + + 3: + 客户登录”加油中石化“APP,查看码商券详情。 + + + 4: + 客户选择中石化任意加油站加油,加完油后,在加油中石化“APP中查看订单,选择支付,支付时选择码商券抵用。支付完成即可。 + - - 二维码生效中,前往个人中心查看 - - - 立即
前往 + + + + 核销码(商户扫客户) + 请告知加油员用码商支付 + + + + - - - {{store.storeName}} - {{store.address}} + 二维码生效中,前往个人中心查看 + + + 立即
前往
- - - - - {{store.distance}}km + + + {{store.storeName}} + {{store.address}} + + + + + + {{store.distance}}km +
@@ -74,7 +101,6 @@ onLoad(option) { this.couDesId = option.id; this.getUserNewCouponDetail(); - this.getStoreListByCoupon(); }, filters: { //过滤器 用于格式化时间 @@ -109,6 +135,13 @@ getUserNewCouponDetail(params).then(res => { if (res.return_code == '000000') { this.couponDesInfo = res.return_data; + if(res.return_data.couponInfo.couponSource == 4){ + this.oneTime = res.return_data.highUserCoupon.createTime; + this.twoTime = res.return_data.highUserCoupon.useEndTime; + this.threeTime = res.return_data.highUserCoupon.consumeTime; + return; + } + this.getStoreListByCoupon(); this.oneTime = res.return_data.couponCodeInfo.receiveTime; this.twoTime = res.return_data.couponCodeInfo.salesEndTime; this.threeTime = res.return_data.couponCodeInfo.consumeTime; diff --git a/pages/tabBar/home/home.vue b/pages/tabBar/home/home.vue index 89ce8a8..73f352d 100644 --- a/pages/tabBar/home/home.vue +++ b/pages/tabBar/home/home.vue @@ -69,14 +69,14 @@ - {{pro.couponName}} + {{pro.couponName}} ¥{{pro.discountPrice}} - + @@ -87,7 +87,7 @@ @click="toGoods(item.id)"> - {{item.couponName}} + {{item.couponName}} {{ item.discountPrice*100}} @@ -150,7 +150,7 @@ @@ -99,6 +99,18 @@
+ + + 我的操作 + + + + + + {{row.text}} + + + @@ -195,7 +207,19 @@ // text: '充话费', // img: 'user/bank.png' // } - ] + ], + //操作列表 + czList: [{ + url: '../../login/updatePas/updatePas', + text: '设置密码', + img: '../../../static/img/pas.png' + },{ + url: '../../login/updatePas/resetPas', + text: '修改密码', + img: '../../../static/img/pas.png' + }, + + ], } }, //下拉刷新,需要自己在page.json文件中配置开启页面下拉刷新 "enablePullDownRefresh": true diff --git a/pages/user/coupon/coupon.vue b/pages/user/coupon/coupon.vue index 12c8700..8a0e244 100644 --- a/pages/user/coupon/coupon.vue +++ b/pages/user/coupon/coupon.vue @@ -12,7 +12,7 @@ - + @@ -24,7 +24,7 @@ {{row.highDiscount.discountName}} - 截止时间:{{row.highDiscount.salesEndTime | formatDate('-')}} + 截止时间:{{row.useEndTime | formatDate('-')}} @@ -41,7 +41,7 @@ {{row.highDiscount.discountName}} - + 去使用 diff --git a/pages/user/mineCoupons/mineCoupons.vue b/pages/user/mineCoupons/mineCoupons.vue index 74959e1..1d9c734 100644 --- a/pages/user/mineCoupons/mineCoupons.vue +++ b/pages/user/mineCoupons/mineCoupons.vue @@ -13,7 +13,7 @@ - + {{ product.highCouponModel.couponName }} @@ -85,7 +85,7 @@ h = h >= 10 ? h : "0" + h; mm = mm >= 10 ? mm : "0" + mm; s = s >= 10 ? s : "0" + s; - return `${year}${spe}${month}${spe}${day} ${h}:${mm}:${s}`; + return `${year}${spe}${month}${spe}${day}`; } }, onLoad() { @@ -218,7 +218,7 @@ } .headconts { - margin-left: 210rpx; + margin-left: 220rpx; } .info { diff --git a/pages/user/mineCouponsDestails/mineCouponsDestails.vue b/pages/user/mineCouponsDestails/mineCouponsDestails.vue index 539ee8b..e6053db 100644 --- a/pages/user/mineCouponsDestails/mineCouponsDestails.vue +++ b/pages/user/mineCouponsDestails/mineCouponsDestails.vue @@ -7,7 +7,7 @@ {{couponsDetails.highDiscount.discountName}} - 活动截止时间:{{salesEndTime | formatDate('-')}} + 使用截止时间:{{salesEndTime | formatDate('-')}} 领取有效期:{{couponsDetails.highDiscount.effectiveDay}}天 @@ -100,7 +100,7 @@ getDiscountByUserDiscountId(params).then(res => { if (res.return_code == '000000') { this.couponsDetails = res.return_data; - this.salesEndTime = res.return_data.highDiscount.salesEndTime; + this.salesEndTime = res.return_data.useEndTime; this.getCouponByDiscount(res.return_data.highDiscount.id); } }) diff --git a/pages/user/order_details/order_details.vue b/pages/user/order_details/order_details.vue index 4994533..6569656 100644 --- a/pages/user/order_details/order_details.vue +++ b/pages/user/order_details/order_details.vue @@ -66,7 +66,7 @@ 支付模式 : - 金币 + 积分 第三方平台 @@ -87,7 +87,7 @@ 微信 - 金币 + 积分 @@ -183,33 +183,6 @@ - - @@ -255,29 +228,6 @@ }, onShow() { //页面显示时,加载订单信息 - // uni.getStorage({ - // key: 'buylist', - // success: (ret) => { - // this.buylist = ret.data; - // this.goodsPrice = 0; - // //合计 - // let len = this.buylist.length; - // for (let i = 0; i < len; i++) { - // this.goodsPrice = this.goodsPrice + (this.buylist[i].number * this.buylist[i].price); - // } - // this.deduction = this.int / 100; - // this.sumPrice = this.goodsPrice - this.deduction + this.freight; - // } - // }); - // uni.getStorage({ - // key: 'selectAddress', - // success: (e) => { - // this.recinfo = e.data; - // uni.removeStorage({ - // key: 'selectAddress' - // }) - // } - // }) this.getOrderById(); }, onHide() { diff --git a/pages/user/order_list/order_list.vue b/pages/user/order_list/order_list.vue index eb9e602..bc3fcf7 100644 --- a/pages/user/order_list/order_list.vue +++ b/pages/user/order_list/order_list.vue @@ -38,7 +38,7 @@ 卡券订单 加油缴费 - 金币订单 + 积分订单
--> - - + + 卡券订单 - - 加油缴费 + + 团油订单 + + + + 电影票 + + + + KFC - + - 金币订单 + 话费充值 - 06-13 12: 11(待改) + {{row.createTime | formatDate('-')}} @@ -162,6 +170,27 @@ onReachBottom() { this.getUserOrderList(); }, + filters: { + toFixed: function(x) { + return parseFloat(x).toFixed(2); + }, + //过滤器 用于格式化时间 + formatDate: function(value, spe = '/') { + let data = new Date(value); + let year = data.getFullYear(); + let month = data.getMonth() + 1; + let day = data.getDate(); + let h = data.getHours(); + let mm = data.getMinutes(); + let s = data.getSeconds(); + month = month >= 10 ? month : "0" + month; + day = day >= 10 ? day : "0" + day; + h = h >= 10 ? h : "0" + h; + mm = mm >= 10 ? mm : "0" + mm; + s = s >= 10 ? s : "0" + s; + return `${year}${spe}${month}${spe}${day} ${h}:${mm}:${s}`; + } + }, watch: { //监听reFresh,如果有修改就执行监听器 reFresh: function() { diff --git a/static/img/jt.png b/static/img/jt.png new file mode 100644 index 0000000000000000000000000000000000000000..e82b724009c618a5e74c05dda2be0f1469d086dd GIT binary patch literal 824 zcmV-81IPS{P)< zC|)7jSnOsKu@KS9;^a^SIVAfrvXFp=&BYwEGcRP*X7k?r|K5Mz%q&5e@()hAe#imj z4w!NR`4X6N1LQ+6Ujn+9z|73d=4!S21OOIY*Im{fUw1sM4ye^?rAnpp3K4e#!0#xE z7Fw;=Tir$LjHeAiv)SBIEEZq%#P@4li=t>hX9(H=IF7R*gm{_KowYcQ4|tyUT4(2U z#nJ{KDadi0!$OFM08khxkgXH60+>Vy+5z+-AmS1t3hqwG1VAEMN_kW%b(cGY%m9pn z5QgC%-}m3?8fF`flPQ4pASk7NMNzcZHiXOp`~~42BL0()0|X-g5(q?e8~|={gJ28* zR|rM{aD-qSz<)s4?fbsB(WyS}@2mjmLqNpaDFy%RZIMPGSOd^IF`g1a+^`A3DgX`; ztOKwOfdv4Y5ZD0dofyvoz*UnoffayJ5P~3>Yq#6)$KC4Id!8MD5fHuyK`^fq0!siy zbQ%$_4|Yx|^+PE&=Xu@-T`ph;KuUQI0Irx2pX6W#z_fT)0Ep-kB3?Ar`F>1HeJNwIx7A zHxcoq&CXjJf}F$~cYu`g4gehE(0Sty;3(dh1BmDWA|Bz?c~cG$M09_M_?0jWlQ+Pb zZ*{h=!-@FEh{$hq@b&48km z^68|A*X@8r{Br=WrQP9LL!vgjni!yC*uG&Sx989w(=^B`{7> zPS555ICaBDEx7}1Q0J60cL1ku*r+9UfDP)La{d8J&xdN+$p&D4hU00d#_x2`Cc)6SPd=%2FPB?_P3uzT{3h zy^HiDByx%U#s4Gw!ooW=-Rhm~00MEg4zh5dM zznHm*?@w_;M5+$o*8d+o%Fz&27z9A#B_6!@T`ti4La`5=bLt9@8z5+)WHz=#0f@c6 z8Y3la^rfy65g(gUz|05M%gq2JE+1X=BQEl`=@~>s)u1)bXr40!fS3-NFSfo^1OSa5 zpBqx}lbO#gXAc43u@UjTdha!aoqRdxG?adi7S$M9)xZRR1|^92Hy8C%NF_XiMu)xA zXDa|(zF$NpGky^@$fjrR0K~k3DJZf6uoaGa?@ecv693gX&N*qQq$v#VBwj;a0MJB4 z(cY-zm1d^Yc_A`Xcc|{UHAHR&AQgL;B6Ny#x{{?N0I6hW3ZhHjAtK2Htqp*!NUJnq zQ=O+3BxXK}-IoL)l5nibT2s+I_#Q+&0f0~I2c(R(1%S!2y}_J^4`aoX1%QORUL+tT zZV?->s6fezPpJQ^q0)xRgEfzDvlCU@fK&&mWV54M00Q$`Pl(nJLPuD$OH)-Rk|p-e zStd1tMAR8vY44AjU5+cPRsx)J+RoZ)b2XV25mQlPHWJWGT~n`|TV$zO0yc8@767t} ztTh9$)zFB5@aDZYjnm9V1&B!d{&#H#u0&(CS_x3biRc^=f5bp2)my9@fB=FHK5TS( zMPyKKF9zfs0LU(9&o&ee60iW!9InXq{p%93s6b?#rmBjNPLf7CyTw{;)k}biYop+z z1=qtNBQCS_0xP05CJ2A)q*sy2&tPQhOoww)T+6q!Pyq`=*1Zb=wR-{Ui(2=OA_1Z0 zJjw*9mBAkSHPYOeSv1E1ed>2T2&rYullMM4+px69tyxtqPuiD`t{Ow%5g9FFeC~T` zCHtO4G?X1%T0@oyoyFF9H7nCq?aF=zSFZ00000NkvXXu0mjfT{qe6 literal 0 HcmV?d00001 diff --git a/uni.scss b/uni.scss index 0354739..eec6a33 100644 --- a/uni.scss +++ b/uni.scss @@ -275,6 +275,10 @@ $uni-font-size-paragraph:30upx; width: 94%; margin-left: 3%; } +.width92 { + width: 92%; + margin-left: 4%; +} .width80 { @@ -343,6 +347,9 @@ $uni-font-size-paragraph:30upx; } /* 高40px */ +.height40p { + height: 40px; +} .height45 { height: 45px; } @@ -365,6 +372,12 @@ $uni-font-size-paragraph:30upx; height: 60px; } +.height80 { + height: 80px; +} + + + .height90 { height: 90px; } @@ -617,6 +630,11 @@ $uni-font-size-paragraph:30upx; display: flex; } +.alijun{ + justify-content: flex-end; + display: flex; +} + .font12{ font-size: 12px; } \ No newline at end of file