From a113085bf4960ea08532bf8d6fed08a72f9e66c3 Mon Sep 17 00:00:00 2001 From: guonan <guonan201020@163.com> Date: 星期三, 09 七月 2025 15:19:57 +0800 Subject: [PATCH] 修改 --- src/api/hpApi.js | 69 +++++++++++++++++++++++++++++----- 1 files changed, 58 insertions(+), 11 deletions(-) diff --git a/src/api/hpApi.js b/src/api/hpApi.js index 9d0e86f..ce801f0 100644 --- a/src/api/hpApi.js +++ b/src/api/hpApi.js @@ -85,7 +85,7 @@ return response.data; } -// 鎸夌収琛屾斂鍖篶ode鏌ヨ涔¢晣code +// 鎸夌収琛屾斂鍖篶ode鏌ヨ涔¢晣code(姝ゆ帴鍙e寘鍚殣鎮g偣鏁伴噺鏌ヨ) export async function getAeraTownCode(data) { const response = await axios.post("/hp/sinoDzHiddenDangerPoint/getHiddenDangerTownCount", { "dictDisasterGrade": "", @@ -98,7 +98,7 @@ return response.data; } -// 鏍规嵁涔¢晣Code鑾峰彇闅愭偅鐐� +// 鏍规嵁涔¢晣Code鑾峰彇闅愭偅鐐�(姝ゆ帴鍙e寘鍚殣鎮g偣鏁伴噺鏌ヨ) export async function getDangerPoint(data) { const response = await axios.post("/hp/sinoDzHiddenDangerPoint/getData", { filterObject: { @@ -127,31 +127,60 @@ // 鐩戞祴璁惧鎺ュ彛 /** - * 妫�鏌ユ椂闂村垪鏄惁鎸夊崌搴忔帓鍒� * @param {string} data - 闆ㄩ噺璁¤澶囩被鍨媔d * @param {string} townCode - 涔¢晣code,鍙互鏌ヨ涔¢晣鐩戞祴璁惧淇℃伅 */ export async function getDeviceInfo(data, townCode) { const response = await axios.post("/hp/deviceInfo/getData", { filterObject: { - "dictDeviceType": data, - "townCode": townCode, + "dictCommunicationType": data, + "townCodeList": [townCode], + "year": 2025, // 鎵�灞為」鐩� - // "belongObjList": [ - // "1797461961110261762" - // ], + "belongObjList": [ + "1797461961110261762" + ], }, "pageSize": 10000 }); return response.data; } +// 鎺ュ彛澶氬啓鍑犱釜搴旇鏃犲Θ鍚� +export async function getDeviceNWJ(data, townCode) { + const response = await axios.post("/hp/deviceInfo/getData", { + filterObject: { + "dictDeviceTypeList": [data], + "townCodeList": [townCode], + "year": 2025, + }, + "pageSize": 10000 + }); + return response.data; +} + +// 鏌ヨ瀛欒儭娌熺洃娴嬭澶囷紝dictCommunicationType涓烘煡璇㈠瓩鑳℃矡鐨勯洦閲忚 +export async function getDeviceInfoSHG(data) { + const response = await axios.post("/hp/deviceInfo/getData", { + filterObject: { + "dictCommunicationType": data, + "townCodeList": ["110116110000"], + "year": 2025, + }, + "pageSize": 10000 + + }); + return response.data; +} + + // 鍒嗛〉鏌ヨ琛屾斂鍖哄垝鐩戞祴璁惧淇℃伅 export async function getDeviceInfoByPage(data, pageNum) { const response = await axios.post("/hp/deviceInfo/getData", { filterObject: { - "divisionDistrict": data, + "divisionDistrictList": [data], // 鎵�灞為」鐩� + // 濡傛灉涓嶅姞杩欎釜锛屽垯杩斿洖鐨勫叏鏄己闇囦华锛�1933099069385355265锛� "belongObjList": [ "1797461961110261762" ], @@ -211,7 +240,25 @@ // 鏌ヨ鍖椾含甯傜洃娴嬭澶囩殑鏁伴噺 -export async function getDeviceCount() { - const response = await axios.get("/hp/device/statisticsCountyByDeviceType"); +export async function getDeviceCount(params = {}) { + const response = await axios.get("/hp/device/statisticsCountyByDeviceType", { + params + }); + return response.data; +} + +// 鏌ヨ瀛欒儭娌熼伩闄╁満鎵� +export async function getSafePoint(data) { + const response = await axios.get("/hp/safeHavenLocation/getDataSelect", { + params: { + divisionId: 110116110218 + } + }); + return response.data; +} + +// 鏌ヨ鍖椾含甯� +export async function getAllCode() { + const response = await axios.get("/hp/district/getAll"); return response.data; } \ No newline at end of file -- Gitblit v1.9.3