|
@@ -1,7 +1,5 @@
|
|
|
import { getPersonOverview, getVehicleOverview } from '@/api/security-confidentiality-overview';
|
|
import { getPersonOverview, getVehicleOverview } from '@/api/security-confidentiality-overview';
|
|
|
import type { PersonOverview, PieChartData, VehicleOverview, BarChartData } from './types';
|
|
import type { PersonOverview, PieChartData, VehicleOverview, BarChartData } from './types';
|
|
|
-import dayjs from 'dayjs';
|
|
|
|
|
-import { getVehicleRecordList } from '@/api/security-confidentiality-vehicle';
|
|
|
|
|
|
|
|
|
|
export async function getPersonOverviewChartData() {
|
|
export async function getPersonOverviewChartData() {
|
|
|
const personOverview: PersonOverview = await getPersonOverview();
|
|
const personOverview: PersonOverview = await getPersonOverview();
|
|
@@ -18,19 +16,3 @@ export async function getVehicleOverviewChartData() {
|
|
|
value: vehicleOverview.vehicleEntryRecordList.map((item) => item.vehicleCount),
|
|
value: vehicleOverview.vehicleEntryRecordList.map((item) => item.vehicleCount),
|
|
|
} as BarChartData;
|
|
} as BarChartData;
|
|
|
}
|
|
}
|
|
|
-
|
|
|
|
|
-export async function getLastDayFlow() {
|
|
|
|
|
- const searchTime = [
|
|
|
|
|
- dayjs().startOf('day').format('YYYY-MM-DD HH:mm:ss'),
|
|
|
|
|
- dayjs().endOf('day').format('YYYY-MM-DD HH:mm:ss'),
|
|
|
|
|
- ];
|
|
|
|
|
- const list = await getVehicleRecordList({
|
|
|
|
|
- pageNumber: 1,
|
|
|
|
|
- pageSize: 1,
|
|
|
|
|
- queryParam: {
|
|
|
|
|
- startTime: searchTime[0],
|
|
|
|
|
- endTime: searchTime[1],
|
|
|
|
|
- },
|
|
|
|
|
- });
|
|
|
|
|
- return list.totalRow;
|
|
|
|
|
-}
|
|
|