menu.vue 3.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124
  1. <template>
  2. <view class="page">
  3. <view class="showlines" v-for="(m,index) in list" :key='index' @tap="$jump(m.url)">
  4. <view >{{m.title}}</view>
  5. <view>
  6. <uni-icons type="arrowright" style="font-size: 16px; color: #666;display: inline-block;vertical-align: middle;font-weight: 600;"></uni-icons>
  7. </view>
  8. </view>
  9. <view class="showlines" @click="goYh()">
  10. <view >用户协议</view>
  11. <view>
  12. <uni-icons type="arrowright" style="font-size: 16px; color: #666;display: inline-block;vertical-align: middle;font-weight: 600;"></uni-icons>
  13. </view>
  14. </view>
  15. <view class="showlines" @click="goYs()">
  16. <view >隐私协议</view>
  17. <view>
  18. <uni-icons type="arrowright" style="font-size: 16px; color: #666;display: inline-block;vertical-align: middle;font-weight: 600;"></uni-icons>
  19. </view>
  20. </view>
  21. <view class="showlines" @click="gozx()">
  22. <view >注销账号</view>
  23. <view>
  24. <uni-icons type="arrowright" style="font-size: 16px; color: #666;display: inline-block;vertical-align: middle;font-weight: 600;"></uni-icons>
  25. </view>
  26. </view>
  27. </view>
  28. </template>
  29. <script>
  30. export default {
  31. data() {
  32. return {
  33. list:[]
  34. }
  35. },
  36. onLoad(opts) {
  37. var list=[];
  38. if(opts.act=='setting'){
  39. list.push({title:'资料设置',url:'mine.profile'});
  40. list.push({title:'绑定手机',url:'mine.mobile'});
  41. list.push({title:'登录密码',url:'mine.password'});
  42. // list.push({title:'资金密码',url:'mine.password1'});
  43. // list.push({title:'我的银行卡',url:'mine.bank'});
  44. list.push({title:'消息通知设置',url:'mine.note'});
  45. }
  46. else if(opts.act=='team'){
  47. list.push({title:'我的团队',url:'mine.my_invite'});
  48. list.push({title:'邀请好友',url:'mine.invite'});
  49. // list.push({title:'手动开户',url:'mine.user_add'});
  50. uni.setNavigationBarTitle({
  51. title:'我的下级'
  52. })
  53. }
  54. this.list=list;
  55. },
  56. methods: {
  57. gozx() {
  58. // console.log();
  59. uni.navigateTo({
  60. url:'/pages/mine/zxzh'
  61. })
  62. },
  63. goYs() {
  64. uni.navigateTo({
  65. url:'/pages/login/rule?type=1'
  66. })
  67. },
  68. goYh() {
  69. uni.navigateTo({
  70. url:'/pages/login/rule?type=0'
  71. })
  72. }
  73. }
  74. }
  75. </script>
  76. <style>
  77. .page{
  78. background-color: #fafafa;
  79. }
  80. .showlines{
  81. display: flex;
  82. height: 50px;
  83. line-height: 50px;
  84. margin-top: 15px;
  85. flex-direction: row;
  86. background-color: #fff;
  87. border-bottom:1px #eee solid;
  88. }
  89. .showlines > view{
  90. flex-direction: row;
  91. height: 50px;
  92. line-height: 50px;
  93. }
  94. .showlines > view:nth-child(1){
  95. width:calc(100% - 30px);
  96. text-align: left;
  97. font-size: 16px;
  98. color: #000;
  99. padding-left: 20px;
  100. }
  101. .showlines > view:nth-child(2){
  102. width:30px ;
  103. text-align: center;
  104. }
  105. .showlines image{
  106. width: 25px;
  107. height:25px;
  108. vertical-align: middle;
  109. }
  110. </style>