yxk-20260525-通用的审批历史表:
1、按开始时间倒序排序 2、去掉原有的审批意见列表,仅展示流程图
This commit is contained in:
+6
-5
@@ -15,8 +15,9 @@
|
||||
import { list as queryApprovalOpinionList } from '/@/views/taskApprovalOpinion/TaskApprovalOpinion.api';
|
||||
|
||||
const approvalHistoryColumns: BasicColumn[] = [
|
||||
{ title: '办理时间', dataIndex: 'opTime', width: 170, align: 'center' },
|
||||
{ title: '节点名称', dataIndex: 'taskName', width: 160, align: 'center' },
|
||||
{ title: '开始时间', dataIndex: 'startTime', width: 170, align: 'center' },
|
||||
{ title: '办理时间', dataIndex: 'opTime', width: 170, align: 'center' },
|
||||
{
|
||||
title: '办理人',
|
||||
dataIndex: 'opUserName',
|
||||
@@ -25,7 +26,7 @@
|
||||
customRender: ({ record }) => record.opUserName || record.opUserId || '-',
|
||||
},
|
||||
{ title: '操作类型', dataIndex: 'actionType', width: 120, align: 'center' },
|
||||
{ title: '操作结果', dataIndex: 'actionResult', width: 180, align: 'center' },
|
||||
// { title: '操作结果', dataIndex: 'actionResult', width: 180, align: 'center' },
|
||||
{ title: '审批意见', dataIndex: 'opinion', align: 'left' },
|
||||
];
|
||||
|
||||
@@ -56,7 +57,7 @@
|
||||
pagination: {
|
||||
pageSize: 10,
|
||||
},
|
||||
scroll: { x: 980 },
|
||||
scroll: { x: 1150 },
|
||||
});
|
||||
|
||||
// 按流程实例查询审批历史,只查 task_approval_opinion 表
|
||||
@@ -71,8 +72,8 @@
|
||||
return queryApprovalOpinionList({
|
||||
...params,
|
||||
processInstId,
|
||||
column: 'opTime',
|
||||
order: 'desc',
|
||||
column: 'startTime',
|
||||
order: 'asc',
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
+53
-52
@@ -1,15 +1,13 @@
|
||||
<template>
|
||||
<div>
|
||||
<div style="margin-bottom: 20px; height: 400px; overflow: hidden; overflow-y: auto; overflow-x: auto">
|
||||
<bpm-graphic :instanceId="formData.procInsId" @task="getTaskList"></bpm-graphic>
|
||||
</div>
|
||||
<a-card title="流程历史跟踪">
|
||||
<div class="trace-graphic-wrapper">
|
||||
<bpm-graphic :instanceId="formData.procInsId" @task="getTaskList"></bpm-graphic>
|
||||
<!-- <a-card title="流程历史跟踪">
|
||||
<BasicTable @register="registerTable">
|
||||
<template #remarks="{ record }">
|
||||
<j-ellipsis :value="getNodeInfo(record)" :length="25" />
|
||||
</template>
|
||||
</BasicTable>
|
||||
</a-card>
|
||||
</a-card> -->
|
||||
</div>
|
||||
</template>
|
||||
|
||||
@@ -18,19 +16,19 @@
|
||||
* 历史任务跟踪-查看历史节点-流程图
|
||||
*/
|
||||
import BpmGraphic from '/@/views/super/bpm/process/components/BpmGraphic.vue';
|
||||
import { BasicTable } from '/@/components/Table';
|
||||
import { taskTraceColumns } from '../task.handle.data';
|
||||
import { taskTraceList } from '../task.handle.api';
|
||||
import { useListPage } from '/@/hooks/system/useListPage';
|
||||
import JEllipsis from '/@/components/Form/src/jeecg/components/JEllipsis.vue';
|
||||
// import { BasicTable } from '/@/components/Table';
|
||||
// import { taskTraceColumns } from '../task.handle.data';
|
||||
// import { taskTraceList } from '../task.handle.api';
|
||||
// import { useListPage } from '/@/hooks/system/useListPage';
|
||||
// import JEllipsis from '/@/components/Form/src/jeecg/components/JEllipsis.vue';
|
||||
import { ref } from 'vue';
|
||||
|
||||
export default {
|
||||
name: 'TaskTraceContent',
|
||||
components: {
|
||||
BpmGraphic,
|
||||
BasicTable,
|
||||
JEllipsis,
|
||||
// BasicTable,
|
||||
// JEllipsis,
|
||||
},
|
||||
props: {
|
||||
formData: {
|
||||
@@ -39,55 +37,58 @@
|
||||
},
|
||||
},
|
||||
setup(props) {
|
||||
console.log('进入TaskTraceContent>>');
|
||||
const { tableContext } = useListPage({
|
||||
designScope: 'task-trace-content',
|
||||
pagination: true,
|
||||
tableProps: {
|
||||
title: '',
|
||||
api: taskTraceList,
|
||||
columns: taskTraceColumns,
|
||||
showIndexColumn: true,
|
||||
showTableSetting: false,
|
||||
canResize: false,
|
||||
showActionColumn: false,
|
||||
useSearchForm: false,
|
||||
beforeFetch: (params) => {
|
||||
return addQueryParams(params);
|
||||
},
|
||||
},
|
||||
});
|
||||
const [registerTable] = tableContext;
|
||||
|
||||
function addQueryParams(params) {
|
||||
params.processInstanceId = props.formData.procInsId;
|
||||
return params;
|
||||
}
|
||||
// const { tableContext } = useListPage({
|
||||
// designScope: 'task-trace-content',
|
||||
// pagination: true,
|
||||
// tableProps: {
|
||||
// title: '',
|
||||
// api: taskTraceList,
|
||||
// columns: taskTraceColumns,
|
||||
// showIndexColumn: true,
|
||||
// showTableSetting: false,
|
||||
// canResize: false,
|
||||
// showActionColumn: false,
|
||||
// useSearchForm: false,
|
||||
// beforeFetch: (params) => {
|
||||
// return addQueryParams(params);
|
||||
// },
|
||||
// },
|
||||
// });
|
||||
// const [registerTable] = tableContext;
|
||||
//
|
||||
// function addQueryParams(params) {
|
||||
// params.processInstanceId = props.formData.procInsId;
|
||||
// return params;
|
||||
// }
|
||||
|
||||
const taskList = ref([]);
|
||||
function getTaskList(arr) {
|
||||
console.log('aaa', arr);
|
||||
taskList.value = arr;
|
||||
}
|
||||
|
||||
function getNodeInfo(record) {
|
||||
let arr = taskList.value;
|
||||
if (arr && arr.length > 0) {
|
||||
for (let item of arr) {
|
||||
if (item.id == record.id) {
|
||||
return item.remarks;
|
||||
}
|
||||
}
|
||||
}
|
||||
return '';
|
||||
}
|
||||
// function getNodeInfo(record) {
|
||||
// let arr = taskList.value;
|
||||
// if (arr && arr.length > 0) {
|
||||
// for (let item of arr) {
|
||||
// if (item.id == record.id) {
|
||||
// return item.remarks;
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
// return '';
|
||||
// }
|
||||
return {
|
||||
registerTable,
|
||||
// registerTable,
|
||||
getTaskList,
|
||||
getNodeInfo,
|
||||
// getNodeInfo,
|
||||
};
|
||||
},
|
||||
};
|
||||
</script>
|
||||
|
||||
<style scoped></style>
|
||||
<style lang="less" scoped>
|
||||
.trace-graphic-wrapper {
|
||||
height: 100%;
|
||||
overflow: auto;
|
||||
}
|
||||
</style>
|
||||
|
||||
Reference in New Issue
Block a user