From 6992aaf0587c09f7c511c1afd12e1519d91363d3 Mon Sep 17 00:00:00 2001
From: cjl <276999030@qq.com>
Date: Thu, 14 Dec 2023 15:38:45 +0800
Subject: [PATCH] Merge remote-tracking branch 'origin/cjl' into qa

---
 screen-api/src/main/java/com/moral/api/controller/AppDevicController.java |   35 ++++++++++++++++++++++-------------
 1 files changed, 22 insertions(+), 13 deletions(-)

diff --git a/screen-api/src/main/java/com/moral/api/controller/AppDevicController.java b/screen-api/src/main/java/com/moral/api/controller/AppDevicController.java
index d230674..17b65e8 100644
--- a/screen-api/src/main/java/com/moral/api/controller/AppDevicController.java
+++ b/screen-api/src/main/java/com/moral/api/controller/AppDevicController.java
@@ -5,7 +5,6 @@
 import io.swagger.annotations.ApiOperation;
 import io.swagger.annotations.ApiParam;
 import lombok.extern.slf4j.Slf4j;
-import org.springframework.beans.BeanUtils;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.util.ObjectUtils;
 import org.springframework.web.bind.annotation.GetMapping;
@@ -14,15 +13,15 @@
 import org.springframework.web.bind.annotation.RestController;
 
 import java.util.List;
-import java.util.Map;
 
 import com.moral.api.entity.Device;
-import com.moral.api.entity.Organization;
+import com.moral.api.entity.MonitorPoint;
+import com.moral.api.pojo.vo.device.AppDeviceVo;
 import com.moral.api.service.DeviceService;
-import com.moral.api.service.OrganizationService;
-import com.moral.constant.ResponseCodeEnum;
+import com.moral.api.service.MonitorPointService;
+import com.moral.api.service.SpecialDeviceService;
 import com.moral.constant.ResultMessage;
-import com.sun.org.apache.regexp.internal.RE;
+
 
 @Slf4j
 @Api(tags = {"���������������������"})
@@ -31,33 +30,43 @@
 public class AppDevicController {
 
     @Autowired
-    private OrganizationService organizationService;
+    private MonitorPointService monitorPointService;
 
     @Autowired
     private DeviceService deviceService;
 
+    @Autowired
+    private SpecialDeviceService specialDeviceService;
+
 
 
     @GetMapping("selectOrganization")
-    @ApiOperation(value = "���������������������")
+    @ApiOperation(value = "���������������������")
     public ResultMessage selectOrganization(){
-        List<Organization> organizations = organizationService.getOrganizations();
-        return ResultMessage.ok(organizations);
+        List<MonitorPoint> monitorPoints = monitorPointService.getOrganizations();
+        return ResultMessage.ok(monitorPoints);
     }
 
 
     @GetMapping("selectDevice")
     @ApiOperation(value = "���������������������")
-    public ResultMessage selectDevice(@RequestParam @ApiParam(value = "organizationId",name = "������ID") Integer organizationId){
-        List<Device> organizationDevice = deviceService.getOrganizationDevice(organizationId);
+    public ResultMessage selectDevice(@RequestParam @ApiParam(value = "monitorPointId",name = "������ID") Integer monitorPointId){
+        List<Device> organizationDevice = deviceService.getOrganizationDevice(monitorPointId);
         return ResultMessage.ok(ObjectUtils.isEmpty(organizationDevice)?null:organizationDevice);
     }
 
     @GetMapping("fuzzySearch")
     @ApiOperation(value = "���������������������")
     public ResultMessage fuzzySearch(@RequestParam @ApiParam(value = "mac",name = "������mac���") String mac){
-        List<Device> devices = deviceService.getFuzzySearch(mac);
+        List<AppDeviceVo> devices = deviceService.getFuzzySearch(mac);
         return ResultMessage.ok(devices);
     }
 
+
+    @GetMapping("specialDevice")
+    @ApiOperation(value = "������������������")
+    public ResultMessage selectSpecialDevice(){
+        List<AppDeviceVo> appDeviceVos = specialDeviceService.selectSpecialDevice();
+        return ResultMessage.ok(appDeviceVos);
+    }
 }

--
Gitblit v1.8.0