chore: reorder import

This commit is contained in:
yangsy
2025-08-22 00:24:05 +08:00
parent a9e52f1e0f
commit a52899b052
43 changed files with 127 additions and 153 deletions

View File

@@ -0,0 +1,22 @@
import { ndmClient } from '@/apis/client';
import type { PageParams, NdmDecoderPageQuery, PageResult, NdmDecoderResultVO, NdmDecoderUpdateVO } from '@/apis/models';
export const postNdmDecoderPage = async (stationCode: string, pageQuery: PageParams<NdmDecoderPageQuery>) => {
const prefix = stationCode ? `/${stationCode}` : '';
const resp = await ndmClient.post<PageResult<NdmDecoderResultVO>>(`${prefix}/api/ndm/ndmDecoder/page`, pageQuery);
const [err, ndmDecoderData] = resp;
if (err || !ndmDecoderData) {
throw err;
}
return ndmDecoderData;
};
export const putNdmDecoder = async (stationCode: string, updateVO: NdmDecoderUpdateVO) => {
const prefix = stationCode ? `/${stationCode}` : '';
const resp = await ndmClient.put<NdmDecoderResultVO>(`${prefix}/api/ndm/ndmDecoder`, updateVO);
const [err, ndmDecoder] = resp;
if (err || !ndmDecoder) {
throw err;
}
return ndmDecoder;
};