Commit 58a15a4d by 张杰

增加手动获取权限

1 parent 5fa2f96d
......@@ -871,15 +871,17 @@ export default {
// this.vehicleDefalutData.find((item) => item.prop == "configId").options =
// res.data;
}); */
console.log(this.$root.parentVuex.getters.curMenuAuth.data);
console.log(this.$root);
let _this = this;
let o = history.state;
if (o.vin) {
this.searchForm.keywords = o.vin;
this.$nextTick(function () {
let tag = this.$refs.serchButton;
let tag = _this.$refs.serchButton;
if (tag) {
tag.$el.click();
}
_this.getMenuPath();
});
}
},
......@@ -887,7 +889,6 @@ export default {
methods: {
beforeSearchFn() {
return new Promise((resolve, reject) => {
console.log(this.searchForm.date);
if (this.searchForm.date) {
this.searchForm.activateTimeStart = this.searchForm.date[0];
this.searchForm.activateTimeEnd = this.searchForm.date[1];
......@@ -972,7 +973,7 @@ export default {
data.brandId,
data.subBrandId,
data.seriesId,
data.typeId||data.modelId,
data.typeId || data.modelId,
];
}
......@@ -1002,7 +1003,7 @@ export default {
data.brandId,
data.subBrandId,
data.seriesId,
data.typeId||data.modelId,
data.typeId || data.modelId,
];
this.snForm = { ...data };
console.log(this.snForm);
......@@ -1544,6 +1545,22 @@ export default {
"/oEshield#/monitor/monitor?vin=" + this.snForm.vin
);
},
// 手动获取二级菜单权限
getMenuPath() {
let root = this.$root;
let list = root.parentVuex.getters.menuList;
console.log(list);
let o = list.find((k) => k.label == "车辆管理");
if (!o) {
return false;
}
let m = o.children.find((j) => j.label == "车辆列表");
console.log(m);
if (m) {
root.parentCommon.getSecondMenu(m.id, m.label);
}
},
},
};
</script>
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!