Merge branch 'master' of http://47.115.223.229:8888/yangjun/dbsd_tjbbfx
# Conflicts: # jeecgboot-vue3/src/views/bl/blTeacherInfo/BlTeacherInfoList.vue
This commit is contained in:
commit
66aba75f64
|
@ -11,6 +11,7 @@ enum Api {
|
|||
deleteBatch = '/blStuInfo/blStuInfo/deleteBatch',
|
||||
importExcel = '/blStuAnswer/blStuAnswer/importExcel',
|
||||
exportXls = '/blStuAnswer/blStuAnswer/exportXls',
|
||||
reloadCreate = '/blStuAnswer/blStuAnswer/createWord',
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -30,6 +31,8 @@ export const getImportUrl = Api.importExcel;
|
|||
*/
|
||||
export const list = (params) => defHttp.get({ url: Api.list, params });
|
||||
|
||||
export const reloadCreateFn = (params) => defHttp.get({ url: Api.reloadCreate, params });
|
||||
|
||||
/**
|
||||
* 删除单个
|
||||
* @param params
|
||||
|
|
|
@ -24,9 +24,11 @@
|
|||
<BasicTable @register="registerTable" >
|
||||
<!--插槽:table标题-->
|
||||
<template #tableTitle>
|
||||
<a-button type="primary" @click="handleAdd" preIcon="ant-design:plus-outlined"> 新增</a-button>
|
||||
<a-button type="primary" preIcon="ant-design:export-outlined" @click="onExportXls"> 下载导出模板</a-button>
|
||||
<!-- <a-button type="primary" @click="handleAdd" preIcon="ant-design:plus-outlined"> 新增</a-button> -->
|
||||
<a-button type="primary" @click="handleV2Add" preIcon="ant-design:plus-outlined"> 新增</a-button>
|
||||
<a-button type="primary" preIcon="ant-design:export-outlined" @click="onExportXls"> 下载导入模板</a-button>
|
||||
<!-- <j-upload-button type="primary" preIcon="ant-design:import-outlined" @click="onImportXls">导入</j-upload-button> -->
|
||||
<a-switch hidden v-model:checked="reloadCreateBtn" checked-children="显示" un-checked-children="不显示"/>
|
||||
</template>
|
||||
<!--操作栏-->
|
||||
<template #action="{ record }">
|
||||
|
@ -40,6 +42,7 @@
|
|||
</BasicTable>
|
||||
<!-- 表单区域 -->
|
||||
<BlStuInfoModal ref="registerModal" @success="handleSuccess"></BlStuInfoModal>
|
||||
<BlStuInfoV2Modal ref="registerV2Modal" @success="handleSuccess"></BlStuInfoV2Modal>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
|
@ -48,9 +51,10 @@
|
|||
import { BasicTable, useTable, TableAction } from '/@/components/Table';
|
||||
import { useListPage } from '/@/hooks/system/useListPage';
|
||||
import { columns, superQuerySchema } from './BlStuInfo.data';
|
||||
import { list, deleteOne, batchDelete, getImportUrl, getExportUrl } from './BlStuInfo.api';
|
||||
import { list, deleteOne, batchDelete, getImportUrl, getExportUrl, reloadCreateFn } from './BlStuInfo.api';
|
||||
import { downloadFile } from '/@/utils/common/renderUtils';
|
||||
import BlStuInfoModal from './components/BlStuInfoModal.vue'
|
||||
import BlStuInfoV2Modal from './components/BlStuInfoV2Modal.vue'
|
||||
import { useUserStore } from '/@/store/modules/user';
|
||||
import { useMethods } from '/@/hooks/system/useMethods';
|
||||
import { useMessage } from '/@/hooks/web/useMessage';
|
||||
|
@ -63,12 +67,14 @@ const $message = useMessage();
|
|||
const formRef = ref();
|
||||
const queryParam = reactive<any>({});
|
||||
const toggleSearchStatus = ref<boolean>(false);
|
||||
const reloadCreateBtn = ref<boolean>(false);
|
||||
const registerModal = ref();
|
||||
const registerV2Modal = ref();
|
||||
const userStore = useUserStore();
|
||||
//注册table数据
|
||||
const { prefixCls, tableContext, onExportXls, onImportXls } = useListPage({
|
||||
tableProps: {
|
||||
title: '教师调研报告',
|
||||
title: '学生调研报告',
|
||||
api: list,
|
||||
columns,
|
||||
canResize:false,
|
||||
|
@ -82,7 +88,7 @@ const $message = useMessage();
|
|||
},
|
||||
},
|
||||
exportConfig: {
|
||||
name: "教师问卷详细信息",
|
||||
name: "学生问卷详细信息",
|
||||
url: getExportUrl,
|
||||
params: { ...queryParam,id:-1},
|
||||
},
|
||||
|
@ -124,6 +130,11 @@ const $message = useMessage();
|
|||
registerModal.value.add();
|
||||
}
|
||||
|
||||
function handleV2Add(){
|
||||
registerV2Modal.value.disableSubmit = true;
|
||||
registerV2Modal.value.add();
|
||||
}
|
||||
|
||||
/**
|
||||
* 编辑事件
|
||||
*/
|
||||
|
@ -160,7 +171,7 @@ const $message = useMessage();
|
|||
let title = "11111";
|
||||
let paramsForm = {id:record.id};
|
||||
|
||||
let fileName = '学生问卷分析情况.docx';
|
||||
let fileName = '学生问卷分析情况.docx';
|
||||
if(record.schoolName){
|
||||
fileName = record.schoolName;
|
||||
if(record.xuenian){
|
||||
|
@ -170,7 +181,7 @@ const $message = useMessage();
|
|||
}
|
||||
let url = realUrl
|
||||
|
||||
const data = await defHttp.get({ url, params: paramsForm, responseType: 'blob',timeout: 999999 }, { isTransformResponse: false, });
|
||||
const data = await defHttp.get({ url, params: paramsForm, responseType: 'blob',timeout: 99999999 }, { isTransformResponse: false,timeout: 99999999 });
|
||||
if (!data) {
|
||||
// createMessage.warning('文件下载失败');
|
||||
return;
|
||||
|
@ -202,18 +213,24 @@ const $message = useMessage();
|
|||
*/
|
||||
function getTableAction(record) {
|
||||
return [
|
||||
// {
|
||||
// label: '编辑',
|
||||
// onClick: handleEdit.bind(null, record),
|
||||
// },
|
||||
{
|
||||
label: '编辑',
|
||||
onClick: handleEdit.bind(null, record),
|
||||
label: '下载报告',
|
||||
onClick: downloadFile.bind(null, record.filePath),
|
||||
},
|
||||
// {
|
||||
// label: '详情',
|
||||
// onClick: handleDetail.bind(null, record),
|
||||
// },
|
||||
{
|
||||
ifShow: reloadCreateBtn.value,
|
||||
label: '重新生成',
|
||||
onClick: reloadCreateFn.bind(null, record),
|
||||
},
|
||||
{
|
||||
label: '报表',
|
||||
onClick: handleTjfx.bind(null, record),
|
||||
},
|
||||
{
|
||||
label: '详情',
|
||||
onClick: handleDetail.bind(null, record),
|
||||
}, {
|
||||
label: '删除',
|
||||
popConfirm: {
|
||||
title: '是否确认删除',
|
||||
|
|
Loading…
Reference in New Issue