|
|
|
@ -1,110 +1,85 @@
|
|
|
|
|
<template> |
|
|
|
|
<ContentWrap> |
|
|
|
|
<!-- 搜索工作栏 --> |
|
|
|
|
<el-form |
|
|
|
|
class="-mb-15px" |
|
|
|
|
:model="queryParams" |
|
|
|
|
ref="queryFormRef" |
|
|
|
|
:inline="true" |
|
|
|
|
label-width="68px" |
|
|
|
|
> |
|
|
|
|
<el-form-item label="汇报标题" prop="title"> |
|
|
|
|
<el-input |
|
|
|
|
v-model="queryParams.title" |
|
|
|
|
placeholder="请输入汇报标题" |
|
|
|
|
clearable |
|
|
|
|
@keyup.enter="handleQuery" |
|
|
|
|
class="!w-240px" |
|
|
|
|
/> |
|
|
|
|
</el-form-item> |
|
|
|
|
<el-form-item label="汇报人姓名" prop="jobName"> |
|
|
|
|
<el-input |
|
|
|
|
v-model="queryParams.jobName" |
|
|
|
|
placeholder="请输入汇报人姓名" |
|
|
|
|
clearable |
|
|
|
|
@keyup.enter="handleQuery" |
|
|
|
|
class="!w-240px" |
|
|
|
|
/> |
|
|
|
|
</el-form-item> |
|
|
|
|
|
|
|
|
|
<el-form-item> |
|
|
|
|
<el-button @click="handleQuery"><Icon icon="ep:search" class="mr-5px" /> 搜索</el-button> |
|
|
|
|
<el-button @click="resetQuery"><Icon icon="ep:refresh" class="mr-5px" /> 重置</el-button> |
|
|
|
|
<el-button |
|
|
|
|
type="primary" |
|
|
|
|
plain |
|
|
|
|
@click="openForm('create')" |
|
|
|
|
v-hasPermi="['system:job-info:create']" |
|
|
|
|
> |
|
|
|
|
<Icon icon="ep:plus" class="mr-5px" /> 新增 |
|
|
|
|
</el-button> |
|
|
|
|
|
|
|
|
|
</el-form-item> |
|
|
|
|
</el-form> |
|
|
|
|
</ContentWrap> |
|
|
|
|
|
|
|
|
|
<!-- 列表 --> |
|
|
|
|
<ContentWrap> |
|
|
|
|
<el-table v-loading="loading" :data="list" :stripe="true" :show-overflow-tooltip="true"> |
|
|
|
|
<el-table-column label="汇报标题" align="center" prop="title" /> |
|
|
|
|
<el-table-column label="汇报日期" :formatter="dateFormatter2" align="center" prop="jobDate" /> |
|
|
|
|
<el-table-column label="汇报人姓名" align="center" prop="jobName" /> |
|
|
|
|
<el-table-column |
|
|
|
|
label="创建时间" |
|
|
|
|
align="center" |
|
|
|
|
prop="createTime" |
|
|
|
|
:formatter="dateFormatter" |
|
|
|
|
width="180px" |
|
|
|
|
/> |
|
|
|
|
<el-table-column label="PDF文件" align="center" prop="pdfUrl"> |
|
|
|
|
<template #default="scope"> |
|
|
|
|
<el-button |
|
|
|
|
v-if="scope.row.pdfUrl" |
|
|
|
|
link |
|
|
|
|
type="primary" |
|
|
|
|
@click="handleOpenPdf(scope.row.pdfUrl)" |
|
|
|
|
> |
|
|
|
|
查看PDF |
|
|
|
|
<section class="flex flex-col gap-20px"> |
|
|
|
|
<!-- 搜索工作栏 --> |
|
|
|
|
<el-form :model="queryParams" ref="queryFormRef" :inline="true" @submit.prevent> |
|
|
|
|
<el-form-item label="" prop="title"> |
|
|
|
|
<el-input |
|
|
|
|
v-model="queryParams.title" |
|
|
|
|
placeholder="请输入汇报标题" |
|
|
|
|
clearable |
|
|
|
|
@keyup.enter="handleQuery" |
|
|
|
|
class="!w-240px" |
|
|
|
|
/> |
|
|
|
|
</el-form-item> |
|
|
|
|
|
|
|
|
|
<el-form-item> |
|
|
|
|
<el-button @click="handleQuery" type="primary" plain> |
|
|
|
|
<Icon icon="ep:search" class="mr-5px" /> |
|
|
|
|
查询 |
|
|
|
|
</el-button> |
|
|
|
|
<span v-else>-</span> |
|
|
|
|
</template> |
|
|
|
|
</el-table-column> |
|
|
|
|
<el-table-column label="操作" align="center" min-width="120px"> |
|
|
|
|
<template #default="scope"> |
|
|
|
|
<el-button @click="resetQuery"><Icon icon="ep:refresh" class="mr-5px" /> 重置</el-button> |
|
|
|
|
</el-form-item> |
|
|
|
|
<el-form-item class="ml-auto"> |
|
|
|
|
<el-button |
|
|
|
|
link |
|
|
|
|
type="primary" |
|
|
|
|
@click="handleDetail(scope.row.id)" |
|
|
|
|
v-hasPermi="['system:job-info:update']" |
|
|
|
|
@click="openForm('create')" |
|
|
|
|
v-hasPermi="['system:job-info:create']" |
|
|
|
|
> |
|
|
|
|
生成 |
|
|
|
|
<Icon icon="ep:circle-plus" class="mr-5px" /> 新增 |
|
|
|
|
</el-button> |
|
|
|
|
<el-button |
|
|
|
|
link |
|
|
|
|
type="primary" |
|
|
|
|
@click="openForm('update', scope.row.id)" |
|
|
|
|
v-hasPermi="['system:job-info:update']" |
|
|
|
|
> |
|
|
|
|
编辑 |
|
|
|
|
</el-button> |
|
|
|
|
<el-button |
|
|
|
|
link |
|
|
|
|
type="danger" |
|
|
|
|
@click="handleDelete(scope.row.id)" |
|
|
|
|
v-hasPermi="['system:job-info:delete']" |
|
|
|
|
> |
|
|
|
|
删除 |
|
|
|
|
</el-button> |
|
|
|
|
</template> |
|
|
|
|
</el-table-column> |
|
|
|
|
</el-table> |
|
|
|
|
<!-- 分页 --> |
|
|
|
|
<Pagination |
|
|
|
|
:total="total" |
|
|
|
|
v-model:page="queryParams.pageNo" |
|
|
|
|
v-model:limit="queryParams.pageSize" |
|
|
|
|
@pagination="getList" |
|
|
|
|
/> |
|
|
|
|
</el-form-item> |
|
|
|
|
</el-form> |
|
|
|
|
|
|
|
|
|
<el-table v-loading="loading" :data="list" :show-overflow-tooltip="true"> |
|
|
|
|
<el-table-column label="汇报标题" prop="title" /> |
|
|
|
|
<el-table-column label="汇报日期" :formatter="dateFormatter2" prop="jobDate" /> |
|
|
|
|
<el-table-column label="汇报人" prop="jobName" /> |
|
|
|
|
<el-table-column |
|
|
|
|
label="创建时间" |
|
|
|
|
prop="createTime" |
|
|
|
|
:formatter="dateFormatter" |
|
|
|
|
/> |
|
|
|
|
<el-table-column label="操作选项" align="center" width="120px"> |
|
|
|
|
<template #default="scope"> |
|
|
|
|
<el-button |
|
|
|
|
link |
|
|
|
|
type="primary" |
|
|
|
|
@click="openForm('update', scope.row.id)" |
|
|
|
|
v-hasPermi="['system:job-info:update']" |
|
|
|
|
> |
|
|
|
|
编辑 |
|
|
|
|
</el-button> |
|
|
|
|
<el-button |
|
|
|
|
link |
|
|
|
|
type="primary" |
|
|
|
|
v-hasPermi="['system:job-info:update']" |
|
|
|
|
> |
|
|
|
|
下载 |
|
|
|
|
</el-button> |
|
|
|
|
<!-- <el-button--> |
|
|
|
|
<!-- link--> |
|
|
|
|
<!-- type="danger"--> |
|
|
|
|
<!-- @click="handleDelete(scope.row.id)"--> |
|
|
|
|
<!-- v-hasPermi="['system:job-info:delete']"--> |
|
|
|
|
<!-- >--> |
|
|
|
|
<!-- 删除--> |
|
|
|
|
<!-- </el-button>--> |
|
|
|
|
</template> |
|
|
|
|
</el-table-column> |
|
|
|
|
</el-table> |
|
|
|
|
|
|
|
|
|
<!-- 分页 --> |
|
|
|
|
<el-pagination |
|
|
|
|
:total="total" |
|
|
|
|
:show-page-size="false" |
|
|
|
|
layout="total, prev, pager, next" |
|
|
|
|
v-model:current-page="queryParams.pageNo" |
|
|
|
|
v-model:page-size="queryParams.pageSize" |
|
|
|
|
@change="getList" |
|
|
|
|
class="ml-auto" |
|
|
|
|
/> |
|
|
|
|
</section> |
|
|
|
|
</ContentWrap> |
|
|
|
|
|
|
|
|
|
<!-- 表单弹窗:添加/修改 --> |
|
|
|
@ -112,7 +87,7 @@
|
|
|
|
|
</template> |
|
|
|
|
|
|
|
|
|
<script setup lang="ts"> |
|
|
|
|
import { dateFormatter,dateFormatter2 } from '@/utils/formatTime' |
|
|
|
|
import { dateFormatter, dateFormatter2 } from '@/utils/formatTime' |
|
|
|
|
import download from '@/utils/download' |
|
|
|
|
import { JobInfoApi, JobInfoVO } from '@/api/system/jobinfo' |
|
|
|
|
import JobInfoForm from './JobInfoForm.vue' |
|
|
|
@ -131,7 +106,7 @@ const queryParams = reactive({
|
|
|
|
|
pageSize: 10, |
|
|
|
|
title: undefined, |
|
|
|
|
jobName: undefined, |
|
|
|
|
createTime: [], |
|
|
|
|
createTime: [] |
|
|
|
|
}) |
|
|
|
|
const queryFormRef = ref() // 搜索的表单 |
|
|
|
|
const exportLoading = ref(false) // 导出的加载中 |
|
|
|
@ -169,7 +144,6 @@ const openForm = (type: string, id?: number) => {
|
|
|
|
|
/** 生成按钮操作 */ |
|
|
|
|
const handleDetail = async (id: number) => { |
|
|
|
|
try { |
|
|
|
|
|
|
|
|
|
// 发起删除 |
|
|
|
|
await JobInfoApi.jobDetail(id) |
|
|
|
|
message.success('生成成功') |
|
|
|
@ -215,4 +189,4 @@ const handleExport = async () => {
|
|
|
|
|
onMounted(() => { |
|
|
|
|
getList() |
|
|
|
|
}) |
|
|
|
|
</script> |
|
|
|
|
</script> |
|
|
|
|