This commit is contained in:
Putoo
2026-05-18 18:12:21 +08:00
parent 571877970b
commit 2037d1e577
20 changed files with 555 additions and 77 deletions

View File

@@ -4,7 +4,11 @@
export class MessageExtend {
// 消息通知
static Notify(message: any, type?: 'primary' | 'success' | 'danger' | 'warning') {
showNotify({ type, message })
showNotify({
type: type,
message: message,
duration: 1500,
});
}
// 提示弹窗
@@ -12,6 +16,16 @@ export class MessageExtend {
showDialog({ title: title, message: message })
}
static ShowDialogEvent(title: string, message: string, onConfirm?: () => void, confirmButtonText?: string) {
showDialog({
title: title,
message: message,
confirmButtonText: confirmButtonText || '确认'
}).then(() => {
onConfirm?.()
});
}
// 确认提示弹窗
static ShowConfirmDialog(title: string, message: string, onConfirm?: () => void, onCancel?: () => void, confirmButtonText?: string) {
showConfirmDialog({