| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121 |
- <template>
- <view v-if="loading">
- <u-modal v-model="loading" :show-title="false" :show-confirm-button="false">
- <view class="slot-content center flex-direction">
- <image class="loading-icon" src="../../static/pay/loading.png"></image>
- <view class="tips center">处理中</view>
- </view>
- </u-modal>
- </view>
- <view v-else class="check-panel flex-direction">
- <image src="../../static/pay/success.png"></image>
- <view class="text-status center">付款成功</view>
- <view class="order-des center">{{orderDes}}</view>
- <view class=" fee center">¥{{amount}}</view>
- <button class="finish" @click="backToHome">完成</button>
- <view class="bottom-line center">联兑通提供技术支持</view>
- </view>
- </template>
- <script>
- export default {
- onLoad(option) {
- this.timer = setInterval(this.queryOrderStatus,500);
- },
- data() {
- return {
- counter: 0,
- timer: null,
- loading: true,
- amount: 100,
- orderDes: '扫码付款'
- }
- },
- methods: {
- queryOrderStatus(){
- this.counter++;
- console.log("轮询订单状态!");
- if(this.counter>10){
- clearInterval(this.timer);
- this.loading = false;
- }
- },
- backToHome(){
- uni.switchTab({
- url: '/pages/mine/mine'
- })
- }
- }
- }
- </script>
- <style lang="scss" scoped>
- .check-panel{
- background-color: #FFFFFF;
- border-radius: 25rpx;
- width: 90%;
- min-height: 900rpx;
- margin: 20rpx 5%;
- image{
- width: 150rpx;
- height: 150rpx;
- margin-top: 100rpx;
- margin-left: calc(50% - 75rpx);
- }
- .order-des{
- margin-top: 100rpx;
- color: #575959;
- width: 100%;
- font-size: 30rpx;
- letter-spacing: 2rpx;
- height: 100rpx;
- }
- .fee{
- height: 80rpx;
- width: 100%;
- color: #484a4b;
- font-size: 80rpx;
- // font-style: italic;
- font-weight: 350;
- }
- .text-status{
- color: #E1961A;
- height: 70rpx;
- width: 100%;
- }
- .finish{
- position: absolute;
- width: 40%;
- left: 30%;
- bottom: 25%;
- color: #E1961A;
- border-color: #E1961A ;
- letter-spacing: 20rpx;
- background: transparent ;
- }
- }
- .slot-content{
- height: 300rpx;
- .loading-icon{
- width: 100rpx;
- height: 100rpx;
- animation: round 1s infinite linear;
- }
- .tips{
- height: 80rpx;
- color: #565757;
- }
- }
- .bottom-line{
- position: absolute;
- bottom: 50rpx;
- left: 0;
- width: 100%;
- color: #dddddd;
- }
- @keyframes round {
- from{
- transform: rotate(360deg);
- }
- }
- </style>
|