update 用户管理 增加用户登录状态解锁功能

This commit is contained in:
疯狂的狮子Li
2026-03-18 13:45:37 +08:00
parent e138c314a8
commit 790abfac85
2 changed files with 25 additions and 0 deletions
+13
View File
@@ -89,6 +89,9 @@
<el-button v-has-permi="['system:user:remove']" type="danger" plain :disabled="multiple" icon="Delete" @click="handleDelete()">
删除
</el-button>
<el-button v-hasPermi="['system:user:edit']" type="warning" plain icon="Unlock" :disabled="single" @click="handleUnlock()">
解锁
</el-button>
<el-dropdown class="mt-[1px]">
<el-button plain type="info">
更多
@@ -511,6 +514,16 @@ const handleDelete = async (row?: UserVO) => {
}
};
/** 解锁按钮操作 */
const handleUnlock = async () => {
const userId = ids.value[0];
const [err] = await to(proxy?.$modal.confirm('是否确认解锁用户编号为"' + userId + '"的数据项?') as any);
if (!err) {
await api.unlockUser(userId);
proxy?.$modal.msgSuccess('用户编号"' + userId + '"解锁成功');
}
};
/** 用户状态修改 */
const handleStatusChange = async (row: UserVO) => {
const text = row.status === '0' ? '启用' : '停用';