diff --git a/app.json b/app.json index 6f84ecc..c654f2c 100644 --- a/app.json +++ b/app.json @@ -25,6 +25,7 @@ "pages/addPark/addPark", "pages/orderquanma/index", "pages/passCar/couponList/couponList", + "pages/passCar/choicecoupon/choicecoupon", "pages/passCar/couponDetail/couponDetail", "pages/managelicenseplate/managelicenseplate" ], diff --git a/assets/img/gou.png b/assets/img/gou.png new file mode 100644 index 0000000..2b84bc8 Binary files /dev/null and b/assets/img/gou.png differ diff --git a/pages/passCar/choicecoupon/choicecoupon.js b/pages/passCar/choicecoupon/choicecoupon.js new file mode 100644 index 0000000..966a00f --- /dev/null +++ b/pages/passCar/choicecoupon/choicecoupon.js @@ -0,0 +1,74 @@ +const format = require("../../../utils/util.js"); +const config = require("../../../config/config.js"); +const app = getApp(); +const Http = require("../../../utils/HttpBasics"); +Page({ + data: { + list: [], + current: "0", + current_scroll: "0", + page: 1, + allow_load: true + }, + onLoad(options) { + this.getList(0, 0); + if (options.quanid){ + this.setData({ + quanid: options.quanid + }) + } + }, + + /** + * 选择使用的优惠券 + */ + choicecoupon: function(e) { + wx.navigateBack(); + console.log(e); + var pages = getCurrentPages(); + var prevPage = pages[pages.length - 2] //上一个页面 + var that = this; + var quantitle = e.currentTarget.dataset.title; + var quanid = e.currentTarget.dataset.id; + prevPage.setData({ + quantitle: quantitle, + quanid: quanid, + }); + wx.setStorage({ + key: 'chosed', + data: 'chosed', + }) + }, + getList(key, pageNum) { + var that = this; + console.log(key); + console.log(pageNum); + if (that.data.allow_load) { + Http.get({ + url: config.api.couponOrderList + "?type=5", + data: { + pageNum: pageNum, + pageSize: 20, + couponOrderStatus: key + } + }).then(res => { + console.log(res); + res.data.list.map(file => { + file.expiredTime = format.formatTime( + file.expiredTime, + "yyyy-MM-dddd hh:mm:ss" + ); + }); + if (pageNum > res.data.pages) { + that.setData({ + allow_load: false + }); + } + that.data.list = that.data.list.concat(res.data.list); + that.setData({ + list: that.data.list + }); + }); + } + }, +}); \ No newline at end of file diff --git a/pages/passCar/choicecoupon/choicecoupon.json b/pages/passCar/choicecoupon/choicecoupon.json new file mode 100644 index 0000000..2d7e370 --- /dev/null +++ b/pages/passCar/choicecoupon/choicecoupon.json @@ -0,0 +1,3 @@ +{ + "navigationBarTitleText": "停车券" +} \ No newline at end of file diff --git a/pages/passCar/choicecoupon/choicecoupon.wxml b/pages/passCar/choicecoupon/choicecoupon.wxml new file mode 100644 index 0000000..b50189d --- /dev/null +++ b/pages/passCar/choicecoupon/choicecoupon.wxml @@ -0,0 +1,39 @@ + + + + + 请您敬请期待 + 我们正在筹备一大波优惠活动 + + + + + + + + + + + + {{item.title}} + + + {{item.subTitle}} + + {{item.salePrice/100}} + + + + + + + 有效期至: + {{item.expiredTime}} + + + + + {{content}} + + + \ No newline at end of file diff --git a/pages/passCar/choicecoupon/choicecoupon.wxss b/pages/passCar/choicecoupon/choicecoupon.wxss new file mode 100644 index 0000000..8b98674 --- /dev/null +++ b/pages/passCar/choicecoupon/choicecoupon.wxss @@ -0,0 +1,211 @@ +.market { + width: 100%; + height: 100%; + /* background: #f5f5f5; */ +} + +.tabs { + width: 100% !important; + height: 88rpx; + text-align: center; + position: fixed; + top: 0; + left: 0; + right: 0; + z-index: 100000; +} + +.i-tab { + width: 25% !important; + display: inline-block; +} + +.section { + position: relative; +} + +.mms { + position: relative; + width: 690rpx; + background: #fff; + padding: 20rpx 0 0; + margin: 0 auto 46rpx; + border-top: 8rpx solid #02b7ff; + box-shadow: 0 6px 20px 0 rgba(0, 0, 0, 0.10); +} + +.detail_msg { + display: flex; +} + +.expiretime { + display: block; + width: 100%; + text-align: left; + text-indent: 1em; + height: 50rpx; + line-height: 50rpx; + font-size: 22rpx; + color: #999; + letter-spacing: 0; +} + +.liness { + display: block; + width: 100%; + margin-top: 20rpx; +} + +.logo { + width: 60rpx; + height: 60rpx; + border: 1px solid #f8f8f8; + border-radius: 50rpx; + display: block; + margin-left: 20rpx; +} + +.logo image { + width: 60rpx; + height: 60rpx; + border-radius: 50%; +} + +.info view:nth-child(1) { + display: flex; + justify-content: space-between; + padding: 0 2%; +} + +.info { + width: 100%; +} + +.info view:nth-child(1) text { + font-size: 32rpx; + line-height: 32rpx; + height: 32rpx; + color: #333; + letter-spacing: 0; + width: 400rpx; + display: inline-block; + white-space: nowrap; + text-overflow: ellipsis; + overflow: hidden; +} + +.info view:nth-child(2) { + padding-left: 2%; + font-size: 22rpx; + color: #333; + letter-spacing: 0; + margin-top: 6rpx; + display: inline-block; + white-space: nowrap; + text-overflow: ellipsis; + overflow: hidden; + width: 400rpx; +} + +.info view:nth-child(3) { + margin-left: 20rpx; +} + +.btns { + position: absolute; + right: 57rpx; + top: 0; + bottom: 0; + margin: auto; + width: 180rpx; + height: 48rpx; + line-height: 48rpx; + text-align: right; + color: #f96563; + font-size: 40rpx; +} + +.yuan { + color: #333; + font-size: 26rpx; +} + +.txt1 { + font-size: 22rpx; + color: #333; + letter-spacing: 0; +} + +.nocoupon image { + width: 300rpx; + display: block; + margin: 3% auto 0; +} + +.txt001 { + display: block; + line-height: 48rpx; + font-size: 34rpx; + color: #333; + letter-spacing: 0; + text-align: center; +} + +.txt002 { + display: block; + margin-top: 1%; + font-size: 28rpx; + color: #999; + letter-spacing: 0; + line-height: 40rpx; + text-align: center; +} + +.nocoupon button { + background: #00c0ff; + color: #fff; + font-style: 30rpx; + width: 100%; + border-radius: 60rpx; +} + +.loading { + text-align: center; + height: 80rpx; + line-height: 80rpx; + font-size: 26rpx; + color: #999; +} + +.loading image { + width: 60rpx; + height: 60rpx; + vertical-align: middle; + margin-right: 10rpx; +} + +.active { + opacity: 0.6; +} + +.nav { + position: absolute; + bottom: 3.3%; + left: 0; + right: 0; + margin: auto; + width: 670rpx; + border-radius: 60rpx; + background: #02c0ff; + font-size: 32px; + color: #fff; + text-align: center; + line-height: 32px; +} + +.gou { + position: absolute; + top: -15rpx; + right: -10rpx; + width: 60rpx; +} diff --git a/pages/passCar/couponDetail/couponDetail.wxss b/pages/passCar/couponDetail/couponDetail.wxss index 7cee945..6da2aa7 100644 --- a/pages/passCar/couponDetail/couponDetail.wxss +++ b/pages/passCar/couponDetail/couponDetail.wxss @@ -73,6 +73,7 @@ } .coupon_detail { padding: 0 20rpx; + margin-top: 30rpx; } .fl { @@ -154,8 +155,8 @@ display: flex; flex-direction: column; background: #fff; - border-bottom: 20rpx solid #f5f5f5; - border-top: 20rpx solid #f5f5f5; + border-bottom: 6rpx solid #f5f5f5; + border-top: 6rpx solid #f5f5f5; position: relative; } diff --git a/pages/passCar/couponList/couponList.wxml b/pages/passCar/couponList/couponList.wxml index 873e410..6eca002 100644 --- a/pages/passCar/couponList/couponList.wxml +++ b/pages/passCar/couponList/couponList.wxml @@ -16,9 +16,9 @@ - + + 总车位:{{park.number}}个 停车费: @@ -19,8 +19,7 @@ - + @@ -47,18 +46,27 @@ 停车时长: {{timecha}} - + + + 优惠券: - 2小时优免券 + + {{quantitle}} + {{couponList.length}}张可用 + + + + + 待缴费用: - {{stopFees.remainingFee}} + {{stopFees.remainingFee}} - - + + + @@ -98,16 +106,5 @@ - - \ No newline at end of file diff --git a/pages/passCar/passCar.wxss b/pages/passCar/passCar.wxss index e334774..394451a 100644 --- a/pages/passCar/passCar.wxss +++ b/pages/passCar/passCar.wxss @@ -3,7 +3,11 @@ page { background-color: #fff; } +.container{ + padding-bottom: 60rpx; +} .top{ + padding-bottom: 34rpx; } .headBox { width: 690rpx; @@ -60,7 +64,7 @@ page { width: 690rpx; font-size: 28rpx; color: #999; - margin: 10rpx auto 60rpx; + margin: 10rpx auto 0; } .time { @@ -150,7 +154,10 @@ page { .bottonBox { width: 750rpx; - margin-top: 30rpx; + margin-top: 32rpx; + margin-bottom: 80rpx; + border-top: 16rpx #f8f8f8 solid; + padding-top: 13rpx; } .textStyle { @@ -218,7 +225,7 @@ page { .passNumberBox { width: 690rpx; - margin: 50rpx auto 0; + margin: 32rpx auto 0; position: relative; background-color: white; } @@ -383,7 +390,7 @@ page { background: #fff; position: relative; height: 88rpx; - margin-top: 50rpx; + margin-top: 30rpx; } .buy { @@ -415,15 +422,15 @@ page { .borderBox { width: 750rpx; - border-top: 4rpx #f8f8f8 solid; + border-top: 16rpx #f8f8f8 solid; } .carmanage { position: relative; width: 690rpx; - margin: 0 auto; - height: 80rpx; - line-height: 82rpx; + margin: 15rpx auto 0; + height: 60rpx; + line-height: 60rpx; /* border-bottom: 1rpx solid #eee; */ } @@ -464,7 +471,7 @@ page { .mycar { display: inline-block; font-size: 33rpx; - color: #333; + color: #666; line-height: 35rpx; letter-spacing: 1.16rpx; } @@ -579,13 +586,13 @@ button::after { } .orderBox .fl { - line-height: 60rpx; + line-height: 67rpx; font-size: 28rpx; color: #333; } .orderBox .fr { - line-height: 60rpx; + line-height: 67rpx; font-size: 28rpx; color: #ff4949; } @@ -602,3 +609,11 @@ button::after { border-radius: 6rpx; margin-right: 6rpx; } +.jiant{ + display: inline-block; + width: 44rpx; + height: 44rpx; + vertical-align: middle; + margin-top: -6rpx; + margin-right: -10rpx; +} \ No newline at end of file diff --git a/pages/ques/ques.wxss b/pages/ques/ques.wxss index ad4e9f4..3c83dca 100644 --- a/pages/ques/ques.wxss +++ b/pages/ques/ques.wxss @@ -1,5 +1,5 @@ .content { - padding: 0 30rpx; + padding: 0 30rpx 30rpx 30rpx; margin: 30rpx auto; } diff --git a/pages/user/index.wxml b/pages/user/index.wxml index 6543b23..9302def 100644 --- a/pages/user/index.wxml +++ b/pages/user/index.wxml @@ -67,7 +67,7 @@ - 版本号:2.0.8 + 版本号:2.0.9