index.vue 1.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107
  1. <template>
  2. <view class="content">
  3. <view class="one">
  4. <image :src="basicInfo.logo_url&&basicInfo.logo_url.length>0?basicInfo.logo_url[0].url:''" mode="aspectFit">
  5. </image>
  6. </view>
  7. <view class="two">
  8. <view class="two_1">
  9. 抵制不良游戏,拒绝盗版游戏。
  10. </view>
  11. <view class="two_1">
  12. 注意自我保护,谨防受骗上当。
  13. </view>
  14. <view class="two_1">
  15. 适度游戏宜脑,沉迷游戏伤身体。
  16. </view>
  17. <view class="two_1">
  18. 合理安排时间,享受健康时间。
  19. </view>
  20. </view>
  21. </view>
  22. </template>
  23. <script>
  24. export default {
  25. data() {
  26. return {
  27. basicInfo: {},
  28. timer: null,
  29. }
  30. },
  31. onLoad() {},
  32. onShow() {
  33. const that = this;
  34. that.search();
  35. },
  36. methods: {
  37. async search() {
  38. const that = this;
  39. let url = '/pagesHome/home/index';
  40. // 不可返回
  41. // uni.redirectTo({
  42. // url
  43. // })
  44. // 可返回
  45. uni.navigateTo({
  46. url
  47. })
  48. // let res = await that.$api('appbasic', 'GET');
  49. // if (res.errcode == '0') {
  50. // that.$set(that, `basicInfo`, res.data)
  51. // uni.setStorage({
  52. // key: 'basicInfo',
  53. // data: res.data,
  54. // success: function() {
  55. // 不可返回
  56. // uni.redirectTo({
  57. // url
  58. // })
  59. // 可返回
  60. // uni.navigateTo({
  61. // url
  62. // })
  63. // }
  64. // });
  65. // } else {
  66. // uni.showToast({
  67. // title: res.errmsg,
  68. // icon: 'none'
  69. // })
  70. // }
  71. },
  72. }
  73. }
  74. </script>
  75. <style lang="scss">
  76. .content {
  77. .one {
  78. flex-grow: 1;
  79. text-align: center;
  80. image {
  81. width: 50vw;
  82. height: 50vw;
  83. border-radius: 90%;
  84. box-shadow: 0 0 5px var(--rgbf1f);
  85. margin: 30vw 0 0 0;
  86. }
  87. .version {
  88. margin: 2vw 0 0 0;
  89. }
  90. }
  91. .two {
  92. text-align: center;
  93. padding: 10px 0;
  94. .two_1 {
  95. padding: 0 0 10px 0;
  96. font-size: 14px;
  97. }
  98. }
  99. }
  100. </style>