From 787ac0c93db67a3ead8e8dd306ad631ac8dd8a56 Mon Sep 17 00:00:00 2001
From: lsh <lsh@163.com>
Date: 星期一, 21 四月 2025 10:09:09 +0800
Subject: [PATCH] *

---
 src/main/resources/mapper/ApiConfigMapper.xml                   |    4 ++--
 src/main/resources/mapper/DeviceErrorMapper.xml                 |    6 +++---
 src/main/java/com/zy/asrs/controller/DeviceErrorController.java |    7 +++++--
 3 files changed, 10 insertions(+), 7 deletions(-)

diff --git a/src/main/java/com/zy/asrs/controller/DeviceErrorController.java b/src/main/java/com/zy/asrs/controller/DeviceErrorController.java
index c235ff5..fbd9636 100644
--- a/src/main/java/com/zy/asrs/controller/DeviceErrorController.java
+++ b/src/main/java/com/zy/asrs/controller/DeviceErrorController.java
@@ -12,11 +12,13 @@
 import com.core.common.Cools;
 import com.core.common.R;
 import com.zy.common.web.BaseController;
+import lombok.extern.slf4j.Slf4j;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.web.bind.annotation.*;
 
 import java.util.*;
 
+@Slf4j
 @RestController
 public class DeviceErrorController extends BaseController {
 
@@ -60,10 +62,10 @@
                     continue;
                 }
                 if (entry.getKey().equals("id")) {
-                    id = Long.getLong(val);
+                    id = (long) Integer.parseInt(val);
                 } else if (entry.getKey().equals("device")) {
                     device = val;
-                } else if (entry.getKey().equals("deviceId")) {
+                } else if (entry.getKey().equals("device_id")) {
                     deviceId = Integer.valueOf(val);
                 }
             }
@@ -72,6 +74,7 @@
             page1.setTotal(deviceErrorService.selectDeviceErrorListTotal(id,device,deviceId));
             return R.ok(page1);
         } catch (Exception e) {
+            log.error("寮傚父" + e);
             return R.error("寮傚父" + e);
         }
     }
diff --git a/src/main/resources/mapper/ApiConfigMapper.xml b/src/main/resources/mapper/ApiConfigMapper.xml
index d6d9747..a6c4c1f 100644
--- a/src/main/resources/mapper/ApiConfigMapper.xml
+++ b/src/main/resources/mapper/ApiConfigMapper.xml
@@ -17,10 +17,10 @@
 
     <sql id="batchSeq">
         <if test="id != null and id != 0">
-            and a.ID = #{id}
+            and ID = #{id}
         </if>
         <if test="url != null and url != ''">
-            and a.URL = #{url}
+            and URL = #{url}
         </if>
     </sql>
 
diff --git a/src/main/resources/mapper/DeviceErrorMapper.xml b/src/main/resources/mapper/DeviceErrorMapper.xml
index 199c16e..932df28 100644
--- a/src/main/resources/mapper/DeviceErrorMapper.xml
+++ b/src/main/resources/mapper/DeviceErrorMapper.xml
@@ -13,13 +13,13 @@
 
     <sql id="batchSeq">
         <if test="id != null and id != 0">
-            and a.ID = #{id}
+            and ID = #{id}
         </if>
         <if test="device != null and device != ''">
-            and a.DEVICE = #{device}
+            and DEVICE = #{device}
         </if>
         <if test="deviceId != null and deviceId != 0">
-            and a.DEVICE_ID = #{deviceId}
+            and DEVICE_ID = #{deviceId}
         </if>
     </sql>
 

--
Gitblit v1.9.1