| File was renamed from pay/paySuccess.vue |
| | |
| | | <view class="u-font-32 font-bold u-m-t-10" style="color: #14AF0D;">支付成功</view> |
| | | </view> |
| | | <view class="shop-info"> |
| | | <view class="u-text-center u-font-32 color-666">{{youHuiInfo.shopName}}</view> |
| | | <view class="u-text-center u-m-t-20"> |
| | | <text class="u-font-30 lh-1">¥</text> |
| | | <text class="u-font-money lh-1">{{$u.priceFormat(youHuiInfo.payMoney/100, 2)}}</text> |
| | | <view class="u-text-center u-font-32 color-666">{{youHuiInfo.shopName}}测试门店</view> |
| | | <view class="u-flex u-col-top u-row-center"> |
| | | <view class="u-font-24 lh-1">¥</view> |
| | | <view class="u-font-money lh-1">{{$u.priceFormat(youHuiInfo.payMoney/100, 2)}}</view> |
| | | </view> |
| | | </view> |
| | | <view class="u-flex u-m-t-30 u-font-30"> |
| | |
| | | </view> |
| | | <view class="u-flex-1 u-text-right">¥{{$u.priceFormat(youHuiInfo.money/100, 2)}}</view> |
| | | </view> |
| | | <!-- <view class="u-flex u-m-t-16 u-font-30"> |
| | | <view class="u-flex u-m-t-16 u-font-30"> |
| | | <view class="color-999 u-flex"> |
| | | <view class="label" style="color: #F69249;">使用积分</view> |
| | | </view> |
| | | <view class="u-flex-1 u-text-right" style="color: #F69249;">{{youHuiInfo.score}}积分<text |
| | | v-if="youHuiInfo.score>0">抵扣{{$u.priceFormat(youHuiInfo.scoreDkPrice/100, 2)}}元</text> |
| | | </view> |
| | | </view>--> |
| | | <view v-if="youHuiInfo.couponDkPrice!=0" class="u-flex u-m-t-16 u-font-30"> |
| | | </view> |
| | | <view class="u-flex u-m-t-16 u-font-30"> |
| | | <view class="color-999 u-flex"> |
| | | <view class="label">优惠券</view> |
| | | </view> |
| | |
| | | </view> |
| | | </view> |
| | | |
| | | <view v-else-if="!join" class="box bg-fff u-m-t-20"> |
| | | <navigator class="u-flex" url="/pages/pay/shuaKa/shuaKa"> |
| | | <image class="card-logo" :src="bankCardStyle.logo"></image> |
| | | <view class="u-flex-1"> |
| | | <view class="u-font-30">领刷{{info.bankCardName}}{{info.totalDiscount/100}}元立减金</view> |
| | | <view class="u-font-24 color-999">参与刷卡有礼,领更多优惠</view> |
| | | </view> |
| | | <view> |
| | | <u-button type="success" size="mini" text="领取"></u-button> |
| | | </view> |
| | | |
| | | </navigator> |
| | | </view> |
| | | |
| | | <view :url="jumpUrl" class="btn-box"> |
| | | <u-button @click="clickDone" text="完成" type="success" plain shape="circle"></u-button> |
| | | </view> |
| | |
| | | </view> |
| | | <view class="u-flex-1">¥{{$u.priceFormat(orderInfo.orderPrice/100, 2)}}</view> |
| | | </view> |
| | | <!-- <view class="u-flex u-m-t-30 u-font-30"> |
| | | <view class="u-flex u-m-t-30 u-font-30"> |
| | | <view class="color-999 u-flex"> |
| | | <view class="label">使用积分</view>: |
| | | </view> |
| | | <view class="u-flex-1">{{orderInfo.payIntegral}}积分<text |
| | | v-if="orderInfo.payIntegral>0">抵扣{{$u.priceFormat(orderInfo.integralMoney/100, 2)}}元</text> |
| | | </view> |
| | | </view>--> |
| | | <view class="u-flex u-m-t-30 u-font-30"> |
| | | </view> |
| | | <view class="u-flex u-m-t-30 u-font-30"> |
| | | <view class="color-999 u-flex"> |
| | | <view class="label">优惠券</view>: |
| | | </view> |
| | |
| | | </view> |
| | | </view> |
| | | <view class="btn-box"> |
| | | <u-button @click="clickDone" text="完成" type="success" plain shape="circle"></u-button> |
| | | <u-button @click="doJump" text="完成" type="success" plain shape="circle"></u-button> |
| | | </view> |
| | | </block> |
| | | |
| | |
| | | |
| | | <script> |
| | | import { |
| | | getPayCompleteUrl, |
| | | getWxOrderInfo, |
| | | } from 'common/api/index' |
| | | } from '@/common/api/index' |
| | | import { |
| | | activityInfo, |
| | | myBrushDetail, |
| | | orderRefBrushNode |
| | | } from '@/common/api/shuaka' |
| | | export default { |
| | | data() { |
| | | return { |
| | | plat: this.$utils.getPlat(), |
| | | info: { |
| | | bankCardName: '', |
| | | totalDiscount: 0, |
| | |
| | | }; |
| | | }, |
| | | onLoad(opt) { |
| | | activityInfo().then(res => { |
| | | this.info = res |
| | | }) |
| | | myBrushDetail().then(res => { |
| | | if (res) { |
| | | this.join = true |
| | | } else { |
| | | this.join = false |
| | | } |
| | | }) |
| | | if (uni.getStorageSync("bankCardStyle")) { |
| | | this.bankCardStyle = uni.getStorageSync("bankCardStyle") |
| | | } |
| | | |
| | | getPayCompleteUrl().then(res => { |
| | | this.jumpUrl = res |
| | | }) |
| | | if (opt.youHuiInfo) { |
| | | this.youHuiInfo = JSON.parse(opt.youHuiInfo) |
| | | } |
| | | if (opt.orderId) { |
| | | this.orderId = opt.orderId |
| | | /*orderRefBrushNode({ |
| | | orderRefBrushNode({ |
| | | orderId: this.orderId |
| | | }).then(res => { |
| | | this.couponList = res.coupIdsMap || [] |
| | | })*/ |
| | | }) |
| | | } |
| | | }, |
| | | onReady() { |
| | |
| | | return null; |
| | | }, |
| | | clickDone() { |
| | | let browser = navigator.userAgent.toLowerCase(); |
| | | if (browser.match(/Alipay/i) == "alipay") { |
| | | console.log("支付宝app的浏览器"); |
| | | //这个可以关闭安卓系统的手机 |
| | | document.addEventListener("AlipayJSBridgeReady", function () { |
| | | AlipayJSBridge.call("closeWindow"); |
| | | }, |
| | | false |
| | | ); |
| | | //这个可以关闭ios系统的手机 |
| | | AlipayJSBridge.call('closeWebview'); //支付宝 |
| | | } else if (browser.match(/MicroMessenger/i) == "micromessenger") { |
| | | //这个可以关闭安卓系统的手机 |
| | | document.addEventListener("WeixinJSBridgeReady", function () { |
| | | WeixinJSBridge.call("closeWindow"); |
| | | }, |
| | | false |
| | | ); |
| | | //这个可以关闭ios系统的手机 |
| | | WeixinJSBridge.call("closeWindow"); |
| | | } else { |
| | | console.log("其它浏览器"); |
| | | window.opener = null; //如果没有这行和下面的一行则会出现上面的第二个询问框。 |
| | | window.open(' ', '_self', ' '); |
| | | window.close() |
| | | } |
| | | // window.close() |
| | | WeixinJSBridge.call('closeWindow'); |
| | | |
| | | }, |
| | | doJump() { |
| | | var mchData = { |
| | |
| | | .coupon { |
| | | width: 638rpx; |
| | | height: 172rpx; |
| | | background-image: url('~@/static/pay-by-card-coupon.png'); |
| | | background-image: url('~@/static/shuaka/pay-by-card-coupon.png'); |
| | | background-size: cover; |
| | | margin: 10rpx auto 20rpx; |
| | | display: flex; |
| | |
| | | .lh-1 { |
| | | line-height: 1; |
| | | } |
| | | </style> |
| | | </style> |