回库删除用户

This commit is contained in:
@fawn-nine
2023-06-26 17:36:25 +08:00
parent 8a91600612
commit f60e0f4b8a
2 changed files with 32 additions and 4 deletions

View File

@@ -77,11 +77,14 @@
<el-table-column prop="company" label="Affiliation"></el-table-column>
<el-table-column prop="field" label="Field"></el-table-column>
<el-table-column prop="remark" label="Remark" width="160"></el-table-column>
<el-table-column label="" width="100" align="center">
<el-table-column label="" width="200" align="center">
<template slot-scope="scope">
<el-button plain type="primary" icon="el-icon-edit" @click="handleEdit(scope.row)">
Edit
</el-button>
<el-button plain type="danger" icon="el-icon-edit" @click="handleDelete(scope.row)">
Delete
</el-button>
<!-- <div style="margin-top: 12px;">
<el-button plain type="warning" @click="handleSend(scope.row)">
PROMOTION
@@ -545,6 +548,29 @@
this.initMajor()
},
methods: {
// 删除灰库用户
handleDelete(row){
this.$confirm(`'Do you want to delete the user? Name: '${row.name}'`, 'prompt', {
confirmButtonText: 'Yes',
cancelButtonText: 'Cancel',
type: 'warning'
}).then(() => {
this.$api
.post('api/User/delAshUser',{'ash_id': row.ash_id})
.then(res => {
if(res.code == 0){
this.$message.success('successed!')
this.getDate()
}
})
.catch(err => {
console.log(err);
});
}).catch(() => { });
},
// 获取国家列表
getCountry() {
this.$api