添加问卷管理报表功能
This commit is contained in:
parent
264f2b4052
commit
586136a30e
|
@ -0,0 +1,72 @@
|
|||
import { defHttp } from '/@/utils/http/axios';
|
||||
import { useMessage } from "/@/hooks/web/useMessage";
|
||||
|
||||
const { createConfirm } = useMessage();
|
||||
|
||||
enum Api {
|
||||
list = '/wjxWjxx/wjxWjxx/sysList',
|
||||
save='/wjxWjxx/wjxWjxx/sysUpdateJxnr',
|
||||
edit='/wjxWjxx/wjxWjxx/sysUpdateJxnr',
|
||||
deleteOne = '/wjxWjxx/wjxWjxx/delete',
|
||||
deleteBatch = '/wjxWjxx/wjxWjxx/deleteBatch',
|
||||
importExcel = '/wjxWjxx/wjxWjxx/importExcel',
|
||||
exportXls = '/wjxWjxx/wjxWjxx/exportSysXls',
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出api
|
||||
* @param params
|
||||
*/
|
||||
export const getExportUrl = Api.exportXls;
|
||||
|
||||
/**
|
||||
* 导入api
|
||||
*/
|
||||
export const getImportUrl = Api.importExcel;
|
||||
|
||||
/**
|
||||
* 列表接口
|
||||
* @param params
|
||||
*/
|
||||
export const list = (params) => defHttp.get({ url: Api.list, params });
|
||||
|
||||
/**
|
||||
* 删除单个
|
||||
* @param params
|
||||
* @param handleSuccess
|
||||
*/
|
||||
export const deleteOne = (params,handleSuccess) => {
|
||||
return defHttp.delete({url: Api.deleteOne, params}, {joinParamsToUrl: true}).then(() => {
|
||||
handleSuccess();
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除
|
||||
* @param params
|
||||
* @param handleSuccess
|
||||
*/
|
||||
export const batchDelete = (params, handleSuccess) => {
|
||||
createConfirm({
|
||||
iconType: 'warning',
|
||||
title: '确认删除',
|
||||
content: '是否删除选中数据',
|
||||
okText: '确认',
|
||||
cancelText: '取消',
|
||||
onOk: () => {
|
||||
return defHttp.delete({url: Api.deleteBatch, data: params}, {joinParamsToUrl: true}).then(() => {
|
||||
handleSuccess();
|
||||
});
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* 保存或者更新
|
||||
* @param params
|
||||
* @param isUpdate
|
||||
*/
|
||||
export const saveOrUpdate = (params, isUpdate) => {
|
||||
let url = isUpdate ? Api.edit : Api.save;
|
||||
return defHttp.post({ url: url, params }, { isTransformResponse: false });
|
||||
}
|
|
@ -0,0 +1,91 @@
|
|||
import {BasicColumn} from '/@/components/Table';
|
||||
import {FormSchema} from '/@/components/Table';
|
||||
import { rules} from '/@/utils/helper/validator';
|
||||
import { render } from '/@/utils/common/renderUtils';
|
||||
//列表数据
|
||||
export const columns: BasicColumn[] = [
|
||||
{
|
||||
title: '学期学年',
|
||||
align: 'center',
|
||||
dataIndex: 'xqxn',
|
||||
},
|
||||
{
|
||||
title: '开课单位',
|
||||
align: 'center',
|
||||
dataIndex: 'kkdw',
|
||||
},
|
||||
{
|
||||
title: '课程编号',
|
||||
align: 'center',
|
||||
dataIndex: 'kcbh',
|
||||
},
|
||||
{
|
||||
title: '课程名称',
|
||||
align: 'center',
|
||||
dataIndex: 'kcmc',
|
||||
},
|
||||
{
|
||||
title: '开课任务编号',
|
||||
align: 'center',
|
||||
dataIndex: 'rwbh',
|
||||
},
|
||||
{
|
||||
title: '上课时间',
|
||||
align: 'center',
|
||||
dataIndex: 'sksj',
|
||||
},
|
||||
{
|
||||
title: '上课地点',
|
||||
align: 'center',
|
||||
dataIndex: 'skdd',
|
||||
},
|
||||
{
|
||||
title: '授课教师',
|
||||
align: 'center',
|
||||
dataIndex: 'skjs',
|
||||
},
|
||||
{
|
||||
title: '选课学生',
|
||||
align: 'center',
|
||||
dataIndex: 'xkrs',
|
||||
},
|
||||
{
|
||||
title: '问卷数量',
|
||||
align: "center",
|
||||
dataIndex: 'num',
|
||||
},
|
||||
// {
|
||||
// title: '课程简介',
|
||||
// align: 'center',
|
||||
// dataIndex: 'kcjs',
|
||||
// },
|
||||
// {
|
||||
// title: '教学日历',
|
||||
// align: "center",
|
||||
// dataIndex: 'jxrlFilePath',
|
||||
// slots: { customRender: 'fileSlot2' },
|
||||
// width: '300'
|
||||
// },
|
||||
];
|
||||
|
||||
//查询数据
|
||||
export const searchFormSchema: FormSchema[] = [
|
||||
];
|
||||
|
||||
//表单数据
|
||||
export const formSchema: FormSchema[] = [
|
||||
{
|
||||
label: '附件',
|
||||
field: 'filePath',
|
||||
component: 'JUpload',
|
||||
componentProps:{
|
||||
},
|
||||
},
|
||||
// TODO 主键隐藏字段,目前写死为ID
|
||||
{
|
||||
label: '',
|
||||
field: 'id',
|
||||
component: 'Input',
|
||||
show: false,
|
||||
},
|
||||
];
|
|
@ -0,0 +1,275 @@
|
|||
<template>
|
||||
<div>
|
||||
<!--查询区域-->
|
||||
<div class="jeecg-basic-table-form-container">
|
||||
<a-form @keyup.enter.native="searchQuery" :model="queryParam" :label-col="labelCol" :wrapper-col="wrapperCol">
|
||||
<a-row :gutter="24">
|
||||
<a-col :lg="6">
|
||||
<a-form-item label="学期学年">
|
||||
<j-dict-select-tag ref="xqDictTag" placeholder="请选择学年学期" v-model:value="queryParam.xqxn" dictCode="kc_xqxn_history,title,title,true order by start_time desc"/>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :lg="6">
|
||||
<a-form-item label="开课单位">
|
||||
<!-- <a-input placeholder="请输入开课单位" v-model:value="queryParam.kkdw"/> -->
|
||||
<JDictSelectTag placeholder="开课单位" v-model:value="queryParam.kkdw" :dictCode="`kc_kkdw_view,kkdw,kkdw`"/>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :lg="6">
|
||||
<a-form-item label="课程名称">
|
||||
<a-input placeholder="请输入课程名称" v-model:value="queryParam.kcmc"/>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :lg="6">
|
||||
<a-form-item label="课程编号">
|
||||
<a-input placeholder="请输入课程编号" v-model:value="queryParam.kcbh"/>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :lg="6">
|
||||
<a-form-item label="授课教师">
|
||||
<a-input placeholder="请输入授课教师" v-model:value="queryParam.skjs"/>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :xl="6" :lg="6" :md="8" :sm="24">
|
||||
<span style="float: left; overflow: hidden" class="table-page-search-submitButtons">
|
||||
<a-col :lg="6">
|
||||
<a-button type="primary" preIcon="ant-design:search-outlined" @click="searchQuery">查询</a-button>
|
||||
<a-button type="primary" preIcon="ant-design:reload-outlined" @click="searchReset" style="margin-left: 8px">重置</a-button>
|
||||
<!-- <a-button type="primary" preIcon="ant-design:plus-outlined" @click="handleAdd" style="margin-left: 8px"> 新增</a-button> -->
|
||||
<a-button type="primary" preIcon="ant-design:export-outlined" @click="onExportXls" style="margin-left: 8px"> 导出</a-button>
|
||||
</a-col>
|
||||
</span>
|
||||
</a-col>
|
||||
</a-row>
|
||||
</a-form>
|
||||
</div>
|
||||
<!--引用表格-->
|
||||
<BasicTable @register="registerTable" >
|
||||
<!--插槽:table标题-->
|
||||
<!--操作栏-->
|
||||
<template #action="{ record }">
|
||||
<TableAction :actions="getTableAction(record)" />
|
||||
</template>
|
||||
<!--字段回显插槽-->
|
||||
<template #htmlSlot="{text}">
|
||||
<div v-html="text"></div>
|
||||
</template>
|
||||
<!--省市区字段回显插槽-->
|
||||
<!--<template #pcaSlot="{text}">
|
||||
{{ getAreaTextByCode(text) }}
|
||||
</template>-->
|
||||
<template #fileSlot="{text,record}">
|
||||
<span v-if="!text" style="font-size: 12px;font-style: italic;">无文件</span>
|
||||
<span v-else >
|
||||
<a-button :ghost="true" type="primary" preIcon="ant-design:download-outlined" size="small" @click="downloadFile(text)">下载</a-button>
|
||||
<a-button :ghost="true" type="primary" preIcon="ant-design:copy-outlined" size="small" @click="openPdf(record.pdfPath)" style="margin-left:5px;">预览</a-button>
|
||||
</span>
|
||||
</template>
|
||||
<template #fileSlot2="{text,record}">
|
||||
<span v-if="!text" style="font-size: 12px;font-style: italic;">无文件</span>
|
||||
<span v-else >
|
||||
<a-button :ghost="true" type="primary" preIcon="ant-design:download-outlined" size="small" @click="downloadFile(text)">下载</a-button>
|
||||
<a-button :ghost="true" type="primary" preIcon="ant-design:copy-outlined" size="small" @click="openPdf(record.jxrlPdfPath)" style="margin-left:5px;">预览</a-button>
|
||||
</span>
|
||||
</template>
|
||||
</BasicTable>
|
||||
<!-- 表单区域 -->
|
||||
<ZyJxdgModal ref="registerModal" @success="handleSuccess"></ZyJxdgModal>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script lang="ts" name="zyJxdg-zyJxdg" setup>
|
||||
import { ref, reactive } from 'vue';
|
||||
import { BasicTable, useTable, TableAction } from '/@/components/Table';
|
||||
import { useListPage } from '/@/hooks/system/useListPage';
|
||||
import { columns } from './Kcwjgl.data';
|
||||
import { list, deleteOne, batchDelete, getImportUrl, getExportUrl } from './Kcwjgl.api';
|
||||
import { downloadFile } from '/@/utils/common/renderUtils';
|
||||
import { JInput, JDictSelectTag } from '/@/components/Form';
|
||||
import ZyJxdgModal from './components/KcwjglModal.vue'
|
||||
import { useMessage } from '/@/hooks/web/useMessage';
|
||||
import { getFileAccessHttpUrl } from '/@/utils/common/compUtils';
|
||||
import { useGlobSetting } from '/@/hooks/setting';
|
||||
|
||||
const globSetting = useGlobSetting();
|
||||
const baseApiUrl = globSetting.domainUrl;
|
||||
const { createMessage } = useMessage();
|
||||
const queryParam = ref<any>({atype:'1'});
|
||||
const toggleSearchStatus = ref<boolean>(false);
|
||||
const registerModal = ref();
|
||||
//注册table数据
|
||||
const { prefixCls, tableContext, onExportXls, onImportXls } = useListPage({
|
||||
tableProps: {
|
||||
api: list,
|
||||
columns,
|
||||
canResize:false,
|
||||
useSearchForm: false,
|
||||
actionColumn: {
|
||||
width: 120,
|
||||
fixed: 'right',
|
||||
},
|
||||
beforeFetch: (params) => {
|
||||
params.column = '',params.order = '';//新生成的默认不带排序
|
||||
return Object.assign(params, queryParam.value);
|
||||
},
|
||||
},
|
||||
exportConfig: {
|
||||
name: "课程问卷管理",
|
||||
url: getExportUrl,
|
||||
params: () => {
|
||||
return Object.assign({},queryParam.value);
|
||||
}
|
||||
},
|
||||
importConfig: {
|
||||
url: getImportUrl,
|
||||
success: handleSuccess
|
||||
},
|
||||
});
|
||||
const [registerTable, { reload, collapseAll, updateTableDataRecord, findTableDataRecord, getDataSource }, { rowSelection, selectedRowKeys }] = tableContext;
|
||||
const labelCol = reactive({
|
||||
xs: { span: 24 },
|
||||
sm: { span: 7 },
|
||||
});
|
||||
const wrapperCol = reactive({
|
||||
xs: { span: 24 },
|
||||
sm: { span: 16 },
|
||||
});
|
||||
|
||||
/**
|
||||
* 新增事件
|
||||
*/
|
||||
function handleAdd() {
|
||||
registerModal.value.disableSubmit = false;
|
||||
registerModal.value.add();
|
||||
}
|
||||
|
||||
/**
|
||||
* 编辑事件
|
||||
*/
|
||||
function handleEdit(record: Recordable) {
|
||||
if(record.filePath){
|
||||
if(!record.pdfPath){
|
||||
createMessage.warning("正在向文件服务器进行传输,请稍等10秒刷新后进行编辑")
|
||||
return;
|
||||
}
|
||||
}
|
||||
if(record.jxrlFilePath){
|
||||
if(!record.jxrlPdfPath){
|
||||
createMessage.warning("正在向文件服务器进行传输,请稍等10秒刷新后进行编辑")
|
||||
return;
|
||||
}
|
||||
}
|
||||
registerModal.value.disableSubmit = false;
|
||||
registerModal.value.edit(record);
|
||||
}
|
||||
|
||||
|
||||
function openPdf(record){
|
||||
if(record){
|
||||
var url2 = getFileAccessHttpUrl(record)
|
||||
let url = baseApiUrl+"/generic/web/viewer.html?file="+encodeURIComponent(url2);
|
||||
window.open(url,"_blank")
|
||||
}else{
|
||||
createMessage.warning("正在向文件服务器进行传输,请稍等10秒刷新后进行预览")
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 详情
|
||||
*/
|
||||
function handleDetail(record: Recordable) {
|
||||
registerModal.value.disableSubmit = true;
|
||||
registerModal.value.edit(record);
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除事件
|
||||
*/
|
||||
async function handleDelete(record) {
|
||||
await deleteOne({ id: record.id }, handleSuccess);
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除事件
|
||||
*/
|
||||
async function batchHandleDelete() {
|
||||
await batchDelete({ ids: selectedRowKeys.value }, handleSuccess);
|
||||
}
|
||||
|
||||
/**
|
||||
* 成功回调
|
||||
*/
|
||||
function handleSuccess() {
|
||||
(selectedRowKeys.value = []) && reload();
|
||||
}
|
||||
|
||||
/**
|
||||
* 操作栏
|
||||
*/
|
||||
function getTableAction(record) {
|
||||
return [
|
||||
{
|
||||
label: '详情',
|
||||
onClick: handleDetail.bind(null, record),
|
||||
},
|
||||
];
|
||||
}
|
||||
|
||||
/**
|
||||
* 下拉操作栏
|
||||
*/
|
||||
function getDropDownAction(record) {
|
||||
return [
|
||||
{
|
||||
label: '详情',
|
||||
onClick: handleDetail.bind(null, record),
|
||||
}, {
|
||||
label: '删除',
|
||||
popConfirm: {
|
||||
title: '是否确认删除',
|
||||
confirm: handleDelete.bind(null, record),
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询
|
||||
*/
|
||||
function searchQuery() {
|
||||
reload();
|
||||
}
|
||||
|
||||
/**
|
||||
* 重置
|
||||
*/
|
||||
function searchReset() {
|
||||
queryParam.value = {};
|
||||
selectedRowKeys.value = [];
|
||||
//刷新数据
|
||||
reload();
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
</script>
|
||||
|
||||
<style lang="less" scoped>
|
||||
.jeecg-basic-table-form-container {
|
||||
.table-page-search-submitButtons {
|
||||
display: block;
|
||||
margin-bottom: 24px;
|
||||
white-space: nowrap;
|
||||
}
|
||||
.query-group-cust{
|
||||
width: calc(50% - 15px);
|
||||
min-width: 100px !important;
|
||||
}
|
||||
.query-group-split-cust{
|
||||
width: 30px;
|
||||
display: inline-block;
|
||||
text-align: center
|
||||
}
|
||||
}
|
||||
</style>
|
|
@ -0,0 +1,306 @@
|
|||
<template>
|
||||
<div style="background: #fff;height: calc(100vh - 255px);overflow-y: auto;margin: 10px 0;">
|
||||
<!--查询区域-->
|
||||
<div class="jeecg-basic-table-form-container">
|
||||
<a-form @keyup.enter.native="searchQuery" :model="queryParam" :label-col="labelCol" :wrapper-col="wrapperCol">
|
||||
<a-row :gutter="24">
|
||||
<a-col :lg="12">
|
||||
<a-form-item label="测验名称">
|
||||
<a-input placeholder="请输入测验名称" v-model:value="queryParam.title"></a-input>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :lg="12">
|
||||
<a-form-item label="测验状态">
|
||||
<j-dict-select-tag placeholder="请选择测验状态" v-model:value="queryParam.qpublish" dictCode="zy_status"/>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :lg="12">
|
||||
<a-button type="primary" preIcon="ant-design:search-outlined" @click="searchQuery">查询</a-button>
|
||||
<a-button type="primary" preIcon="ant-design:reload-outlined" @click="searchReset" style="margin-left: 8px">重置</a-button>
|
||||
</a-col>
|
||||
</a-row>
|
||||
</a-form>
|
||||
</div>
|
||||
<a-row style="overflow:hidden;">
|
||||
<a-col :lg="8" v-for="(item, index) in tableData" :key="index" style="padding: 0px 0px 5px 5px;overflow:hidden;">
|
||||
<div style="width: 100%; height: 20px; background-color: rgb(28, 132, 198);"></div>
|
||||
<a-card style="height: 256px;border: 1px solid rgb(28, 132, 198);">
|
||||
<div class="rotate" :style="classFun(item.qpublish)">{{item.qpublish_dictText}}</div>
|
||||
<a-row style="top: -48px;position: relative;">
|
||||
<a-col :span="24" style="margin-bottom: 10px;height:53px;overflow:hidden;">
|
||||
<div style="font-size: 18px;font-weight: bold;">{{item.title}}</div>
|
||||
</a-col>
|
||||
<a-col :span="24" class="zyCon">
|
||||
<a-row>
|
||||
<a-col :span="24" class="zyCon">时间:{{dayjs(item.startTime).format('YYYY.MM.DD')}} - {{dayjs(item.endTime).format('YYYY.MM.DD')}}</a-col>
|
||||
</a-row>
|
||||
</a-col>
|
||||
<a-col :span="24" class="zyCon">
|
||||
<a-row>
|
||||
<a-col :span="12" class="zyCon">{{item.xqxn}}</a-col>
|
||||
<a-col :span="12" class="zyCon"><div style="float:right;" @click="openXkrs(item)"><a>{{item.xkrs}}人选课</a></div></a-col>
|
||||
</a-row>
|
||||
</a-col>
|
||||
<a-col :span="24" class="zyCon">
|
||||
<a-row>
|
||||
<a-col :span="12" class="zyCon"><div style="float:left;" @click="handleDjjgs(item,'0')" v-if="item.wwcrs>0"><a>未提交:{{item.wwcrs}}人</a></div></a-col>
|
||||
<a-col :span="12" class="zyCon"><div style="float:right;" @click="handleDjjgs(item,'1')" v-if="item.ywcrs>0"><a>已提交:{{item.ywcrs}}人</a></div></a-col>
|
||||
</a-row>
|
||||
</a-col>
|
||||
<a-col :span="24" style="text-align:center;margin-top:8px;">
|
||||
<a-button type="primary" @click="handleDetail(item)" style="margin-left:5px;margin-bottom:5px;padding: 0px 4px;background:rgb(28, 132, 198);" >问卷详情</a-button>
|
||||
<a-button type="primary" @click="handlePeizhiXq(item)" style="margin-left:5px;margin-bottom:5px;padding: 0px 4px;background:rgb(28, 132, 198);" >预览题目</a-button>
|
||||
<a-button type="primary" @click="handleDjjgs(item,'')" style="margin-left:5px;margin-bottom:5px;padding: 0px 4px;background:rgb(28, 132, 198);" v-if="item.qpublish==1||item.qpublish==2">问卷结果</a-button>
|
||||
<a-button type="primary" @click="handleTjfx(item)" style="margin-left:5px;margin-bottom:5px;padding: 0px 4px;background:rgb(28, 132, 198);" v-if="item.qpublish==1||item.qpublish==2">统计分析</a-button>
|
||||
<a-button type="primary" @click="handleXzdj(item)" style="margin-left:5px;margin-bottom:5px;padding: 0px 4px;background:rgb(28, 132, 198);" v-if="item.qpublish==1||item.qpublish==2">下载答卷</a-button>
|
||||
</a-col>
|
||||
</a-row>
|
||||
</a-card>
|
||||
</a-col>
|
||||
<a-col :span="24">
|
||||
<div v-show="tableData.length>0">
|
||||
<a-pagination v-model="current" :total="total" @change="handlePageChange" :pageSize="pageSize" style="text-align: right;"/>
|
||||
</div>
|
||||
<div v-show="tableData.length==0">
|
||||
<a-empty/>
|
||||
</div>
|
||||
</a-col>
|
||||
</a-row>
|
||||
|
||||
<WjxWjxxModal ref="registerModal"></WjxWjxxModal>
|
||||
<ZyInfoStudentListModal ref="ZyInfoStudentListModalPage" ></ZyInfoStudentListModal>
|
||||
<WjxWjxxTmlbDjModal ref="WjxWjxxTmlbDjModalPage" ></WjxWjxxTmlbDjModal>
|
||||
<WjxWjxxTmlbDjjgsModal ref="WjxWjxxTmlbDjjgsModalPage" ></WjxWjxxTmlbDjjgsModal>
|
||||
<WjxWjxxTjfxModal ref="WjxWjxxTjfxModalPage"></WjxWjxxTjfxModal>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script lang="ts" setup>
|
||||
import { ref, reactive, defineExpose, nextTick, defineProps, computed, onMounted } from 'vue';
|
||||
import { defHttp } from '/@/utils/http/axios';
|
||||
import { useMessage } from '/@/hooks/web/useMessage';
|
||||
import JUpload from '/@/components/Form/src/jeecg/components/JUpload/JUpload.vue';
|
||||
import { getValueType } from '/@/utils';
|
||||
import { saveOrUpdate } from '../Kczygl.api';
|
||||
import { Form } from 'ant-design-vue';
|
||||
import WjxWjxxModal from '/@/views/kc/wjxWjxx/components/WjxWjxxModal.vue'
|
||||
import ZyInfoStudentListModal from '/@/views/zy/zyInfoStudent/ZyInfoStudentListModal.vue';
|
||||
import dayjs from 'dayjs';
|
||||
import { JInput,JDictSelectTag } from '/@/components/Form';
|
||||
import { Pagination } from 'ant-design-vue';
|
||||
import WjxWjxxTjfxModal from '/@/views/kc/wjxCswj/WjxWjxxTjfxModal.vue';
|
||||
import WjxWjxxTmlbDjjgsModal from '/@/views/kc/wjxWjxx/components/WjxWjxxTmlbDjjgsDcModal.vue'
|
||||
import WjxWjxxTmlbDjModal from '/@/views/kc/wjxWjxx/components/WjxWjxxTmlbDjModal.vue'
|
||||
|
||||
const props = defineProps({
|
||||
formDisabled: { type: Boolean, default: false },
|
||||
formData: { type: Object, default: ()=>{} },
|
||||
formBpm: { type: Boolean, default: true }
|
||||
});
|
||||
const WjxWjxxTmlbDjModalPage = ref()
|
||||
const WjxWjxxTmlbDjjgsModalPage = ref()
|
||||
const WjxWjxxTjfxModalPage = ref();
|
||||
const formRef = ref();
|
||||
const useForm = Form.useForm;
|
||||
const emit = defineEmits(['register', 'ok']);
|
||||
const formData = reactive<Record<string, any>>({
|
||||
id: '',
|
||||
filePath: '',
|
||||
jxrlFilePath: '',
|
||||
});
|
||||
const { createMessage } = useMessage();
|
||||
const labelCol = ref<any>({ xs: { span: 24 }, sm: { span: 5 } });
|
||||
const wrapperCol = ref<any>({ xs: { span: 24 }, sm: { span: 16 } });
|
||||
const confirmLoading = ref<boolean>(false);
|
||||
//表单验证
|
||||
const validatorRules = { };
|
||||
|
||||
const APagination = Pagination;
|
||||
const queryParam = ref<any>({});
|
||||
const registerModal = ref();
|
||||
const ZyInfoStudentListModalPage = ref();
|
||||
let rwbh = ref<string>('');
|
||||
let xqxn = ref<string>('');
|
||||
let teano = ref<string>('');
|
||||
let id = ref<string>('');
|
||||
const current = ref<number>(0);
|
||||
const total = ref<number>(0);
|
||||
const pageNo = ref<number>(0);
|
||||
const pageSize = ref<number>(6);
|
||||
const tableData = ref<any>([]);
|
||||
|
||||
|
||||
const { resetFields, validate, validateInfos } = useForm(formData, validatorRules, { immediate: true });
|
||||
|
||||
// 表单禁用
|
||||
const disabled = computed(()=>{
|
||||
if(props.formBpm === true){
|
||||
if(props.formData.disabled === false){
|
||||
return false;
|
||||
}else{
|
||||
return true;
|
||||
}
|
||||
}
|
||||
return props.formDisabled;
|
||||
});
|
||||
|
||||
|
||||
/**
|
||||
* 新增
|
||||
*/
|
||||
function add() {
|
||||
edit({});
|
||||
}
|
||||
|
||||
/**
|
||||
* 编辑
|
||||
*/
|
||||
function edit(record) {
|
||||
console.log(`🚀 ~ edit ~ record:`, record)
|
||||
nextTick(() => {
|
||||
resetFields();
|
||||
rwbh = record.rwbh;
|
||||
xqxn = record.xqxn;
|
||||
teano = record.jgh;
|
||||
id = record.id;
|
||||
console.log(`🚀 ~ nextTick ~ rwbh:`, rwbh)
|
||||
|
||||
reload()
|
||||
});
|
||||
}
|
||||
//统计分析
|
||||
function handleTjfx(record){
|
||||
WjxWjxxTjfxModalPage.value.disableSubmit = true;
|
||||
WjxWjxxTjfxModalPage.value.edit(record);
|
||||
}
|
||||
//下载答卷
|
||||
function handleXzdj(record){
|
||||
defHttp.get({ url: '/wjxWjxx/wjxWjxx/wjxxDownLoad', params: { id: record.id } },{timeout: 60 * 60 * 1000}).then(res => {
|
||||
console.log(`🚀 ~ defHttp.get ~ res:`, res)
|
||||
if(res.result){
|
||||
var downUrl = res.data.download_url;
|
||||
console.log(`🚀 ~ defHttp.get ~ downUrl:`, downUrl)
|
||||
if(downUrl){
|
||||
window.open(downUrl)
|
||||
}else{
|
||||
createMessage.warning("下载异常请联系管理员")
|
||||
}
|
||||
}else{
|
||||
createMessage.warning(res.errormsg)
|
||||
}
|
||||
});
|
||||
}
|
||||
/**
|
||||
* 配置详情
|
||||
*/
|
||||
function handlePeizhiXq(record: Recordable) {
|
||||
WjxWjxxTmlbDjModalPage.value.disableSubmit = true;
|
||||
WjxWjxxTmlbDjModalPage.value.edit(record,true,"1",'ls');
|
||||
}
|
||||
/**
|
||||
* 学生答卷列表
|
||||
*/
|
||||
function handleDjjgs(record: Recordable,flag) {
|
||||
WjxWjxxTmlbDjjgsModalPage.value.disableSubmit = true;
|
||||
WjxWjxxTmlbDjjgsModalPage.value.edit(record,flag);
|
||||
}
|
||||
|
||||
function reload(){
|
||||
queryParam.value.pageNo = current.value;
|
||||
queryParam.value.pageSize = pageSize.value;
|
||||
queryParam.value.rwbh = rwbh;
|
||||
queryParam.value.xqxn = xqxn;
|
||||
queryParam.value.id = id;
|
||||
queryParam.value.atype = "1";
|
||||
defHttp.get({ url: '/wjxWjxx/wjxWjxx/newlist', params: queryParam.value }).then(res => {
|
||||
total.value = res.total;
|
||||
pageNo.value = res.pages;
|
||||
current.value = res.current;
|
||||
tableData.value = res.records;
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* 详情
|
||||
*/
|
||||
function handleDetail(record: Recordable) {
|
||||
registerModal.value.disableSubmit = true;
|
||||
registerModal.value.edit(record);
|
||||
}
|
||||
|
||||
//查看作业信息
|
||||
function handleZyxx(record){
|
||||
ZyInfoStudentListModalPage.value.disableSubmit = true;
|
||||
ZyInfoStudentListModalPage.value.init(record);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询
|
||||
*/
|
||||
function searchQuery() {
|
||||
total.value = 1;
|
||||
handlePageChange(1);
|
||||
}
|
||||
|
||||
function classFun(type){
|
||||
if(type == '0'){
|
||||
return "background: #fe1a1a";
|
||||
}else if(type == '1'){
|
||||
return "background: #c6c209";
|
||||
}else if(type == '2'){
|
||||
return "background: #18a689";
|
||||
}
|
||||
}
|
||||
|
||||
function handlePageChange(record){
|
||||
current.value = record;
|
||||
reload();
|
||||
}
|
||||
/**
|
||||
* 提交数据
|
||||
*/
|
||||
async function submitForm() {
|
||||
}
|
||||
|
||||
|
||||
defineExpose({
|
||||
add,
|
||||
edit,
|
||||
submitForm,
|
||||
});
|
||||
</script>
|
||||
|
||||
<style lang="less" scoped>
|
||||
.antd-modal-form {
|
||||
min-height: 500px !important;
|
||||
overflow-y: auto;
|
||||
padding: 24px 24px 24px 24px;
|
||||
}
|
||||
|
||||
|
||||
.jeecg-basic-table-form-container .ant-form {
|
||||
padding: 12px 10px 0px 10px;
|
||||
margin-bottom: 0px;
|
||||
background-color: #fff;
|
||||
border-radius: 2px;
|
||||
}
|
||||
.ellipsis {
|
||||
overflow: hidden; /* 确保超出容器的内容被裁剪 */
|
||||
white-space: nowrap; /* 确保文本在一行内显示 */
|
||||
text-overflow: ellipsis; /* 超出部分显示省略号 */
|
||||
}
|
||||
.zyCon{
|
||||
line-height: 30px;
|
||||
}
|
||||
.rotate {
|
||||
transform: rotate(45deg);
|
||||
// background: rgb(28, 132, 198);
|
||||
color: #fff;
|
||||
padding: 19px 10px 3px 10px;
|
||||
position: relative;
|
||||
top: -54px;
|
||||
right: -131px;
|
||||
text-align: center;
|
||||
font-size: 11px;
|
||||
}
|
||||
</style>
|
|
@ -0,0 +1,75 @@
|
|||
<template>
|
||||
<a-modal :title="title" :width="width" style="top:20px;" :visible="visible" @ok="handleOk" :okButtonProps="{ class: { 'jee-hidden': disableSubmit } }" @cancel="handleCancel" cancelText="关闭">
|
||||
<ZyJxdgForm ref="registerForm" @ok="submitCallback" :formDisabled="disableSubmit" :formBpm="false"></ZyJxdgForm>
|
||||
</a-modal>
|
||||
</template>
|
||||
|
||||
<script lang="ts" setup>
|
||||
import { ref, nextTick, defineExpose } from 'vue';
|
||||
import ZyJxdgForm from './KcwjglForm.vue'
|
||||
|
||||
const title = ref<string>('');
|
||||
const width = ref<number>(900);
|
||||
const visible = ref<boolean>(false);
|
||||
const disableSubmit = ref<boolean>(false);
|
||||
const registerForm = ref();
|
||||
const emit = defineEmits(['register', 'success']);
|
||||
|
||||
/**
|
||||
* 新增
|
||||
*/
|
||||
function add() {
|
||||
title.value = '新增';
|
||||
visible.value = true;
|
||||
nextTick(() => {
|
||||
registerForm.value.add();
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* 编辑
|
||||
* @param record
|
||||
*/
|
||||
function edit(record) {
|
||||
title.value = disableSubmit.value ? '详情' : '编辑';
|
||||
visible.value = true;
|
||||
nextTick(() => {
|
||||
registerForm.value.edit(record);
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* 确定按钮点击事件
|
||||
*/
|
||||
function handleOk() {
|
||||
registerForm.value.submitForm();
|
||||
}
|
||||
|
||||
/**
|
||||
* form保存回调事件
|
||||
*/
|
||||
function submitCallback() {
|
||||
handleCancel();
|
||||
emit('success');
|
||||
}
|
||||
|
||||
/**
|
||||
* 取消按钮回调事件
|
||||
*/
|
||||
function handleCancel() {
|
||||
visible.value = false;
|
||||
}
|
||||
|
||||
defineExpose({
|
||||
add,
|
||||
edit,
|
||||
disableSubmit,
|
||||
});
|
||||
</script>
|
||||
|
||||
<style>
|
||||
/**隐藏样式-modal确定按钮 */
|
||||
.jee-hidden {
|
||||
display: none !important;
|
||||
}
|
||||
</style>
|
|
@ -0,0 +1,72 @@
|
|||
import { defHttp } from '/@/utils/http/axios';
|
||||
import { useMessage } from "/@/hooks/web/useMessage";
|
||||
|
||||
const { createConfirm } = useMessage();
|
||||
|
||||
enum Api {
|
||||
list = '/wjxDjxx/sysWjglList',
|
||||
save='/wjxDjxx/sysUpdateJxnr',
|
||||
edit='/wjxDjxx/sysUpdateJxnr',
|
||||
deleteOne = '/wjxDjxx/delete',
|
||||
deleteBatch = '/wjxDjxx/deleteBatch',
|
||||
importExcel = '/wjxDjxx/importExcel',
|
||||
exportXls = '/wjxDjxx/exportWjglSysXls',
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出api
|
||||
* @param params
|
||||
*/
|
||||
export const getExportUrl = Api.exportXls;
|
||||
|
||||
/**
|
||||
* 导入api
|
||||
*/
|
||||
export const getImportUrl = Api.importExcel;
|
||||
|
||||
/**
|
||||
* 列表接口
|
||||
* @param params
|
||||
*/
|
||||
export const list = (params) => defHttp.get({ url: Api.list, params });
|
||||
|
||||
/**
|
||||
* 删除单个
|
||||
* @param params
|
||||
* @param handleSuccess
|
||||
*/
|
||||
export const deleteOne = (params,handleSuccess) => {
|
||||
return defHttp.delete({url: Api.deleteOne, params}, {joinParamsToUrl: true}).then(() => {
|
||||
handleSuccess();
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除
|
||||
* @param params
|
||||
* @param handleSuccess
|
||||
*/
|
||||
export const batchDelete = (params, handleSuccess) => {
|
||||
createConfirm({
|
||||
iconType: 'warning',
|
||||
title: '确认删除',
|
||||
content: '是否删除选中数据',
|
||||
okText: '确认',
|
||||
cancelText: '取消',
|
||||
onOk: () => {
|
||||
return defHttp.delete({url: Api.deleteBatch, data: params}, {joinParamsToUrl: true}).then(() => {
|
||||
handleSuccess();
|
||||
});
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* 保存或者更新
|
||||
* @param params
|
||||
* @param isUpdate
|
||||
*/
|
||||
export const saveOrUpdate = (params, isUpdate) => {
|
||||
let url = isUpdate ? Api.edit : Api.save;
|
||||
return defHttp.post({ url: url, params }, { isTransformResponse: false });
|
||||
}
|
|
@ -0,0 +1,75 @@
|
|||
import {BasicColumn} from '/@/components/Table';
|
||||
import {FormSchema} from '/@/components/Table';
|
||||
import { rules} from '/@/utils/helper/validator';
|
||||
import { render } from '/@/utils/common/renderUtils';
|
||||
//列表数据
|
||||
export const columns: BasicColumn[] = [
|
||||
{
|
||||
title: '学期学年',
|
||||
align: 'center',
|
||||
dataIndex: 'xqxn',
|
||||
},
|
||||
{
|
||||
title: '课程名称',
|
||||
align: 'center',
|
||||
dataIndex: 'kcmc',
|
||||
},
|
||||
{
|
||||
title: '授课教师',
|
||||
align: 'center',
|
||||
dataIndex: 'skjs',
|
||||
},
|
||||
{
|
||||
title: '作业名称',
|
||||
align: 'center',
|
||||
dataIndex: 'title',
|
||||
},
|
||||
{
|
||||
title: '学生姓名',
|
||||
align: 'center',
|
||||
dataIndex: 'stuName',
|
||||
},
|
||||
{
|
||||
title: '学号',
|
||||
align: 'center',
|
||||
dataIndex: 'stuNo',
|
||||
},
|
||||
{
|
||||
title: '测验状态',
|
||||
align: 'center',
|
||||
dataIndex: 'status',
|
||||
},
|
||||
{
|
||||
title: '测验时间',
|
||||
align: 'center',
|
||||
dataIndex: 'createTime',
|
||||
},
|
||||
// {
|
||||
// title: '测验结果',
|
||||
// align: "center",
|
||||
// dataIndex: 'score',
|
||||
// },
|
||||
|
||||
];
|
||||
|
||||
//查询数据
|
||||
export const searchFormSchema: FormSchema[] = [
|
||||
];
|
||||
|
||||
//表单数据
|
||||
export const formSchema: FormSchema[] = [
|
||||
{
|
||||
label: '附件',
|
||||
field: 'filePath',
|
||||
component: 'JUpload',
|
||||
componentProps:{
|
||||
},
|
||||
},
|
||||
// TODO 主键隐藏字段,目前写死为ID
|
||||
{
|
||||
label: '',
|
||||
field: 'id',
|
||||
component: 'Input',
|
||||
show: false,
|
||||
},
|
||||
];
|
|
@ -0,0 +1,278 @@
|
|||
<template>
|
||||
<div>
|
||||
<!--查询区域-->
|
||||
<div class="jeecg-basic-table-form-container">
|
||||
<a-form @keyup.enter.native="searchQuery" :model="queryParam" :label-col="labelCol" :wrapper-col="wrapperCol">
|
||||
<a-row :gutter="24">
|
||||
<a-col :lg="6">
|
||||
<a-form-item label="学期学年">
|
||||
<j-dict-select-tag ref="xqDictTag" placeholder="请选择学年学期" v-model:value="queryParam.xqxn" dictCode="kc_xqxn_history,title,title,true order by start_time desc"/>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :lg="6">
|
||||
<a-form-item label="开课单位">
|
||||
<!-- <a-input placeholder="请输入开课单位" v-model:value="queryParam.kkdw"/> -->
|
||||
<JDictSelectTag placeholder="开课单位" v-model:value="queryParam.kkdw" :dictCode="`kc_kkdw_view,kkdw,kkdw`"/>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :lg="6">
|
||||
<a-form-item label="课程名称">
|
||||
<a-input placeholder="请输入课程名称" v-model:value="queryParam.kcmc"/>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :lg="6">
|
||||
<a-form-item label="课程编号">
|
||||
<a-input placeholder="请输入课程编号" v-model:value="queryParam.kcbh"/>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :lg="6">
|
||||
<a-form-item label="授课教师">
|
||||
<a-input placeholder="请输入授课教师" v-model:value="queryParam.skjs"/>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :lg="6">
|
||||
<a-form-item label="学生姓名">
|
||||
<a-input placeholder="请输入学生姓名" v-model:value="queryParam.stuName"/>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :lg="6">
|
||||
<a-form-item label="学号">
|
||||
<a-input placeholder="请输入学号" v-model:value="queryParam.stuNo"/>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :xl="6" :lg="6" :md="8" :sm="24">
|
||||
<span style="float: left; overflow: hidden" class="table-page-search-submitButtons">
|
||||
<a-col :lg="6">
|
||||
<a-button type="primary" preIcon="ant-design:search-outlined" @click="searchQuery">查询</a-button>
|
||||
<a-button type="primary" preIcon="ant-design:reload-outlined" @click="searchReset" style="margin-left: 8px">重置</a-button>
|
||||
<!-- <a-button type="primary" preIcon="ant-design:plus-outlined" @click="handleAdd" style="margin-left: 8px"> 新增</a-button> -->
|
||||
<a-button type="primary" preIcon="ant-design:export-outlined" @click="onExportXls" style="margin-left: 8px"> 导出</a-button>
|
||||
</a-col>
|
||||
</span>
|
||||
</a-col>
|
||||
</a-row>
|
||||
</a-form>
|
||||
</div>
|
||||
<!--引用表格-->
|
||||
<BasicTable @register="registerTable" >
|
||||
<!--插槽:table标题-->
|
||||
<!--操作栏-->
|
||||
<template #action="{ record }">
|
||||
<TableAction :actions="getTableAction(record)" />
|
||||
</template>
|
||||
<!--字段回显插槽-->
|
||||
<template #htmlSlot="{text}">
|
||||
<div v-html="text"></div>
|
||||
</template>
|
||||
<!--省市区字段回显插槽-->
|
||||
<!--<template #pcaSlot="{text}">
|
||||
{{ getAreaTextByCode(text) }}
|
||||
</template>-->
|
||||
<template #fileSlot="{text,record}">
|
||||
<span v-if="!text" style="font-size: 12px;font-style: italic;">无文件</span>
|
||||
<span v-else >
|
||||
<a-button :ghost="true" type="primary" preIcon="ant-design:download-outlined" size="small" @click="downloadFile(text)">下载</a-button>
|
||||
<a-button :ghost="true" type="primary" preIcon="ant-design:copy-outlined" size="small" @click="openPdf(record.pdfPath)" style="margin-left:5px;">预览</a-button>
|
||||
</span>
|
||||
</template>
|
||||
</BasicTable>
|
||||
<WjxWjxxTmlbDjjgModal ref="registerModal" ></WjxWjxxTmlbDjjgModal>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script lang="ts" name="zyJxdg-zyJxdg" setup>
|
||||
import { ref, reactive } from 'vue';
|
||||
import { BasicTable, useTable, TableAction } from '/@/components/Table';
|
||||
import { useListPage } from '/@/hooks/system/useListPage';
|
||||
import { columns } from './Studentwjgl.data';
|
||||
import { list, deleteOne, batchDelete, getImportUrl, getExportUrl } from './Studentwjgl.api';
|
||||
import { downloadFile } from '/@/utils/common/renderUtils';
|
||||
import { JInput, JDictSelectTag } from '/@/components/Form';
|
||||
import { useMessage } from '/@/hooks/web/useMessage';
|
||||
import { getFileAccessHttpUrl } from '/@/utils/common/compUtils';
|
||||
import { useGlobSetting } from '/@/hooks/setting';
|
||||
import WjxWjxxTmlbDjjgModal from '/@/views/kc/wjxWjxx/components/WjxWjxxTmlbDjjgModal.vue'
|
||||
|
||||
const globSetting = useGlobSetting();
|
||||
const baseApiUrl = globSetting.domainUrl;
|
||||
const { createMessage } = useMessage();
|
||||
const queryParam = ref<any>({atype:'1'});
|
||||
const toggleSearchStatus = ref<boolean>(false);
|
||||
const registerModal = ref();
|
||||
//注册table数据
|
||||
const { prefixCls, tableContext, onExportXls, onImportXls } = useListPage({
|
||||
tableProps: {
|
||||
api: list,
|
||||
columns,
|
||||
canResize:false,
|
||||
useSearchForm: false,
|
||||
// showActionColumn: false,
|
||||
actionColumn: {
|
||||
width: 120,
|
||||
fixed: 'right',
|
||||
},
|
||||
beforeFetch: (params) => {
|
||||
params.column = '',params.order = '';//新生成的默认不带排序
|
||||
return Object.assign(params, queryParam.value);
|
||||
},
|
||||
},
|
||||
exportConfig: {
|
||||
name: "课程问卷管理",
|
||||
url: getExportUrl,
|
||||
params: () => {
|
||||
return Object.assign({},queryParam.value);
|
||||
}
|
||||
},
|
||||
importConfig: {
|
||||
url: getImportUrl,
|
||||
success: handleSuccess
|
||||
},
|
||||
});
|
||||
const [registerTable, { reload, collapseAll, updateTableDataRecord, findTableDataRecord, getDataSource }, { rowSelection, selectedRowKeys }] = tableContext;
|
||||
const labelCol = reactive({
|
||||
xs: { span: 24 },
|
||||
sm: { span: 7 },
|
||||
});
|
||||
const wrapperCol = reactive({
|
||||
xs: { span: 24 },
|
||||
sm: { span: 16 },
|
||||
});
|
||||
|
||||
/**
|
||||
* 新增事件
|
||||
*/
|
||||
function handleAdd() {
|
||||
registerModal.value.disableSubmit = false;
|
||||
registerModal.value.add();
|
||||
}
|
||||
|
||||
/**
|
||||
* 编辑事件
|
||||
*/
|
||||
function handleEdit(record: Recordable) {
|
||||
if(record.filePath){
|
||||
if(!record.pdfPath){
|
||||
createMessage.warning("正在向文件服务器进行传输,请稍等10秒刷新后进行编辑")
|
||||
return;
|
||||
}
|
||||
}
|
||||
if(record.jxrlFilePath){
|
||||
if(!record.jxrlPdfPath){
|
||||
createMessage.warning("正在向文件服务器进行传输,请稍等10秒刷新后进行编辑")
|
||||
return;
|
||||
}
|
||||
}
|
||||
registerModal.value.disableSubmit = false;
|
||||
registerModal.value.edit(record);
|
||||
}
|
||||
|
||||
|
||||
function openPdf(record){
|
||||
if(record){
|
||||
var url2 = getFileAccessHttpUrl(record)
|
||||
let url = baseApiUrl+"/generic/web/viewer.html?file="+encodeURIComponent(url2);
|
||||
window.open(url,"_blank")
|
||||
}else{
|
||||
createMessage.warning("正在向文件服务器进行传输,请稍等10秒刷新后进行预览")
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 详情
|
||||
*/
|
||||
function handleDetail(record: Recordable) {
|
||||
registerModal.value.disableSubmit = true;
|
||||
registerModal.value.edit(record.id);
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除事件
|
||||
*/
|
||||
async function handleDelete(record) {
|
||||
await deleteOne({ id: record.id }, handleSuccess);
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除事件
|
||||
*/
|
||||
async function batchHandleDelete() {
|
||||
await batchDelete({ ids: selectedRowKeys.value }, handleSuccess);
|
||||
}
|
||||
|
||||
/**
|
||||
* 成功回调
|
||||
*/
|
||||
function handleSuccess() {
|
||||
(selectedRowKeys.value = []) && reload();
|
||||
}
|
||||
|
||||
/**
|
||||
* 操作栏
|
||||
*/
|
||||
function getTableAction(record) {
|
||||
return [
|
||||
{
|
||||
label: '详情',
|
||||
onClick: handleDetail.bind(null, record),
|
||||
},
|
||||
];
|
||||
}
|
||||
|
||||
/**
|
||||
* 下拉操作栏
|
||||
*/
|
||||
function getDropDownAction(record) {
|
||||
return [
|
||||
{
|
||||
label: '详情',
|
||||
onClick: handleDetail.bind(null, record),
|
||||
}, {
|
||||
label: '删除',
|
||||
popConfirm: {
|
||||
title: '是否确认删除',
|
||||
confirm: handleDelete.bind(null, record),
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询
|
||||
*/
|
||||
function searchQuery() {
|
||||
reload();
|
||||
}
|
||||
|
||||
/**
|
||||
* 重置
|
||||
*/
|
||||
function searchReset() {
|
||||
queryParam.value = {};
|
||||
selectedRowKeys.value = [];
|
||||
//刷新数据
|
||||
reload();
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
</script>
|
||||
|
||||
<style lang="less" scoped>
|
||||
.jeecg-basic-table-form-container {
|
||||
.table-page-search-submitButtons {
|
||||
display: block;
|
||||
margin-bottom: 24px;
|
||||
white-space: nowrap;
|
||||
}
|
||||
.query-group-cust{
|
||||
width: calc(50% - 15px);
|
||||
min-width: 100px !important;
|
||||
}
|
||||
.query-group-split-cust{
|
||||
width: 30px;
|
||||
display: inline-block;
|
||||
text-align: center
|
||||
}
|
||||
}
|
||||
</style>
|
Loading…
Reference in New Issue