<template>
  <div class="paySuccess">

    <i class="el-icon-success" style="color: #67c32a;font-size:90px;margin-bottom: 15px"></i>
    <span style="font-size:30px">支付成功!</span>
  </div>
</template>

<script>
import {payhuidiaoAPI} from '@/api/login'

export default {
  data() {
    return {
      url: window.location.href,
      params: {}
    }
  },
  created() {
    // var params = this.getparams()
    // this.payhuidiao(params)
  },
  mounted() {

  },
  methods: {
    getparams() {
      if (this.url.indexOf("?") != -1) {
        this.url = this.url.split('?')[1];
        if (this.url.indexOf("&") != -1) {
          this.url = this.url.split('&');
          this.url.forEach(item => {
            if (item.indexOf('=') === -1) {
              this.params[item] = undefined
            } else {
              const innerArrIndex = item.indexOf('=')
              const key = item.substring(0, innerArrIndex)
              const value = item.substr(innerArrIndex + 1)
              this.params[key] = value
            }
          })
          return this.params
        }
      }
    },
    payhuidiao(params) {
      payhuidiaoAPI(params).then(res => {
        if (res.status == true) {

        } else {
        }
      })
    }
  }
}
</script>

<style lang="scss" scoped>
.paySuccess {
  width: 100%;
  height: 100%;
  display: flex;

  flex-direction: column;
  align-items: center;
  justify-content: center;
}
</style>
