index.wxml 747 B

123456789101112131415161718
  1. <van-tabbar active="{{ active }}" placeholder active-color='#3874F6' bindchange="onChange">
  2. <van-tabbar-item wx:if="{{per.query(Permission,item.text)}}" info="{{item.fcount}}" name="{{item.name}}" wx:for="{{tabbarList}}" wx:key="index">
  3. <text slot='icon' class="{{'iconfont '+item.icon}}" style="font-size: 44rpx; color: #999999;" />
  4. <text slot='icon-active' class="{{'iconfont '+item.icon}}" style="font-size: 44rpx; color: #3874F6;" />
  5. {{item.text}}
  6. </van-tabbar-item>
  7. </van-tabbar>
  8. <wxs module="per">
  9. function query(list, name) {
  10. // console.log(list.includes(name))
  11. return a1 = list.some(function (v) {
  12. return v == name
  13. });
  14. };
  15. module.exports.query = query
  16. </wxs>