From 52463eae02ebd330a704ef4728eb6520cd6f01d4 Mon Sep 17 00:00:00 2001 From: zhufu <17863654727@163.com> Date: Wed, 11 Mar 2026 16:49:39 +0800 Subject: [PATCH] =?UTF-8?q?=E7=A9=BF=E9=80=8F=E5=86=85=E5=AE=B9=E6=B7=BB?= =?UTF-8?q?=E5=8A=A0=E6=97=B6=E9=97=B4=E7=AD=9B=E9=80=89=E7=BB=93=E6=9E=9C?= =?UTF-8?q?=EF=BC=8C=E5=BC=82=E5=B8=B8=E4=B8=8A=E6=8A=A5=E6=98=BE=E7=A4=BA?= =?UTF-8?q?=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/api/illegalconstruction/statistical.ts | 12 +++---- .../ShowListModal/index.vue | 5 ++- .../ShowListModal/utils.ts | 34 +++++++++++++++++-- .../inspectionrecordpoint/index.vue | 12 ++++++- .../inspectionrecorduser/index.vue | 10 +++++- 5 files changed, 62 insertions(+), 11 deletions(-) diff --git a/src/api/illegalconstruction/statistical.ts b/src/api/illegalconstruction/statistical.ts index d7da8d2..3f4ffd7 100644 --- a/src/api/illegalconstruction/statistical.ts +++ b/src/api/illegalconstruction/statistical.ts @@ -38,19 +38,19 @@ export const getUserCountApi = (type: string, params) => { return GetDealDetailData(params) } } -export function GetPunchDetailData(params: { userid: string }) { +export function GetPunchDetailData(params: { userid: string, begindate?: string, enddate?: string }) { return defHttp.get({ url: Api.GetPunchDetailData, params, }); } -export function GetReportDetailData(params: { userid: string }) { +export function GetReportDetailData(params: { userid: string, begindate?: string, enddate?: string }) { return defHttp.get({ url: Api.GetReportDetailData, params, }); } -export function GetDealDetailData(params: { userid: string }) { +export function GetDealDetailData(params: { userid: string, begindate?: string, enddate?: string }) { return defHttp.get({ url: Api.GetDealDetailData, params, @@ -75,19 +75,19 @@ export function GetPointPunchStatistics(params) { }); } -export function GetPointPunchDetailData(params: { pointid: string }) { +export function GetPointPunchDetailData(params: { pointid: string, begindate?: string, enddate?: string }) { return defHttp.get({ url: Api.GetPointPunchDetailData, params, }); } -export function GetPointReportDetailData(params: { pointid: string }) { +export function GetPointReportDetailData(params: { pointid: string, begindate?: string, enddate?: string }) { return defHttp.get({ url: Api.GetPointReportDetailData, params, }); } -export function GetPointDealDetailData(params: { pointid: string }) { +export function GetPointDealDetailData(params: { pointid: string, begindate?: string, enddate?: string }) { return defHttp.get({ url: Api.GetPointDealDetailData, params, diff --git a/src/views/demo/illegalconstruction/inspectionrecordpoint/ShowListModal/index.vue b/src/views/demo/illegalconstruction/inspectionrecordpoint/ShowListModal/index.vue index a8f0e0e..e538e8e 100644 --- a/src/views/demo/illegalconstruction/inspectionrecordpoint/ShowListModal/index.vue +++ b/src/views/demo/illegalconstruction/inspectionrecordpoint/ShowListModal/index.vue @@ -9,7 +9,7 @@ import { BasicTable, useTable, TableAction } from '@/components/Table'; import { getColums, searchFormSchema } from './utils'; import { getPointCountApi } from '@/api/illegalconstruction/statistical' -const props = defineProps(['title','id','type']) +const props = defineProps(['title','id','type','timeParams']) const [registerTable, { setTableData, reload, clearSelectedRowKeys, setPagination, setLoading }] =useTable({ title: props.title, api: (params) => getPointCountApi(props.type, { ...params, pointid: props.id }), @@ -26,6 +26,9 @@ const [registerTable, { setTableData, reload, clearSelectedRowKeys, setPaginatio handleSearchInfoFn(info) { return info; }, + beforeFetch(params) { + return { ...params, ...props.timeParams }; + }, }); diff --git a/src/views/demo/illegalconstruction/inspectionrecordpoint/ShowListModal/utils.ts b/src/views/demo/illegalconstruction/inspectionrecordpoint/ShowListModal/utils.ts index db6bee9..b889ba8 100644 --- a/src/views/demo/illegalconstruction/inspectionrecordpoint/ShowListModal/utils.ts +++ b/src/views/demo/illegalconstruction/inspectionrecordpoint/ShowListModal/utils.ts @@ -1,5 +1,5 @@ export const punchCountColumns = [ - { + { title: '片区', dataIndex: 'CountyName', }, @@ -30,6 +30,36 @@ export const punchCountColumns = [ ] export const reportCountColumns = [ { + title: '片区', + dataIndex: 'CountyName', + }, + { + title: '乡镇', + dataIndex: 'StreetName', + }, + { + title: '村居', + dataIndex: 'CommunityName', + }, + { + title: '点位名称', + dataIndex: 'PointName', + }, + { + title: '巡查时间', + dataIndex: 'PunchTime', + }, + { + title: '人员', + dataIndex: 'UserName', + }, + { + title: '巡查结果', + dataIndex: 'StatusName', + }, +] +export const dealCountColumns = [ + { title: '标题', dataIndex: 'Title', }, @@ -65,7 +95,7 @@ export const getColums = (type: string) => { case "reportCount": return reportCountColumns case "dealCount": - return reportCountColumns + return dealCountColumns } } export const searchFormSchema = [ diff --git a/src/views/demo/illegalconstruction/inspectionrecordpoint/index.vue b/src/views/demo/illegalconstruction/inspectionrecordpoint/index.vue index 549da5e..a0360c1 100644 --- a/src/views/demo/illegalconstruction/inspectionrecordpoint/index.vue +++ b/src/views/demo/illegalconstruction/inspectionrecordpoint/index.vue @@ -18,7 +18,7 @@ title="列表信息" :destroyOnClose="true" > - + @@ -38,6 +38,7 @@ const showListModal = ref(false) const showListModalTitle = ref('') const showListModalId = ref('') const showListModalType = ref('') +const showListModalTimeParams = ref({}) const [registerTable, { getForm }] =useTable({ title: '巡查台账-点位', api: GetPointPunchStatistics, @@ -108,6 +109,15 @@ const onBtnClicked = (domId) => { } } const showRecordList = (record, type) => { + const form = getForm(); + const params = form.getFieldsValue(); + if(params.begindate){ + params.begindate = dayjs(params.begindate).startOf('day').format('YYYY-MM-DD HH:mm:ss') + } + if(params.enddate){ + params.enddate = dayjs(params.enddate).endOf('day').format('YYYY-MM-DD HH:mm:ss') + } + showListModalTimeParams.value = params showListModalTitle.value = record.name showListModalId.value = record.pointId showListModalType.value = type diff --git a/src/views/demo/illegalconstruction/inspectionrecorduser/index.vue b/src/views/demo/illegalconstruction/inspectionrecorduser/index.vue index 9a9f9e5..a23edf2 100644 --- a/src/views/demo/illegalconstruction/inspectionrecorduser/index.vue +++ b/src/views/demo/illegalconstruction/inspectionrecorduser/index.vue @@ -108,7 +108,15 @@ const onBtnClicked = (domId) => { } } const showRecordList = (record, type) => { - getUserCountApi(type, { userid: record.userId })?.then(res => { + const form = getForm(); + const params = form.getFieldsValue(); + if(params.begindate){ + params.begindate = dayjs(params.begindate).startOf('day').format('YYYY-MM-DD HH:mm:ss') + } + if(params.enddate){ + params.enddate = dayjs(params.enddate).endOf('day').format('YYYY-MM-DD HH:mm:ss') + } + getUserCountApi(type, { userid: record.userId, ...params })?.then(res => { console.log(111,res) modalData.value = res mapVisible.value = true