success.vue 2.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899
  1. <template>
  2. <div class="point-success">
  3. <div class="icon"></div>
  4. <div class="text">兑换成功</div>
  5. <div class="menu">
  6. <nuxt-link class="text1" to="/point" tag="span">回到首页</nuxt-link>
  7. <nuxt-link class="text2" to="/point/list" tag="span">查看订单</nuxt-link>
  8. </div>
  9. </div>
  10. </template>
  11. <script>
  12. import ProductList from "../../components/ProductList";
  13. import { mapState, mapActions } from "vuex";
  14. import wx from "weixin-js-sdk";
  15. export default {
  16. head() {
  17. return {
  18. title: "兑换成功",
  19. };
  20. },
  21. data() {
  22. return {};
  23. },
  24. components: {
  25. ProductList,
  26. },
  27. created(){
  28. // // this.getAppId(1);
  29. // this
  30. },
  31. mounted() {
  32. this.getSdkConfig(["openLocation", "getNetworkType"]).then((res) => {
  33. console.log(res)
  34. wx.config(res)
  35. });
  36. },
  37. methods: {
  38. ...mapActions({
  39. getSdkConfig: "authen/getSdkConfig",
  40. getAppId:"authen/getAppId"
  41. }),
  42. },
  43. };
  44. </script>
  45. <style>
  46. .point-success {
  47. width: 100vw;
  48. height: 100vh;
  49. position: relative;
  50. }
  51. .point-success .icon {
  52. background: url("~static/point/cg@2xhuang.png") no-repeat 0px 0px;
  53. background-size: 100% 100%;
  54. width: 1.81rem;
  55. height: 1.81rem;
  56. position: absolute;
  57. left: 2.85rem;
  58. top: 1.6rem;
  59. }
  60. .point-success .text {
  61. height: 0.56rem;
  62. font-size: 0.4rem;
  63. font-family: PingFangSC-Regular, PingFang SC;
  64. font-weight: 400;
  65. color: #111111;
  66. line-height: 0.56rem;
  67. text-align: center;
  68. position: absolute;
  69. top: 3.71rem;
  70. left: 2.95rem;
  71. }
  72. .point-success .menu {
  73. width: 80vw;
  74. height: 1.1rem;
  75. background: #ffffff;
  76. box-shadow: 0rem 0.02rem 0.1rem 0rem rgba(0, 0, 0, 0.1);
  77. border-radius: 0.1rem;
  78. display: flex;
  79. flex-direction: row;
  80. justify-content: space-around;
  81. align-items: center;
  82. position: absolute;
  83. top: 50vh;
  84. left: 10vw;
  85. }
  86. .point-success .menu span {
  87. height: 0.45rem;
  88. font-size: 0.32rem;
  89. font-family: PingFangSC-Regular, PingFang SC;
  90. font-weight: 400;
  91. color: #111111;
  92. line-height: 0.45rem;
  93. }
  94. </style>