@@ -26,7 +26,7 @@
export default {
props: {
permission: {
- type: Number,
+ type: Number | String,
default: 0
}
},
@@ -81,14 +81,17 @@
created(){
this.getRolToTabBars(uni.getStorageSync('nowPermission'));
- },
+ },
methods: {
// 路由跳转
navigateTo(pagePath){
- this.currentPagePath = pagePath;
- uni.navigateTo({
+ this.currentPagePath = pagePath;
+ uni.redirectTo({
url: `/${pagePath}`
});
+ // uni.navigateTo({
+ // url: `/${pagePath}`
+ // });
// 获取权限对应的地步导航
getRolToTabBars(permission) {