diff --git a/src/api/system/mail/template.ts b/src/api/system/mail/template.ts
index e66a8d4c..c571a916 100644
--- a/src/api/system/mail/template.ts
+++ b/src/api/system/mail/template.ts
@@ -25,7 +25,30 @@ export function getMailTemplatePage(params) {
return defHttp.get({ url: '/system/mail-template/page', params })
}
+// 邮件模板
+export type MailTemplate = {
+ name: string // 标题
+ code: string // 编码
+ accountId: number
+ nickname: string // 发送人
+ title: string // 标题
+ content: string // 内容
+ status: number //
+ remark?: any // 备注
+ id: number
+ params: string[] // 模板里的参数
+ createTime: number
+}
+
+export type SendMailParams = {
+ mail: string
+ templateCode: string
+ templateParams: {
+ [key: string]: any
+ }
+}
+
// 发送测试邮件
-export function sendMail(data) {
+export function sendMail(data: SendMailParams) {
return defHttp.post({ url: '/system/mail-template/send-mail', data })
}
diff --git a/src/views/system/mail/template/SendMailModal.vue b/src/views/system/mail/template/SendMailModal.vue
new file mode 100644
index 00000000..84d9a174
--- /dev/null
+++ b/src/views/system/mail/template/SendMailModal.vue
@@ -0,0 +1,90 @@
+
+
+
+
+
+
+
+
+
diff --git a/src/views/system/mail/template/TemplateModal.vue b/src/views/system/mail/template/TemplateModal.vue
index 19cb2d26..7f0a5f6e 100644
--- a/src/views/system/mail/template/TemplateModal.vue
+++ b/src/views/system/mail/template/TemplateModal.vue
@@ -20,7 +20,7 @@ const emit = defineEmits(['success', 'register'])
const isUpdate = ref(true)
const [registerForm, { setFieldsValue, resetFields, validate }] = useForm({
- labelWidth: 120,
+ labelWidth: 100,
baseColProps: { span: 24 },
schemas: formSchema,
showActionButtonGroup: false,
diff --git a/src/views/system/mail/template/index.vue b/src/views/system/mail/template/index.vue
index cb95d762..07f8524c 100644
--- a/src/views/system/mail/template/index.vue
+++ b/src/views/system/mail/template/index.vue
@@ -38,7 +38,8 @@
-
+
+