隐患点

This commit is contained in:
wzy-warehouse
2026-04-11 10:09:40 +08:00
parent de01e88642
commit e17a73537c
29 changed files with 573 additions and 25 deletions
+13
View File
@@ -1,4 +1,8 @@
import type { DisasterType } from '@/types/common/DisasterType'
import { getSm2PublicKey } from './crypto'
import { getBasePoins, getPointDetailById } from './hidden-danger-spots'
import type { ApiResponse } from '@/types/ApiResponse'
import type { XianHiddenDangerSpots } from '@/types/base/XianHiddenDangerSpots'
export const $api = {
@@ -7,4 +11,13 @@ export const $api = {
// 获取sm2公钥
getSm2PublicKey: () => getSm2PublicKey(),
},
// 隐患点信息
hiddenDangerSpots: {
// 获取所有基础隐患点
getBasePoins: (disasterType: DisasterType): Promise<ApiResponse<XianHiddenDangerSpots[]>> => getBasePoins(disasterType),
// 根据id获取隐患点详情
getPointDetailById: (id: number): Promise<ApiResponse<XianHiddenDangerSpots>> => getPointDetailById(id),
},
}