Vue3 重构:基本完善完 邮件模版 的重构
This commit is contained in:
@ -28,6 +28,14 @@
|
||||
v-model:currentPage="tableObject.currentPage"
|
||||
>
|
||||
<template #action="{ row }">
|
||||
<el-button
|
||||
link
|
||||
type="primary"
|
||||
@click="openSend(row.id)"
|
||||
v-hasPermi="['system:mail-template:send-mail']"
|
||||
>
|
||||
测试
|
||||
</el-button>
|
||||
<el-button
|
||||
link
|
||||
type="primary"
|
||||
@ -50,11 +58,15 @@
|
||||
|
||||
<!-- 表单弹窗:添加/修改 -->
|
||||
<mail-template-form ref="modalRef" @success="getList" />
|
||||
|
||||
<!-- 表单弹窗:发送测试 -->
|
||||
<mail-template-send ref="sendRef" />
|
||||
</template>
|
||||
<script setup lang="ts" name="MailTemplate">
|
||||
import { allSchemas } from './template.data'
|
||||
import * as MailTemplateApi from '@/api/system/mail/template'
|
||||
import MailTemplateForm from './form.vue'
|
||||
import MailTemplateSend from './send.vue'
|
||||
|
||||
// tableObject:表格的属性对象,可获得分页大小、条数等属性
|
||||
// tableMethods:表格的操作对象,可进行获得分页、删除记录等操作
|
||||
@ -77,6 +89,12 @@ const handleDelete = (id: number) => {
|
||||
tableMethods.delList(id, false)
|
||||
}
|
||||
|
||||
/** 发送测试操作 */
|
||||
const sendRef = ref()
|
||||
const openSend = (id: number) => {
|
||||
sendRef.value.openModal(id)
|
||||
}
|
||||
|
||||
/** 初始化 **/
|
||||
onMounted(() => {
|
||||
getList()
|
||||
|
||||
Reference in New Issue
Block a user