From bf0eb543e2deab8a1629dd2a46f8e1cd191531e1 Mon Sep 17 00:00:00 2001
From: wangjuncheng <1>
Date: 星期四, 17 七月 2025 15:22:01 +0800
Subject: [PATCH] Merge branch 'master' of http://103.135.160.14:9034/r/NslWeb

---
 src/api/hpApi.js |   94 +++++++++++++++++++++++++++++++++++++++++++---
 1 files changed, 87 insertions(+), 7 deletions(-)

diff --git a/src/api/hpApi.js b/src/api/hpApi.js
index 6be05d2..9c220ff 100644
--- a/src/api/hpApi.js
+++ b/src/api/hpApi.js
@@ -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"
       ],
@@ -216,4 +245,55 @@
     params
   });
   return response.data;
+}
+
+// 鏌ヨ鍖椾含甯傞伩闄╁満鎵�
+export async function getSafePoint(data) {
+  const response = await axios.get("/hp/safeHavenLocation/getDataSelect", {
+    params: {
+      divisionId: data
+    }
+  });
+  return response.data;
+}
+// 110116110218
+
+
+
+// 鏌ヨ鍖椾含甯�
+export async function getAllCode() {
+  const response = await axios.get("/hp/district/getAll");
+  return response.data;
+}
+
+// 鑾峰彇澶╂皵棰勬姤
+export async function getWeather() {
+  // 鑾峰彇褰撳墠鏃堕棿鎴�
+  const currentTimestamp = Date.now();
+
+  // 鍒涘缓Date瀵硅薄
+  const currentDate = new Date(currentTimestamp);
+
+  // 鏍煎紡鍖栦负骞�-鏈�-鏃ワ紙YYYY-MM-DD锛�
+  const year = currentDate.getFullYear();
+  const month = String(currentDate.getMonth() + 1).padStart(2, '0'); // 鏈堜唤浠�0寮�濮嬶紝鎵�浠ヨ+1
+  const day = String(currentDate.getDate()).padStart(2, '0');
+  const formattedDate = `${year}-${month}-${day}`;
+
+  const response = await axios.get("/hp/weatherForecast/getSevenDaysWeather", {
+    params: {
+      inputDate: formattedDate
+    }
+  });
+  return response.data;
+}
+
+// 鐩戞祴璁惧涓叧鑱旂殑闅愭偅鐐圭殑鍏蜂綋淇℃伅
+export async function hdByDevice(data) {
+  const response = await axios.get("/hp/sinoDzHiddenDangerPoint/getDetail", {
+    params: {
+      unifiedCode: data
+    }
+  });
+  return response.data;
 }
\ No newline at end of file

--
Gitblit v1.9.3