|
- <template>
- <div>
- <router-view />
- <van-tabbar route :placeholder="true" >
- <van-tabbar-item replace to="/lawEnforcement" icon="wap-home-o">首页</van-tabbar-item>
- <van-tabbar-item replace to="/lawEnforcement/productsList" icon="shop-o">农用品</van-tabbar-item>
- <van-tabbar-item replace to="/lawEnforcement/caseList" icon="apps-o">案件</van-tabbar-item>
- <van-tabbar-item replace to="/lawEnforcement/user" icon="contact">我的</van-tabbar-item>
- </van-tabbar>
- </div>
- </template>
- <script>
- import { getUserProfile } from "@/api/lawEnforcement/index";
- export default {
- name: "law",
- data() {
- return {
- active: 0,
- tabShow: true,
- };
- },
- created() {
- // v-if="tabShow"
- // getUserProfile().then(response => {
- // if (response.data.roles.length < 1){
- // this.tabShow = false;
- // }else{
- // response.data.roles.forEach(res=>{
- // if(res.roleKey == 'personal_user' || res.roleKey == 'company_user'){
- // this.tabShow = false;
- // }else{
- // this.tabShow = true;
- // }
- // })
- // }
- // });
- },
- methods: {
-
- },
- };
- </script>
-
- <style scoped >
-
- >>> .van-tabbar{
- height:1.5rem;
- }
- </style>
|