Commit 882bb4780fc78e91a5fe5d713b81cb6028276743
1 parent
08e0d9c8
充值方式
Showing
2 changed files
with
204 additions
and
196 deletions
pages/rechargeDetail/outDetail.vue
| 1 | 1 | <template> |
| 2 | - <view> | |
| 3 | - <view style="height: 100px;line-height: 100px;" class="uni-center"> | |
| 4 | - <text style="font-size: 32px;font-weight: 500;">{{changeFeeDetail}}</text> | |
| 5 | - </view> | |
| 6 | - <view class="border-bg"></view> | |
| 2 | + <view> | |
| 3 | + <view style="height: 100px;line-height: 100px;" class="uni-center"> | |
| 4 | + <text style="font-size: 32px;font-weight: 500;">{{changeFeeDetail}}</text> | |
| 5 | + </view> | |
| 6 | + <view class="border-bg"></view> | |
| 7 | 7 | |
| 8 | - <view class="uni-list"> | |
| 9 | - <view class="uni-list-cell paddingTopBottom"> | |
| 10 | - <view class="uni-list-cell-left"> | |
| 11 | - 订单编号 | |
| 12 | - </view> | |
| 13 | - <view class="uni-list-cell-db"> | |
| 14 | - {{orderId | tranNull}} | |
| 15 | - </view> | |
| 16 | - </view> | |
| 17 | - <view class="uni-list-cell paddingTopBottom"> | |
| 18 | - <view class="uni-list-cell-left"> | |
| 19 | - 支付时间 | |
| 20 | - </view> | |
| 21 | - <view class="uni-list-cell-db"> | |
| 22 | - {{payTime | tranNull}} | |
| 23 | - </view> | |
| 24 | - </view> | |
| 25 | - <view class="uni-list-cell paddingTopBottom"> | |
| 26 | - <view class="uni-list-cell-left"> | |
| 27 | - 支付方式 | |
| 28 | - </view> | |
| 29 | - <view class="uni-list-cell-db color-green"> | |
| 30 | - {{payType | tranNull}} | |
| 31 | - </view> | |
| 32 | - </view> | |
| 33 | - <view class="uni-list-cell paddingTopBottom"> | |
| 34 | - <view class="uni-list-cell-left"> | |
| 35 | - 交易类型 | |
| 36 | - </view> | |
| 37 | - <view class="uni-list-cell-db"> | |
| 38 | - {{typeName | tranNull}} | |
| 39 | - </view> | |
| 40 | - </view> | |
| 41 | - <view class="" v-if="cardIsShow"> | |
| 42 | - <view class="uni-list-cell paddingTopBottom"> | |
| 43 | - <view class="uni-list-cell-left"> | |
| 44 | - 卡券类型 | |
| 45 | - </view> | |
| 46 | - <view class="uni-list-cell-db"> | |
| 47 | - {{cardType | tranNull}} | |
| 48 | - </view> | |
| 49 | - </view> | |
| 50 | - <view class="uni-list-cell paddingTopBottom"> | |
| 51 | - <view class="uni-list-cell-left"> | |
| 52 | - 规则名称 | |
| 53 | - </view> | |
| 54 | - <view class="uni-list-cell-db"> | |
| 55 | - {{cardRuleName | tranNull}} | |
| 56 | - </view> | |
| 57 | - </view> | |
| 58 | - <view class="uni-list-cell paddingTopBottom"> | |
| 59 | - <view class="uni-list-cell-left"> | |
| 60 | - 购买数量 | |
| 61 | - </view> | |
| 62 | - <view class="uni-list-cell-db"> | |
| 63 | - {{cardNum | tranNull}}张 | |
| 64 | - </view> | |
| 65 | - </view> | |
| 8 | + <view class="uni-list"> | |
| 9 | + <view class="uni-list-cell paddingTopBottom"> | |
| 10 | + <view class="uni-list-cell-left"> | |
| 11 | + 订单编号 | |
| 12 | + </view> | |
| 13 | + <view class="uni-list-cell-db"> | |
| 14 | + {{orderId | tranNull}} | |
| 15 | + </view> | |
| 16 | + </view> | |
| 17 | + <view class="uni-list-cell paddingTopBottom"> | |
| 18 | + <view class="uni-list-cell-left"> | |
| 19 | + 支付时间 | |
| 20 | + </view> | |
| 21 | + <view class="uni-list-cell-db"> | |
| 22 | + {{payTime | tranNull}} | |
| 23 | + </view> | |
| 24 | + </view> | |
| 25 | + <view class="uni-list-cell paddingTopBottom"> | |
| 26 | + <view class="uni-list-cell-left"> | |
| 27 | + 支付方式 | |
| 28 | + </view> | |
| 29 | + <view class="uni-list-cell-db color-green"> | |
| 30 | + {{payType | tranNull}} | |
| 31 | + </view> | |
| 32 | + </view> | |
| 33 | + <view class="uni-list-cell paddingTopBottom"> | |
| 34 | + <view class="uni-list-cell-left"> | |
| 35 | + 交易类型 | |
| 36 | + </view> | |
| 37 | + <view class="uni-list-cell-db"> | |
| 38 | + {{typeName | tranNull}} | |
| 39 | + </view> | |
| 40 | + </view> | |
| 41 | + <view class="" v-if="cardIsShow"> | |
| 42 | + <view class="uni-list-cell paddingTopBottom"> | |
| 43 | + <view class="uni-list-cell-left"> | |
| 44 | + 卡券类型 | |
| 45 | + </view> | |
| 46 | + <view class="uni-list-cell-db"> | |
| 47 | + {{cardType | tranNull}} | |
| 48 | + </view> | |
| 49 | + </view> | |
| 50 | + <view class="uni-list-cell paddingTopBottom"> | |
| 51 | + <view class="uni-list-cell-left"> | |
| 52 | + 规则名称 | |
| 53 | + </view> | |
| 54 | + <view class="uni-list-cell-db"> | |
| 55 | + {{cardRuleName | tranNull}} | |
| 56 | + </view> | |
| 57 | + </view> | |
| 58 | + <view class="uni-list-cell paddingTopBottom"> | |
| 59 | + <view class="uni-list-cell-left"> | |
| 60 | + 购买数量 | |
| 61 | + </view> | |
| 62 | + <view class="uni-list-cell-db"> | |
| 63 | + {{cardNum | tranNull}}张 | |
| 64 | + </view> | |
| 65 | + </view> | |
| 66 | 66 | |
| 67 | - </view> | |
| 68 | - </view> | |
| 69 | - <view class="border-bg"></view> | |
| 67 | + </view> | |
| 68 | + </view> | |
| 69 | + <view class="border-bg"></view> | |
| 70 | 70 | |
| 71 | - </view> | |
| 71 | + </view> | |
| 72 | 72 | </template> |
| 73 | 73 | |
| 74 | 74 | <script> |
| 75 | - export default { | |
| 76 | - data() { | |
| 77 | - | |
| 78 | - return { | |
| 79 | - changeFeeDetail: '', | |
| 80 | - orderId: '', | |
| 81 | - payTime: '', | |
| 82 | - typeName: '', | |
| 83 | - payType: '商户余额', | |
| 84 | - cardRuleName: '', | |
| 85 | - cardType: '', | |
| 86 | - cardNum: '', | |
| 87 | - cardIsShow: false, | |
| 88 | - } | |
| 89 | - }, | |
| 90 | - onLoad(params) { | |
| 91 | - wx.showShareMenu({ | |
| 92 | - withShareTicket: true | |
| 93 | - }) | |
| 94 | - let option = JSON.parse(params.optionData) | |
| 95 | - console.log(option) | |
| 96 | - this.changeFeeDetail = option.changeFeeDetail | |
| 97 | - this.orderId = option.orderId | |
| 98 | - this.typeName = option.typeName | |
| 99 | - this.payTime = option.opTime | |
| 100 | - if (option.typeName == "购买卡券") { | |
| 101 | - this.cardIsShow = true; | |
| 102 | - this.getCouponInfo(); | |
| 103 | - }else{ | |
| 104 | - this.cardIsShow = false; | |
| 105 | - } | |
| 106 | - | |
| 107 | - | |
| 108 | - | |
| 109 | - }, | |
| 110 | - onShow() { | |
| 111 | - var me = this; | |
| 112 | - var userInfo = me.getGlobalUser("globalUser"); | |
| 113 | - if (userInfo != null) { | |
| 114 | - me.phoneNumb = userInfo.userPhone; | |
| 115 | - } | |
| 116 | - var pages = getCurrentPages(); | |
| 117 | - var currPage = pages[pages.length - 1]; //当前页面 | |
| 118 | - console.log('currPage.data.selCoupon = ' + currPage.data.selCoupon); | |
| 119 | - me.selCoupon = currPage.data.selCoupon; | |
| 120 | - console.log(JSON.stringify(me.selCoupon)); | |
| 121 | - // me.GetbillQueryInfo(me.mycarNumber, me.myorderId, me.myparkCode, me.selCoupon.cardNo, me.selCoupon.couponType, me.selCoupon | |
| 122 | - // .discValue); | |
| 123 | - // GetbillQueryInfo(carnum, orderId, parkCode, cardNo, couponType, disValue) { | |
| 124 | - }, | |
| 125 | - computed: { | |
| 126 | - startDate() { | |
| 127 | - return this.getDate('start'); | |
| 128 | - }, | |
| 129 | - endDate() { | |
| 130 | - return this.getDate('end'); | |
| 131 | - } | |
| 132 | - }, | |
| 133 | - methods: { | |
| 134 | - bindPickerChange: function(e) { | |
| 135 | - console.log('picker发送选择改变,携带值为', e.detail.value) | |
| 136 | - this.index = e.detail.value | |
| 137 | - }, | |
| 138 | - bindPickerChangeWay: function(e) { | |
| 139 | - console.log('picker发送选择改变,携带值为', e.detail.value) | |
| 140 | - this.indexWay = e.detail.value | |
| 141 | - }, | |
| 142 | - bindStartDateChange: function(e) { | |
| 143 | - this.benginDate = e.detail.value | |
| 144 | - }, | |
| 145 | - bindEndDateChange: function(e) { | |
| 146 | - this.overDate = e.detail.value | |
| 147 | - }, | |
| 148 | - getDate(type) { | |
| 149 | - const date = new Date(); | |
| 150 | - let year = date.getFullYear(); | |
| 151 | - let month = date.getMonth() + 1; | |
| 152 | - let day = date.getDate(); | |
| 153 | - if (type === 'start') { | |
| 154 | - year = year - 60; | |
| 155 | - } else if (type === 'end') { | |
| 156 | - year = year + 2; | |
| 157 | - } | |
| 158 | - month = month > 9 ? month : '0' + month; | |
| 159 | - day = day > 9 ? day : '0' + day; | |
| 160 | - return `${year}-${month}-${day}`; | |
| 161 | - }, | |
| 162 | - getCouponInfo(){ | |
| 163 | - let that = this | |
| 164 | - let paramsData = { | |
| 165 | - orderId: that.orderId | |
| 166 | - } | |
| 167 | - | |
| 168 | - that.$myRequest({ | |
| 169 | - url: that.$common.couponInfo, | |
| 170 | - method: 'POST', | |
| 171 | - data: that.$common.requestSign(paramsData) | |
| 172 | - }).then(res => { | |
| 173 | - console.log(res) | |
| 174 | - that.cardType = res.data.cardTypeName | |
| 175 | - that.cardRuleName = res.data.cardRuleName | |
| 176 | - that.cardNum = res.data.buyNum | |
| 177 | - }) | |
| 178 | - | |
| 179 | - | |
| 180 | - }, | |
| 181 | - } | |
| 182 | - } | |
| 75 | +export default { | |
| 76 | + data() { | |
| 77 | + return { | |
| 78 | + changeFeeDetail: '', | |
| 79 | + orderId: '', | |
| 80 | + payTime: '', | |
| 81 | + typeName: '', | |
| 82 | + payType: '商户余额', | |
| 83 | + cardRuleName: '', | |
| 84 | + cardType: '', | |
| 85 | + cardNum: '', | |
| 86 | + cardIsShow: false, | |
| 87 | + } | |
| 88 | + }, | |
| 89 | + onLoad(params) { | |
| 90 | + wx.showShareMenu({ | |
| 91 | + withShareTicket: true | |
| 92 | + }) | |
| 93 | + let option = JSON.parse(params.optionData) | |
| 94 | + console.log(option) | |
| 95 | + this.changeFeeDetail = option.changeFeeDetail | |
| 96 | + this.orderId = option.orderId | |
| 97 | + this.typeName = option.typeName | |
| 98 | + this.payTime = option.opTime | |
| 99 | + if (option.kind == 1) { | |
| 100 | + this.payType = '支付宝' | |
| 101 | + } | |
| 102 | + if (option.kind == 2) { | |
| 103 | + this.payType = '微信' | |
| 104 | + } | |
| 105 | + if (option.kind == 3) { | |
| 106 | + this.payType = '平台现金' | |
| 107 | + } | |
| 108 | + if (option.typeName == "购买卡券") { | |
| 109 | + this.cardIsShow = true; | |
| 110 | + this.getCouponInfo(); | |
| 111 | + } else { | |
| 112 | + this.cardIsShow = false; | |
| 113 | + } | |
| 114 | + }, | |
| 115 | + onShow() { | |
| 116 | + var me = this; | |
| 117 | + var userInfo = me.getGlobalUser("globalUser"); | |
| 118 | + if (userInfo != null) { | |
| 119 | + me.phoneNumb = userInfo.userPhone; | |
| 120 | + } | |
| 121 | + var pages = getCurrentPages(); | |
| 122 | + var currPage = pages[pages.length - 1]; //当前页面 | |
| 123 | + console.log('currPage.data.selCoupon = ' + currPage.data.selCoupon); | |
| 124 | + me.selCoupon = currPage.data.selCoupon; | |
| 125 | + console.log(JSON.stringify(me.selCoupon)); | |
| 126 | + // me.GetbillQueryInfo(me.mycarNumber, me.myorderId, me.myparkCode, me.selCoupon.cardNo, me.selCoupon.couponType, me.selCoupon | |
| 127 | + // .discValue); | |
| 128 | + // GetbillQueryInfo(carnum, orderId, parkCode, cardNo, couponType, disValue) { | |
| 129 | + }, | |
| 130 | + computed: { | |
| 131 | + startDate() { | |
| 132 | + return this.getDate('start'); | |
| 133 | + }, | |
| 134 | + endDate() { | |
| 135 | + return this.getDate('end'); | |
| 136 | + } | |
| 137 | + }, | |
| 138 | + methods: { | |
| 139 | + bindPickerChange: function (e) { | |
| 140 | + console.log('picker发送选择改变,携带值为', e.detail.value) | |
| 141 | + this.index = e.detail.value | |
| 142 | + }, | |
| 143 | + bindPickerChangeWay: function (e) { | |
| 144 | + console.log('picker发送选择改变,携带值为', e.detail.value) | |
| 145 | + this.indexWay = e.detail.value | |
| 146 | + }, | |
| 147 | + bindStartDateChange: function (e) { | |
| 148 | + this.benginDate = e.detail.value | |
| 149 | + }, | |
| 150 | + bindEndDateChange: function (e) { | |
| 151 | + this.overDate = e.detail.value | |
| 152 | + }, | |
| 153 | + getDate(type) { | |
| 154 | + const date = new Date(); | |
| 155 | + let year = date.getFullYear(); | |
| 156 | + let month = date.getMonth() + 1; | |
| 157 | + let day = date.getDate(); | |
| 158 | + if (type === 'start') { | |
| 159 | + year = year - 60; | |
| 160 | + } else if (type === 'end') { | |
| 161 | + year = year + 2; | |
| 162 | + } | |
| 163 | + month = month > 9 ? month : '0' + month; | |
| 164 | + day = day > 9 ? day : '0' + day; | |
| 165 | + return `${year}-${month}-${day}`; | |
| 166 | + }, | |
| 167 | + getCouponInfo() { | |
| 168 | + let that = this | |
| 169 | + let paramsData = { | |
| 170 | + orderId: that.orderId | |
| 171 | + } | |
| 172 | + that.$myRequest({ | |
| 173 | + url: that.$common.couponInfo, | |
| 174 | + method: 'POST', | |
| 175 | + data: that.$common.requestSign(paramsData) | |
| 176 | + }).then(res => { | |
| 177 | + console.log(res) | |
| 178 | + that.cardType = res.data.cardTypeName | |
| 179 | + that.cardRuleName = res.data.cardRuleName | |
| 180 | + that.cardNum = res.data.buyNum | |
| 181 | + }) | |
| 182 | + }, | |
| 183 | + } | |
| 184 | +} | |
| 183 | 185 | </script> |
| 184 | 186 | |
| 185 | 187 | <style lang="scss" scoped> |
| 186 | - .rechargeWrap { | |
| 187 | - position: relative; | |
| 188 | + .rechargeWrap { | |
| 189 | + position: relative; | |
| 188 | 190 | |
| 189 | - .rechargeArrow { | |
| 190 | - position: absolute; | |
| 191 | - right: 10px; | |
| 192 | - top: 30px; | |
| 193 | - font-size: 20px; | |
| 194 | - color: #999; | |
| 195 | - } | |
| 196 | - } | |
| 191 | + .rechargeArrow { | |
| 192 | + position: absolute; | |
| 193 | + right: 10px; | |
| 194 | + top: 30px; | |
| 195 | + font-size: 20px; | |
| 196 | + color: #999; | |
| 197 | + } | |
| 198 | + } | |
| 197 | 199 | |
| 198 | - .recordCon { | |
| 199 | - padding-right: 35px; | |
| 200 | - color: #999; | |
| 201 | - display: flex; | |
| 202 | - justify-content: space-between; | |
| 203 | - } | |
| 200 | + .recordCon { | |
| 201 | + padding-right: 35px; | |
| 202 | + color: #999; | |
| 203 | + display: flex; | |
| 204 | + justify-content: space-between; | |
| 205 | + } | |
| 204 | 206 | </style> | ... | ... |
pages/rechargeDetail/rechargeDetail.vue
| ... | ... | @@ -67,11 +67,17 @@ |
| 67 | 67 | <text>{{item.payStateDesc}}</text> |
| 68 | 68 | </view> |
| 69 | 69 | <view class="recordCon uni-list-cell-pd"> |
| 70 | - <text v-if="item.typeName == '购买卡券'" class="color-green">{{item.typeName}}</text> | |
| 71 | - <text v-if="item.typeName == '微信充值'" class="color-green">{{item.typeName}}</text> | |
| 72 | - <text v-if="item.typeName == '支付停车费'" class="color-red">{{item.typeName}}</text> | |
| 73 | - <text v-if="item.typeName == '支付宝充值'" class="color-blue">{{item.typeName}}</text> | |
| 74 | - <text v-if="item.typeName == '平台现金充值'" class="color-red">{{item.typeName}}</text> | |
| 70 | + <!--<text v-if="item.typeName == '购买卡券'" class="color-green">{{item.typeName}}</text>--> | |
| 71 | + <!--<text v-if="item.typeName == '微信充值'" class="color-green">{{item.typeName}}</text>--> | |
| 72 | + <!--<text v-if="item.typeName == '支付停车费'" class="color-red">{{item.typeName}}</text>--> | |
| 73 | + <!--<text v-if="item.typeName == '支付宝充值'" class="color-blue">{{item.typeName}}</text>--> | |
| 74 | + <!--<text v-if="item.typeName == '平台现金充值'" class="color-red">{{item.typeName}}</text>--> | |
| 75 | + | |
| 76 | + <text v-if="item.kind == '1'" class="color-green">支付宝</text> | |
| 77 | + <text v-if="item.typeName == '2'" class="color-green">微信</text> | |
| 78 | + <text v-if="item.typeName == '3'" class="color-red">平台现金</text> | |
| 79 | + | |
| 80 | + | |
| 75 | 81 | <text>{{item.opTime}}</text> |
| 76 | 82 | </view> |
| 77 | 83 | <view class="uni-icon pos-abs icon-arrowright uni-icon-arrowright"> | ... | ... |