fix: base user界面显示优化
This commit is contained in:
parent
faacaa8d8e
commit
febde751c3
|
|
@ -77,6 +77,7 @@
|
|||
<scTable
|
||||
ref="table"
|
||||
:apiObj="apiObj"
|
||||
row-key="id"
|
||||
stripe
|
||||
remoteSort
|
||||
remoteFilter
|
||||
|
|
@ -487,20 +488,29 @@ export default {
|
|||
let res;
|
||||
|
||||
if (this.type === "add") {
|
||||
res = await this.$API.system.user.create.req(this.addForm);
|
||||
try {
|
||||
res = await this.$API.system.user.create.req(this.addForm);
|
||||
this.isSaveing = false;
|
||||
this.limitedVisible = false;
|
||||
this.$refs.table.refresh()
|
||||
this.$message.success("操作成功");
|
||||
}catch (err) {
|
||||
this.isSaveing = false;
|
||||
}
|
||||
} else if (this.type === "edit") {
|
||||
res = await this.$API.system.user.update.req(
|
||||
try {
|
||||
res = await this.$API.system.user.update.req(
|
||||
this.addForm.id,
|
||||
this.addForm
|
||||
);
|
||||
}
|
||||
this.isSaveing = false;
|
||||
if (res.err_msg) {
|
||||
this.$message(res.err_msg);
|
||||
} else {
|
||||
this.limitedVisible = false;
|
||||
this.$refs.table.refresh()
|
||||
this.$message.success("操作成功");
|
||||
this.isSaveing = false;
|
||||
this.limitedVisible = false;
|
||||
this.$refs.table.refresh()
|
||||
this.$message.success("操作成功");
|
||||
}catch(e) {
|
||||
this.isSaveing = false;
|
||||
}
|
||||
|
||||
}
|
||||
} else {
|
||||
return false;
|
||||
|
|
|
|||
Loading…
Reference in New Issue