用户管理密码设置优化

This commit is contained in:
阿辉
2025-01-07 17:38:01 +08:00
parent 15c87ddd26
commit 2015db53ab
2 changed files with 38 additions and 39 deletions

View File

@@ -100,10 +100,7 @@ export const createCrudOptions = function ({ crudExpose, context }: CreateCrudOp
placement: 'top',
content: '重设密码',
},
click: (ctx: any) => {
const { row } = ctx;
context?.handleResetPwdOpen(row);
},
click: (ctx: any) => context?.handleResetPwdOpen(ctx.row),
},
},
},

View File

@@ -18,6 +18,7 @@ import {storeToRefs} from "pinia";
import { computed } from "vue";
import { Md5 } from 'ts-md5';
import { commonCrudConfig } from "/@/utils/commonCrud";
import { ElMessageBox } from 'element-plus';
export const createCrudOptions = function ({ crudExpose }: CreateCrudOptionsProps): CreateCrudOptionsRet {
const pageRequest = async (query: UserPageQuery) => {
return await api.GetList(query);
@@ -79,9 +80,10 @@ export const createCrudOptions = function ({crudExpose}: CreateCrudOptionsProps)
text: "导出",//按钮文字
title: "导出",//鼠标停留显示的信息
show: auth('user:Export'),
click() {
return exportRequest(crudExpose!.getSearchFormData())
}
click: (ctx: any) => ElMessageBox.confirm(
'确定重设密码吗?', '提示',
{ confirmButtonText: '确定', cancelButtonText: '取消', type: 'warning' }
).then(() => resetToDefaultPasswordRequest(ctx.row))
}
}
},