删除账户(逻辑删除) 代码调整

This commit is contained in:
joylink_cuiweidong 2021-06-10 14:48:24 +08:00
parent b1a0fd88d0
commit 298999d7ff

View File

@ -9,7 +9,7 @@
</template>
<script>
import { getUserList } from '@/api/management/user';
import { getUserList, deleteUserInLogic } from '@/api/management/user';
import { getCompanyList } from '@/api/company';
import DictionaryEdit from './edit';
import CreateUser from './createUser';
@ -144,6 +144,10 @@ export default {
{
name: '绑定组织管理员',
handleClick: this.handleBind
},
{
name: '删除',
handleClick: this.handleDelete
}
]
}
@ -200,6 +204,15 @@ export default {
handleBind(index, row) {
this.$refs.bindCompany.doShow(row);
},
handleDelete(index, row) {
deleteUserInLogic(row.id).then(resp=> {
//
this.$message.success('删除账户成功!');
this.reloadTable();
}).catch(() => {
this.$messageBox('删除账户失败');
});
},
create() {
this.reloadTable();
}