帧视界壹通告,付费看视频的微信小程序
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

238 lines
6.9 KiB

1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
  1. <template>
  2. <view style="display: flex;flex-direction: column; width: 100vw;height: 100vh;">
  3. <tabber :select="2" />
  4. <!-- 顶部 -->
  5. <view style="width: 100%;height: 30%;">
  6. <image src="https://tennis-oss.xzaiyp.top/2024-09-07/05cbb032-8177-478e-8fbe-0a3797096890.png"
  7. style="width: 100%;height: 100%;"></image>
  8. </view>
  9. <!--中部 用户信息-->
  10. <view
  11. style="border-radius: 20rpx;position: absolute;top: 20%;left: 10%; width:80%;height: 12%;z-index: 1;background: white;">
  12. <!--头像-->
  13. <view
  14. style="position: absolute;z-index:2;width:30%;height:90%;border-radius: 50%;overflow: hidden;top: -32%;left: 2%;">
  15. <image :src="userInfo.headImage || '微信用户'" style="width: 100%;height: 100%;"></image>
  16. </view>
  17. <!--福利中心-->
  18. <!-- <view style="position: absolute;z-index:2;width:33%;height:30%;top: 13%;right: 2%;">
  19. <image src="/static/image/center/flzx.png" style="width: 100%;height: 100%;"></image>
  20. </view> -->
  21. <!-- 未认证-->
  22. <view style="position: absolute;z-index:2;width:15%;height:20%;top: 45%;left: 28%;">
  23. <image src="/static/image/center/wrz.png" style="width: 100%;height: 100%;"></image>
  24. </view>
  25. <!-- 去认证 -->
  26. <view style="position: absolute;z-index:2;width:55%;height:20%;top: 43%;left: 46%;">
  27. <span style="font-size: 26rpx;" class="textColor"
  28. @click="toAuthPage">去认证</span>
  29. </view>
  30. <!-- 用户信息 -->
  31. <view style="position: absolute;z-index:2;width:55%;height:20%;top: 60%;left: 7%;">
  32. <view>
  33. <span style="font-size: 35rpx;margin-right: 5rpx">{{ userInfo.nickName || '微信用户' }}</span>
  34. <span style="font-size: 18rpx">{{ userInfo.phone }}</span>
  35. </view>
  36. </view>
  37. <!-- 点赞量 -->
  38. <!-- <view
  39. style="display: flex;flex-direction: column;gap:2rpx ;position: absolute;z-index:2;width:15%;height:40%;top: 55%;right: 3%;">
  40. <view style="display: flex;justify-content: center;align-items: center;width: 100%;height: 100%;">
  41. <image src="/static/image/center/dianZan.svg" style="width: 40%;height: 84%;"></image>
  42. </view>
  43. <view style="display: flex;justify-content: center ;font-size: 20rpx;color:#777777">点赞量</view>
  44. </view> -->
  45. </view>
  46. <!-- 下部 -->
  47. <view style="width: 100%;height: 70%;padding-top:150rpx">
  48. <view>
  49. <!--上GridView-->
  50. <view>
  51. <uv-grid :col="4">
  52. <uv-grid-item v-for="(item,index) in baseList" :key="index" @click="goToPage(item)">
  53. <img :src="item.imageUrl" :alt="item.title"
  54. :style="{ width: '80rpx', height: '80rpx',marginBottom: '10rpx'}" />
  55. <text style="font-size: 30rpx;color: #333333;">{{ item.title }}
  56. </text>
  57. </uv-grid-item>
  58. </uv-grid>
  59. </view>
  60. <!--其他-->
  61. <view style="margin:50rpx 0 0 50rpx;font-size: 40rpx;color: #333333;">其他</view>
  62. <!--下GridView-->
  63. <view style="margin-top: 50rpx;">
  64. <uv-grid :col="4">
  65. <uv-grid-item v-for="(item,index) in otherList" :key="index" @click="goToPage(item)">
  66. <img :src="item.imageUrl" :alt="item.title"
  67. :style="{ width: '80rpx', height: '80rpx',marginBottom: '10rpx'}" />
  68. <text style="font-size: 30rpx;color: #333333;">{{ item.title }}
  69. </text>
  70. </uv-grid-item>
  71. </uv-grid>
  72. </view>
  73. </view>
  74. </view>
  75. <!-- 退出弹框-->
  76. <confirmationPopup ref="confirmationPopup" title="提示" :cancel="true" @confirm="handleConfirm"
  77. @cancel="handleCancel" confirmText="确认">
  78. <view class="confirmationPopup">
  79. <!-- <image src="/static/image/publish/upload.png"
  80. style="width: 150rpx;height: 150rpx;"
  81. mode=""></image> -->
  82. <view style="text-align:center">
  83. 确认退出登录吗
  84. </view>
  85. </view>
  86. </confirmationPopup>
  87. </view>
  88. </template>
  89. <script>
  90. import {
  91. mapState
  92. } from 'vuex'
  93. import tabber from '@/components/base/tabbar.vue'
  94. import confirmationPopup from "@/components/toast/confirmationPopup.vue";
  95. export default {
  96. components: {
  97. confirmationPopup,
  98. tabber,
  99. },
  100. computed: {
  101. ...mapState(['userInfo']),
  102. },
  103. data() {
  104. return {
  105. // 基础列表
  106. baseList: [{
  107. name: 'photo',
  108. imageUrl: 'https://tennis-oss.xzaiyp.top/2024-09-07/05cbb032-8177-478e-8fbe-0a3797096890.png',
  109. title: '我的发布',
  110. gotoPageUrl: '/mine/releaseRecord'
  111. },
  112. {
  113. name: 'lock',
  114. imageUrl: 'https://tennis-oss.xzaiyp.top/2024-09-07/05cbb032-8177-478e-8fbe-0a3797096890.png',
  115. title: '我的推广',
  116. gotoPageUrl: '/mine/promotionRecord'
  117. },
  118. {
  119. name: 'star',
  120. imageUrl: 'https://tennis-oss.xzaiyp.top/2024-09-07/05cbb032-8177-478e-8fbe-0a3797096890.png',
  121. title: '我的银行卡',
  122. gotoPageUrl: '/mine/addBankCard'
  123. },
  124. {
  125. name: 'star',
  126. imageUrl: 'https://tennis-oss.xzaiyp.top/2024-09-07/05cbb032-8177-478e-8fbe-0a3797096890.png',
  127. title: '我的钱包',
  128. gotoPageUrl: '/mine/purse'
  129. },
  130. ],
  131. // 其他列表
  132. otherList: [{
  133. name: 'photo',
  134. imageUrl: 'https://tennis-oss.xzaiyp.top/2024-09-07/05cbb032-8177-478e-8fbe-0a3797096890.png',
  135. title: '实名信息',
  136. gotoPageUrl: '/mine/certifiedIndividual'
  137. },
  138. {
  139. name: 'lock',
  140. imageUrl: 'https://tennis-oss.xzaiyp.top/2024-09-07/05cbb032-8177-478e-8fbe-0a3797096890.png',
  141. title: '帮助反馈'
  142. },
  143. {
  144. name: 'outLogin',
  145. imageUrl: 'https://tennis-oss.xzaiyp.top/2024-09-07/05cbb032-8177-478e-8fbe-0a3797096890.png',
  146. title: '退出登录',
  147. gotoPageUrl: '/mine/promotionRecord'
  148. },
  149. ],
  150. }
  151. },
  152. onShow() {
  153. // 获取用户个人信息
  154. this.$store.commit('getUserInfo')
  155. },
  156. methods: {
  157. toAuthPage(){
  158. uni.navigateTo({
  159. url: '/pages_mine/mine/authOption'
  160. })
  161. },
  162. // 点击列表跳转页面
  163. goToPage(item) {
  164. if (item.name == 'outLogin') {
  165. //
  166. this.$refs.confirmationPopup.open()
  167. return
  168. }
  169. uni.navigateTo({
  170. url: '/pages_mine' + item.gotoPageUrl
  171. })
  172. },
  173. handleConfirm() {
  174. // 退出登录
  175. console.log("退出登录")
  176. this.$api('loginLogout', res => {
  177. if (res.code == 200) {
  178. uni.removeStorageSync('token')
  179. this.$store.state.userInfo = {}
  180. uni.redirectTo({
  181. url: '/pages/index/index'
  182. })
  183. }
  184. })
  185. this.$refs.confirmationPopup.close()
  186. },
  187. handleCancel() {
  188. // 取消退出登录
  189. console.log("取消退出登录")
  190. this.$refs.confirmationPopup.close()
  191. }
  192. }
  193. }
  194. </script>
  195. <style lang="scss" scoped>
  196. * {
  197. box-sizing: border-box;
  198. margin: 0;
  199. padding: 0;
  200. }
  201. .textColor {
  202. background: $uni-linear-gradient-color;
  203. -webkit-background-clip: text;
  204. /*将设置的背景颜色限制在文字中*/
  205. -webkit-text-fill-color: transparent;
  206. /*给文字设置成透明*/
  207. }
  208. .confirmationPopup {
  209. display: flex;
  210. flex-direction: column;
  211. align-items: center;
  212. justify-content: center;
  213. width: 100%;
  214. height: 200rpx;
  215. image {
  216. margin-top: 40rpx;
  217. }
  218. .info {
  219. margin-top: 40rpx;
  220. font-size: 26rpx;
  221. }
  222. }
  223. </style>