Commit 6db5bcfa authored by 张俊's avatar 张俊

Merge branch 'zj' into dev

parents b2364aa9 f9ac3f4d
...@@ -280,17 +280,13 @@ export default { ...@@ -280,17 +280,13 @@ export default {
{ max: 200, message: "长度小于200个字符", trigger: "blur" }, { max: 200, message: "长度小于200个字符", trigger: "blur" },
], ],
}, },
edit_flag:0,
}; };
}, },
watch: {}, watch: {},
computed: {}, computed: {},
created() { created() {
this.now_user = this.$store.state.role; this.get_now_page()
getRole().then((data) => {
this.now_user = data;
this.$store.commit("rolefun", data);
this.now_page();
});
console.log(this.$route); console.log(this.$route);
}, },
mounted() {}, mounted() {},
...@@ -306,16 +302,31 @@ export default { ...@@ -306,16 +302,31 @@ export default {
} }
}); });
}, },
now_page() { get_now_page(){
if (this.$route.path.indexOf("edit") !== -1) { console.log(this.$route);
this.getInfo(); if(this.$route.path.indexOf('add')!==-1){
this.edit_flag = 0
}
if(this.$route.path.indexOf('edit')!==-1){
this.edit_flag = 1
this.getInfo()
} }
if (this.$route.path.indexOf("allot") !== -1) { if(this.$route.path.indexOf('detail')!==-1){
this.getInfo(); this.edit_flag = 2
this.getInfo()
} }
}, },
getInfo() { getInfo() {
console.log("111"); this.$http
.get(`/apaas/backmgt/role/id/${this.$route.params.id}`)
.then(response => {
console.log(response);
let data = response.data.data
})
.catch((response)=> {
});
}, },
changePermissions(values) { changePermissions(values) {
console.log(values); console.log(values);
......
This diff is collapsed.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment