my.vue 6.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249
  1. <template>
  2. <view class="tabPage" :style="{'min-height':h+'px', 'padding-top':mt+'px'}">
  3. <cus-header title='我的' bgColor="transparent" :showback="false"></cus-header>
  4. <image class="topbg" :src="imgBase+'my_topbg.png'" mode="widthFix"></image>
  5. <div class="box">
  6. <div class="top adfacjb">
  7. <div class="top-left adfac">
  8. <div class="top-left-img">
  9. <image :src="userInfo.avatar"></image>
  10. </div>
  11. <div class="top-left-info">
  12. <div class="top-left-info-name">{{userInfo.name||'未登录'}}</div>
  13. <div class="top-left-info-tip" v-if="!userInfo.name">点击立即登录</div>
  14. <div class="top-left-info-version" v-else>{{'基础版'}}</div>
  15. </div>
  16. </div>
  17. <div class="top-right">
  18. <image :src="imgBase+'my_set.png'"></image>
  19. </div>
  20. </div>
  21. <div class="num adf">
  22. <div class="num-pre adffcac">
  23. <div class="num-pre-sz">{{0}}</div>
  24. <div class="num-pre-text">基础版次数</div>
  25. </div>
  26. <div class="num-pre adffcac">
  27. <div class="num-pre-sz">{{0}}</div>
  28. <div class="num-pre-text">专业版次数</div>
  29. </div>
  30. <div class="num-pre adffcac">
  31. <div class="num-pre-sz">{{0}}</div>
  32. <div class="num-pre-text">我的团队</div>
  33. </div>
  34. </div>
  35. <div class="preill adfacjb">
  36. <div class="preill-left">{{userInfo.name?'已激活,深入了解支撑高价值团队的关键因素':'尚未激活问卷,无法开始PREILL评估'}}</div>
  37. <div class="preill-right" @click="handleActiveDetail">{{userInfo.name?'查看详情':'立即激活'}}</div>
  38. </div>
  39. <div class="menu">
  40. <div class="menu-item adfacjb" v-for="(item,index) in menuList" :key="index" @click="handleTurn(item.path)">
  41. <div class="menu-item-left adfac">
  42. <image :src="item.img"></image>
  43. <text>{{item.title}}</text>
  44. </div>
  45. <image class="menu-item-right" :src="imgBase+'my_arrow_right.png'"></image>
  46. </div>
  47. </div>
  48. </div>
  49. <Tabbar :tabbarIndex="2"></Tabbar>
  50. </view>
  51. </template>
  52. <script>
  53. import Tabbar from '@/components/CusTabbar/index.vue'
  54. export default {
  55. components:{ Tabbar },
  56. data(){
  57. return {
  58. userInfo:{
  59. avatar:this.$imgBase+'my_avatar.png',
  60. name:''
  61. },
  62. menuList:[
  63. {
  64. img:this.$imgBase+'my_order.png',
  65. title:'我的订单',
  66. path:'/pagesMy/order'
  67. },
  68. {
  69. img:this.$imgBase+'my_record.png',
  70. title:'推荐记录',
  71. path:'/pagesMy/recommendHistory'
  72. },
  73. {
  74. img:this.$imgBase+'my_program.png',
  75. title:'我的项目',
  76. path:''
  77. },
  78. {
  79. img:this.$imgBase+'my_teamusers.png',
  80. title:'团队成员',
  81. path:''
  82. },
  83. {
  84. img:this.$imgBase+'my_friends.png',
  85. title:'邀请好友',
  86. path:''
  87. }
  88. ]
  89. }
  90. },
  91. onLoad() {
  92. },
  93. methods:{
  94. handleTurn(url){
  95. if(!url) return
  96. uni.navigateTo({ url })
  97. },
  98. handleActiveDetail(){
  99. let url = '/pagesPublish/rechargeCenter'
  100. if(this.userInfo.name) url = '';
  101. url && uni.navigateTo({ url })
  102. }
  103. }
  104. }
  105. </script>
  106. <style scoped lang="scss">
  107. .tabPage{
  108. .topbg{
  109. width: 100%;
  110. position: absolute;
  111. left: 0;
  112. top: 0;
  113. }
  114. .box{
  115. position: relative;
  116. padding-top: 40rpx;
  117. .top{
  118. padding: 0 22rpx 0 16rpx;
  119. &-left{
  120. &-img{
  121. image{
  122. width: 128rpx;
  123. height: 128rpx;
  124. }
  125. }
  126. &-info{
  127. margin-left: 20rpx;
  128. &-name{
  129. font-family: PingFang-SC, PingFang-SC;
  130. font-weight: bold;
  131. font-size: 40rpx;
  132. color: #002846;
  133. line-height: 40rpx;
  134. }
  135. &-tip{
  136. font-family: PingFangSC, PingFang SC;
  137. font-weight: 400;
  138. font-size: 26rpx;
  139. color: #86909C;
  140. line-height: 26rpx;
  141. margin-top: 31rpx;
  142. }
  143. &-version{
  144. width: 129rpx;
  145. height: 40rpx;
  146. background: url('https://gitee.com/hw_0302/chuang-heng-wechat-images/raw/master/my_version_bg.png') no-repeat;
  147. background-size: 100% 100%;
  148. padding-left: 48rpx;
  149. box-sizing: border-box;
  150. font-family: PingFang-SC, PingFang-SC;
  151. font-weight: bold;
  152. font-size: 22rpx;
  153. color: #795021;
  154. line-height: 40rpx;
  155. margin-top: 24rpx;
  156. }
  157. }
  158. }
  159. &-right{
  160. image{
  161. width: 42rpx;
  162. height: 42rpx;
  163. }
  164. }
  165. }
  166. .num{
  167. margin-top: 48rpx;
  168. &-pre{
  169. width: calc(100% / 3);
  170. &-sz{
  171. font-family: D-DINCondensed, D-DINCondensed;
  172. font-weight: bold;
  173. font-size: 48rpx;
  174. color: #002846;
  175. line-height: 48rpx;
  176. }
  177. &-text{
  178. font-family: PingFangSC, PingFang SC;
  179. font-weight: 400;
  180. font-size: 26rpx;
  181. color: #86909C;
  182. line-height: 26rpx;
  183. text-align: center;
  184. margin-top: 24rpx;
  185. }
  186. }
  187. }
  188. .preill{
  189. margin-top: 49rpx;
  190. background: url('https://gitee.com/hw_0302/chuang-heng-wechat-images/raw/master/my_pinggu_bg.png') no-repeat;
  191. background-size: 100% 100%;
  192. padding: 34rpx 24rpx;
  193. &-left{
  194. font-family: PingFangSC, PingFang SC;
  195. font-weight: 400;
  196. font-size: 24rpx;
  197. color: #B0B7C7;
  198. line-height: 24rpx;
  199. padding-top: 42rpx;
  200. }
  201. &-right{
  202. padding: 18rpx 26rpx;
  203. background: linear-gradient( 270deg, #F0E2C7 0%, #E3CD9E 100%);
  204. border-radius: 32rpx;
  205. font-family: PingFangSC, PingFang SC;
  206. font-weight: 400;
  207. font-size: 26rpx;
  208. color: #795021;
  209. line-height: 26rpx;
  210. }
  211. }
  212. .menu{
  213. margin-top: 30rpx;
  214. background: #FFFFFF;
  215. border-radius: 16rpx;
  216. &-item{
  217. padding: 35rpx 30rpx;
  218. box-shadow: inset 0rpx -1rpx 0rpx 0rpx #EFEFEF;
  219. &-left{
  220. image{
  221. width: 40rpx;
  222. height: 40rpx;
  223. }
  224. text{
  225. font-family: PingFangSC, PingFang SC;
  226. font-weight: 400;
  227. font-size: 30rpx;
  228. color: #002846;
  229. line-height: 32rpx;
  230. margin-left: 21rpx;
  231. }
  232. }
  233. &-right{
  234. width: 36rpx;
  235. height: 36rpx;
  236. }
  237. }
  238. }
  239. }
  240. }
  241. </style>