update
parent
4bc15af9d3
commit
c55cd0599b
|
@ -469,7 +469,6 @@ export default {
|
||||||
handleAdd() {
|
handleAdd() {
|
||||||
this.reset();
|
this.reset();
|
||||||
getUser().then(response => {
|
getUser().then(response => {
|
||||||
debugger
|
|
||||||
this.postOptions = response.posts;
|
this.postOptions = response.posts;
|
||||||
this.roleOptions = response.roles;
|
this.roleOptions = response.roles;
|
||||||
this.oldRoleOptions=response.roles;
|
this.oldRoleOptions=response.roles;
|
||||||
|
@ -482,7 +481,7 @@ export default {
|
||||||
handleUpdate(row) {
|
handleUpdate(row) {
|
||||||
this.reset();
|
this.reset();
|
||||||
const userId = row.userId || this.ids;
|
const userId = row.userId || this.ids;
|
||||||
getUser(userId).then(response => {
|
getUser(userId).then(response => {
|
||||||
this.form = response.data;
|
this.form = response.data;
|
||||||
this.postOptions = response.posts;
|
this.postOptions = response.posts;
|
||||||
this.roleOptions = response.roles;
|
this.roleOptions = response.roles;
|
||||||
|
@ -496,6 +495,10 @@ export default {
|
||||||
let node=this.$refs.treeSel.getNode(this.form.deptId);
|
let node=this.$refs.treeSel.getNode(this.form.deptId);
|
||||||
this.$refs.treeSel.select(node);
|
this.$refs.treeSel.select(node);
|
||||||
this.doInputDept(node.raw);
|
this.doInputDept(node.raw);
|
||||||
|
let roles=response.data.roles;
|
||||||
|
if(roles.length>0){
|
||||||
|
this.form.roleId=roles[0].roleId;
|
||||||
|
}
|
||||||
const func=p=>{
|
const func=p=>{
|
||||||
p.isExpanded=true;
|
p.isExpanded=true;
|
||||||
if(p.parentNode){
|
if(p.parentNode){
|
||||||
|
|
Loading…
Reference in New Issue