choose.vue 3.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180
  1. <template>
  2. <view class="">
  3. <view class="alertBox">
  4. <image class="titleImg" src="@/static/img/alertbg2.png" mode="widthFix"></image>
  5. <image :src="img" class="logo"></image>
  6. <view class="hed"></view>
  7. <view class="lxTtem flex" @click="type = 1">
  8. <view class="leftTitle flex">
  9. <image class="leftImgTip" src="@/static/img/bp2.png" mode="heightFix"></image>
  10. <text>个人会员</text>
  11. </view>
  12. <view class="rightTip flex"><view v-if="type == 1" class="xzTip"></view></view>
  13. </view>
  14. <view class="lxTtem flex" @click="type = 2">
  15. <view class="leftTitle flex">
  16. <image class="leftImgTip" src="@/static/img/bp1.png" mode="heightFix"></image>
  17. <text>企业会员</text>
  18. </view>
  19. <view class="rightTip flex"><view v-if="type == 2" class="xzTip"></view></view>
  20. </view>
  21. <view class="pushtyle" @click="submit">确认</view>
  22. </view>
  23. <view class="content" id="content"></view>
  24. </view>
  25. </template>
  26. <script>
  27. import { shareLoad } from '../../utils/wxAuthorized.js'
  28. import { getIndex } from '../../api/apply.js'
  29. import { getUserInfo } from '../../api/login.js'
  30. import {
  31. mapState,
  32. } from 'vuex';
  33. export default {
  34. data() {
  35. return {
  36. type: 1,
  37. img: require('@/static/img/logo.png'),
  38. }
  39. },
  40. computed: {
  41. ...mapState(['baseURL'])
  42. },
  43. mounted() {
  44. this.getContent()
  45. },
  46. onShow() {
  47. },
  48. onLoad() {
  49. this.share()
  50. },
  51. methods: {
  52. getContent() {
  53. getIndex().then(res => {
  54. const content = document.getElementById("content");
  55. console.log(res.data)
  56. content.innerHTML = res.data.content
  57. })
  58. },
  59. submit() {
  60. uni.navigateTo({
  61. url: '/pages/apply/information?type=' + this.type
  62. })
  63. },
  64. // 分享
  65. share() {
  66. const pages = getCurrentPages()
  67. const path = pages[pages.length - 1].route
  68. const baseURL = this.baseURL;
  69. const data = {
  70. link: window.location.href, // 分享链接
  71. imgUrl: `${baseURL}/index/static/img/logo.f387ae76.png`,
  72. desc: '母婴健康专委会会员申请表',
  73. title: '母婴健康专委会会员申请表',
  74. fail:function (e) {
  75. console.log(e);
  76. }
  77. }
  78. shareLoad(data)
  79. }
  80. }
  81. }
  82. </script>
  83. <style lang="scss" scoped>
  84. page {
  85. height: 100%;
  86. }
  87. .alertBox {
  88. background-color: #fff;
  89. width: 80%;
  90. margin: auto auto;
  91. border-radius: 30rpx;
  92. padding-bottom: 40rpx;
  93. position: relative;
  94. top: 100rpx;
  95. .titleImg {
  96. width: 100%;
  97. z-index: 99;
  98. position: absolute;
  99. top: 0;
  100. }
  101. .logo {
  102. width: 130rpx;
  103. height: 130rpx;
  104. position: absolute;
  105. top: 100rpx;
  106. left: calc(50% - 60rpx);
  107. }
  108. .hed {
  109. height: 230rpx;
  110. }
  111. .title {
  112. text-align: center;
  113. font-size: 36rpx;
  114. font-weight: bold;
  115. color: #333333;
  116. margin-top: -80rpx;
  117. }
  118. .titleTip {
  119. text-align: center;
  120. font-size: 24rpx;
  121. font-weight: bold;
  122. color: #808080;
  123. }
  124. .lxTtem {
  125. margin: 0 40rpx;
  126. padding: 30rpx 0;
  127. border-bottom: 1px solid #ebebeb;
  128. .leftTitle {
  129. justify-content: start;
  130. width: 43rpx;
  131. flex-grow: 1;
  132. color: #333333;
  133. font-size: 28rpx;
  134. .leftImgTip {
  135. flex-shrink: 0;
  136. // width: 30rpx;
  137. height: 30rpx;
  138. margin-right: 20rpx;
  139. }
  140. }
  141. .rightTip {
  142. border: 1px solid #006eeb;
  143. opacity: 0.5;
  144. border-radius: 50%;
  145. width: 32rpx;
  146. height: 32rpx;
  147. justify-content: center;
  148. .xzTip {
  149. width: 20rpx;
  150. height: 20rpx;
  151. border-radius: 99rpx;
  152. background-color: #006eeb;
  153. }
  154. }
  155. }
  156. .pushtyle {
  157. background-color: #3b66f5;
  158. border-radius: 10rpx;
  159. color: #ffffff;
  160. font-size: 28rpx;
  161. font-weight: bold;
  162. text-align: center;
  163. padding: 20rpx 0;
  164. margin: 0 40rpx;
  165. margin-top: 40rpx;
  166. }
  167. }
  168. .content {
  169. // background-color: ;
  170. position: relative;
  171. top: 150rpx;
  172. padding: 0 10%;
  173. font-size: 28rpx;
  174. color: #303133;
  175. line-height: 45rpx;
  176. }
  177. </style>