Files
ndm-web-client/src/apis/requests/device/log/ndm-snmp-log.ts
2025-11-20 10:58:19 +08:00

12 lines
510 B
TypeScript

import { ndmClient, type NdmSnmpLogPageQuery, type NdmSnmpLogResultVO, type PageParams, type PageResult } from '@/apis';
export const postSnmpLogPage = async (stationCode: string, pageQuery: PageParams<NdmSnmpLogPageQuery>) => {
const prefix = stationCode ? `/${stationCode}` : '';
const resp = await ndmClient.post<PageResult<NdmSnmpLogResultVO>>(`${prefix}/api/ndm/ndmSnmpLog/page`, pageQuery);
const [err, snmpLogData] = resp;
if (err || !snmpLogData) {
throw err;
}
return snmpLogData;
};