1、bug修复
Some checks are pending
Gitea Actions Demo / Explore-Gitea-Actions (push) Waiting to run

2、添加巡检明细接口
This commit is contained in:
2025-07-28 17:16:27 +08:00
parent ba538a2227
commit fe78f7ad25
9 changed files with 458 additions and 85 deletions

View File

@@ -7,10 +7,18 @@ import {getDictOptions} from "#/utils/dict";
export const querySchema: FormSchemaGetter = () => [
// {
// component: 'Input',
// fieldName: 'actUserId',
// label: '当前巡检人',
// },
{
component: 'Input',
fieldName: 'actUserId',
label: '当前巡检人',
label: '签到类型',
fieldName: 'signType',
component: 'Select',
componentProps: {
options:getDictOptions('wy_xjqdfs')
},
},
{
component: 'Select',
@@ -24,64 +32,94 @@ export const querySchema: FormSchemaGetter = () => [
export const columns: VxeGridProps['columns'] = [
{ type: 'checkbox', width: 60 },
{
title: '任务编号',
field: 'id',
width:'auto'
},
{
title: '巡检计划',
field: 'planName',
minWidth:200
},
{
title: '巡检时间范围',
field: 'planInsTime',
width:'auto'
},
// {
// title: '任务编号',
// field: 'id',
// width:'auto'
// },
// {
// title: '实际巡检时间',
// field: 'endDate',
// width:180
// title: '巡检计划',
// field: 'planName',
// minWidth:200
// },
// {
// title: '巡检时间范围',
// field: 'planInsTime',
// width:'auto'
//
// },
// // {
// // title: '实际巡检时间',
// // field: 'endDate',
// // width:180
// //
// // },
// {
// title: '签到状态',
// field: 'actInsTime',
// width:150,
// },
// {
// title: '巡检人',
// field: 'planUserName',
// width:'auto'
//
// },
// {
// title: '巡检方式',
// field: 'taskType',
// width:'auto',
// slots: {
// default: ({ row }) => {
// return renderDict(row.taskType, 'wy_xjqdfs');
// },
// },
// },
{
title: '签到状态',
field: 'actInsTime',
title: '签到类型',
field: 'signType',
width:150,
},
{
title: '巡检人',
field: 'planUserName',
width:'auto'
},
{
title: '巡检方式',
field: 'taskType',
width:'auto',
slots: {
default: ({ row }) => {
return renderDict(row.taskType, 'wy_xjqdfs');
return renderDict(row.signType, 'wy_xjqdfs');
},
},
},
{
title: '巡检状态',
field: 'status',
width:100,
width:150,
slots: {
default: ({ row }) => {
return renderDict(row.taskType, 'wy_xjzt');
return renderDict(row.inspectionState, 'wy_xjzt');
},
},
},
{
title: '巡检照片',
field: 'remark',
field: 'inspectionImage',
width:120
},
{
title: '开始时间',
field: 'pointStartTime',
width:150
},
{
title: '结束时间',
field: 'pointEndTime',
width:150
},
{
title: '实际巡检时间',
field: 'inspectionTime',
width:150
},
{
title: '备注',
field: 'remark',
minWidth:120
},
// {
// field: 'action',
// fixed: 'right',

View File

@@ -8,15 +8,15 @@ import {
type VxeGridProps
} from '#/adapter/vxe-table';
import {
inspectionTaskExport,
inspectionTaskList,
} from '#/api/property/inspectionManagement/inspectionTask';
import type {InspectionTaskForm} from '#/api/property/inspectionManagement/inspectionTask/model';
import {commonDownloadExcel} from '#/utils/file/download';
import inspectionDetailsModal from './inspectionDetails-modal.vue';
import {columns, querySchema} from './data';
import {
taskDetailExport,
taskDetailList
} from "#/api/property/inspectionManagement/inspectionDetail";
const formOptions: VbenFormProps = {
commonConfig: {
@@ -46,7 +46,7 @@ const gridOptions: VxeGridProps = {
proxyConfig: {
ajax: {
query: async ({page}, formValues = {}) => {
return await inspectionTaskList({
return await taskDetailList({
pageNum: page.currentPage,
pageSize: page.pageSize,
...formValues,
@@ -77,7 +77,7 @@ async function handInfo(row: Required<InspectionTaskForm>) {
}
function handleDownloadExcel() {
commonDownloadExcel(inspectionTaskExport, '巡检任务数据', tableApi.formApi.form.values, {
commonDownloadExcel(taskDetailExport, '巡检明细数据', tableApi.formApi.form.values, {
fieldMappingTime: formOptions.fieldMappingTime,
});
}
@@ -97,7 +97,7 @@ function handleDownloadExcel() {
</Space>
</template>
<template #action="{ row }">
<!-- <template #action="{ row }">-->
<!-- <Space>-->
<!-- <ghost-button-->
<!-- v-access:code="['property:inspectionTask:info']"-->
@@ -106,7 +106,7 @@ function handleDownloadExcel() {
<!-- {{ $t('pages.common.info') }}-->
<!-- </ghost-button>-->
<!-- </Space>-->
</template>
<!-- </template>-->
</BasicTable>
<InspectionDetailsModal @reload="tableApi.query()"/>
</Page>