|
@@ -1,6 +1,6 @@
|
|
|
import request from '@/config/axios'
|
|
|
|
|
|
-/** 统计数据类型 */
|
|
|
+/** IoT 统计数据类型 */
|
|
|
export interface IotStatisticsSummaryRespVO {
|
|
|
productCategoryCount: number
|
|
|
productCount: number
|
|
@@ -16,7 +16,7 @@ export interface IotStatisticsSummaryRespVO {
|
|
|
productCategoryDeviceCounts: Record<string, number>
|
|
|
}
|
|
|
|
|
|
-/** 消息统计数据类型 */
|
|
|
+/** IoT 消息统计数据类型 */
|
|
|
export interface IotStatisticsDeviceMessageSummaryRespVO {
|
|
|
upstreamCounts: Record<number, number>
|
|
|
downstreamCounts: Record<number, number>
|
|
@@ -24,21 +24,18 @@ export interface IotStatisticsDeviceMessageSummaryRespVO {
|
|
|
|
|
|
// IoT 数据统计 API
|
|
|
export const ProductCategoryApi = {
|
|
|
- // 查询IoT基础数据统计
|
|
|
+ // 查询基础的数据统计
|
|
|
getIotStatisticsSummary: async () => {
|
|
|
- return await request.get<IotStatisticsSummaryRespVO>({
|
|
|
+ return await request.get<IotStatisticsSummaryRespVO>({
|
|
|
url: `/iot/statistics/get-summary`
|
|
|
})
|
|
|
},
|
|
|
|
|
|
- // 查询IoT上下行消息数据统计
|
|
|
- getIotStatisticsDeviceMessageSummary: async (params: {
|
|
|
- startTime: number
|
|
|
- endTime: number
|
|
|
- }) => {
|
|
|
- return await request.get<IotStatisticsDeviceMessageSummaryRespVO>({
|
|
|
- url: `/iot/statistics/get-log-summary`,
|
|
|
- params
|
|
|
+ // 查询设备上下行消息的数据统计
|
|
|
+ getIotStatisticsDeviceMessageSummary: async (params: { startTime: number; endTime: number }) => {
|
|
|
+ return await request.get<IotStatisticsDeviceMessageSummaryRespVO>({
|
|
|
+ url: `/iot/statistics/get-log-summary`,
|
|
|
+ params
|
|
|
})
|
|
|
}
|
|
|
-}
|
|
|
+}
|