index.vue 1.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869
  1. <template>
  2. <view>
  3. <view :class="'top-fixed' + (skinNotColor ? ' not-color' : '')" :style="'height: '+ systems.barHeight + 'rpx;'">
  4. <view class="top-fixed-c" :style="'height: '+ systems.navigationHeight + 'rpx;margin-top:' + systems.ktxStatusHeight + 'rpx;'">
  5. <navigator url="" hover-class="none" open-type="navigateBack" class="back"><image :src="picUrlss+'back_white.png'"></image></navigator>
  6. <view class="top-title ddflex" :style="'line-height: '+ systems.navigationHeight + 'rpx;'">会员开通</view>
  7. </view>
  8. </view>
  9. <image :src="picUrlss+'scrm/vip_top.png'" class="top-img"></image>
  10. <view class="cons">
  11. <view class="tit ddflex">开通会员卡</view>
  12. <view class="tits">会员等级</view>
  13. <view class="list ddflex">
  14. <view class="li">
  15. 青铜会员
  16. <image :src="picUrlss+'scrm/vip_gou.png'" class="gou"></image>
  17. </view>
  18. <view class="li">
  19. 白银会员
  20. </view>
  21. <view class="li">
  22. 黄金会员
  23. </view>
  24. </view>
  25. </view>
  26. </view>
  27. </template>
  28. <script>
  29. //index.js
  30. //获取应用实例
  31. const app = getApp();
  32. const req = require('../../utils/request.js');
  33. const api = require('../../utils/api.js');
  34. export default {
  35. data() {
  36. return {
  37. picUrlss: req.public.picUrls,
  38. systems: {}
  39. };
  40. },
  41. components: {
  42. },
  43. props: {},
  44. onLoad: async function(options) {
  45. },
  46. async onShow() {
  47. },
  48. methods: {
  49. },
  50. mounted() {
  51. const systemInfo = uni.getSystemInfoSync();
  52. // px转换到rpx的比例
  53. let pxToRpxScale = 750 / systemInfo.windowWidth;
  54. let systems = {
  55. ktxStatusHeight: systemInfo.statusBarHeight * pxToRpxScale, // 状态栏的高度
  56. navigationHeight: 44 * pxToRpxScale // 导航栏的高度
  57. };
  58. systems.barHeight = systems.ktxStatusHeight + systems.navigationHeight;
  59. this.systems = systems;
  60. }
  61. };
  62. </script>
  63. <style>
  64. @import "./index.css";
  65. </style>