mySet.vue 1.5 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889
  1. <template>
  2. <view class="content">
  3. <view class="content1 flex-all-center relative">
  4. <view class="user">
  5. <image src="../../static/logo.png" mode="widthFix" class="img"></image>
  6. <view class="name">
  7. {{userInfo.nickName}}
  8. </view>
  9. </view>
  10. <view class="position">
  11. <u-icon name="share-square" color="#2979ff" size="28"></u-icon>
  12. <u-icon name="grid-fill" color="#2979ff" size="28"></u-icon>
  13. </view>
  14. </view>
  15. <view class="content2">
  16. <view class="row" v-for="item in menuList" @click="menuClick(item.type)">
  17. <span class="left">{{item.name}}</span>
  18. <span class="right">></span>
  19. </view>
  20. </view>
  21. </view>
  22. </template>
  23. <script>
  24. export default {
  25. data() {
  26. return {
  27. userInfo:{},
  28. menuList:[
  29. {
  30. name:"我的名片",
  31. type:'myInfo'
  32. },
  33. {
  34. name:"我的主页",
  35. type:'myHome'
  36. },
  37. {
  38. name:"账号",
  39. type:"myAccount"
  40. },
  41. {
  42. name:"名片分类",
  43. type:"cardType"
  44. },
  45. {
  46. name:"我的证件",
  47. type:"myCard"
  48. },
  49. {
  50. name:"帮助说明",
  51. type:"help"
  52. },
  53. {
  54. name:"联系客服",
  55. type:"contactCustomer"
  56. },
  57. {
  58. name:"设置",
  59. type:'set'
  60. },
  61. ]
  62. };
  63. },
  64. onShow() {
  65. this.userInfo = uni.getStorageInfoSync("userInfo")
  66. },
  67. methods:{
  68. menuClick(typeName){
  69. let _url = '/pages/mySet/'+typeName
  70. console.log(_url)
  71. uni.navigateTo({
  72. url:_url
  73. })
  74. }
  75. }
  76. }
  77. </script>
  78. <style lang="scss" scoped>
  79. .content1{
  80. .img{
  81. width: 100rpx;
  82. border-radius: 50%;
  83. }
  84. }
  85. </style>