From 3a4330d7095e4177b9ffee0ca1749c22711bc955 Mon Sep 17 00:00:00 2001
From: aijinhui <aijinhui>
Date: 星期三, 18 十月 2023 13:36:36 +0800
Subject: [PATCH] 设备健康列表
---
ard-work/src/main/java/com/ruoyi/sy/vo/CarLockVo.java | 14 ++++
ard-work/src/main/java/com/ruoyi/statistical/mapper/ArdPumpStatusMapper.java | 2
ard-work/src/main/java/com/ruoyi/sy/service/impl/ArdSyCarLockServiceImpl.java | 42 ++++++++++++++
ard-work/src/main/java/com/ruoyi/oil/controller/OilWallController.java | 14 ++--
ard-work/src/main/java/com/ruoyi/oil/service/ArdOilWallService.java | 2
ard-work/src/main/java/com/ruoyi/oil/mapper/ArdOilWallMapper.java | 2
ard-work/src/main/java/com/ruoyi/oil/service/impl/ArdOilWallServiceImpl.java | 18 +++---
ard-work/src/main/java/com/ruoyi/sy/controller/ArdSyCarLockController.java | 19 +++--
ard-work/src/main/java/com/ruoyi/statistical/service/impl/StatisticalServiceImpl.java | 14 ++--
ard-work/src/main/java/com/ruoyi/sy/service/ArdSyCarLockService.java | 18 ++++++
10 files changed, 111 insertions(+), 34 deletions(-)
diff --git a/ard-work/src/main/java/com/ruoyi/oil/controller/OilWallController.java b/ard-work/src/main/java/com/ruoyi/oil/controller/OilWallController.java
index 98d2346..76aa0ea 100644
--- a/ard-work/src/main/java/com/ruoyi/oil/controller/OilWallController.java
+++ b/ard-work/src/main/java/com/ruoyi/oil/controller/OilWallController.java
@@ -4,7 +4,7 @@
import com.ruoyi.common.utils.uuid.UUID;
import com.ruoyi.oil.domain.ArdOilWall;
import com.ruoyi.oil.param.OilWallParam;
-import com.ruoyi.oil.service.OilWallService;
+import com.ruoyi.oil.service.ArdOilWallService;
import com.ruoyi.utils.result.Results;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
@@ -22,7 +22,7 @@
public class OilWallController {
@Autowired
- private OilWallService oilWallService;
+ private ArdOilWallService ardOilWallService;
@PostMapping("/add")
@ApiOperation("娣诲姞鐢靛瓙鍥存爮")
@@ -30,13 +30,13 @@
ardOilWall.setId(String.valueOf(UUID.randomUUID()));
ardOilWall.setCreateBy(SecurityUtils.getUsername());
ardOilWall.setCreateTime(new Date());
- return Results.succeed("鎴愬姛娣诲姞"+oilWallService.addOilWall(ardOilWall)+"鏉℃暟鎹�");
+ return Results.succeed("鎴愬姛娣诲姞"+ ardOilWallService.addOilWall(ardOilWall)+"鏉℃暟鎹�");
}
@DeleteMapping("/del")
@ApiOperation("鍒犻櫎鐢靛瓙鍥存爮")
public Results del(String id){
- return Results.succeed("鎴愬姛鍒犻櫎"+oilWallService.delOilWall(id)+"鏉℃暟鎹�");
+ return Results.succeed("鎴愬姛鍒犻櫎"+ ardOilWallService.delOilWall(id)+"鏉℃暟鎹�");
}
@PutMapping("/upd")
@@ -44,19 +44,19 @@
public Results upd(@RequestBody ArdOilWall ardOilWall){
ardOilWall.setUpdateBy(SecurityUtils.getUsername());
ardOilWall.setUpdateTime(new Date());
- return Results.succeed("鎴愬姛淇敼"+oilWallService.updOilWall(ardOilWall)+"鏉℃暟鎹�");
+ return Results.succeed("鎴愬姛淇敼"+ ardOilWallService.updOilWall(ardOilWall)+"鏉℃暟鎹�");
}
@GetMapping("/one")
@ApiOperation("鏌ヨ涓�鏉$數瀛愬洿鏍�")
public Results one(String id){
- return Results.succeed(oilWallService.one(id));
+ return Results.succeed(ardOilWallService.one(id));
}
@GetMapping("/query")
@ApiOperation("鏌ヨ鎵�鏈夌數瀛愬洿鏍�")
public Results query(OilWallParam oilWallParam){
- return Results.succeed(oilWallService.query(oilWallParam));
+ return Results.succeed(ardOilWallService.query(oilWallParam));
}
}
diff --git a/ard-work/src/main/java/com/ruoyi/oil/mapper/OilWallMapper.java b/ard-work/src/main/java/com/ruoyi/oil/mapper/ArdOilWallMapper.java
similarity index 71%
rename from ard-work/src/main/java/com/ruoyi/oil/mapper/OilWallMapper.java
rename to ard-work/src/main/java/com/ruoyi/oil/mapper/ArdOilWallMapper.java
index 8142ab7..61c8f58 100644
--- a/ard-work/src/main/java/com/ruoyi/oil/mapper/OilWallMapper.java
+++ b/ard-work/src/main/java/com/ruoyi/oil/mapper/ArdOilWallMapper.java
@@ -6,5 +6,5 @@
/**
* @author Administrator
*/
-public interface OilWallMapper extends BaseMapper<ArdOilWall> {
+public interface ArdOilWallMapper extends BaseMapper<ArdOilWall> {
}
diff --git a/ard-work/src/main/java/com/ruoyi/oil/service/OilWallService.java b/ard-work/src/main/java/com/ruoyi/oil/service/ArdOilWallService.java
similarity index 91%
rename from ard-work/src/main/java/com/ruoyi/oil/service/OilWallService.java
rename to ard-work/src/main/java/com/ruoyi/oil/service/ArdOilWallService.java
index fb8d27b..4b447a8 100644
--- a/ard-work/src/main/java/com/ruoyi/oil/service/OilWallService.java
+++ b/ard-work/src/main/java/com/ruoyi/oil/service/ArdOilWallService.java
@@ -9,7 +9,7 @@
/**
* @author Administrator
*/
-public interface OilWallService {
+public interface ArdOilWallService {
int addOilWall(ArdOilWall ardOilWall);
int delOilWall(String id);
int updOilWall(ArdOilWall ardOilWall);
diff --git a/ard-work/src/main/java/com/ruoyi/oil/service/impl/OilWallServiceImpl.java b/ard-work/src/main/java/com/ruoyi/oil/service/impl/ArdOilWallServiceImpl.java
similarity index 67%
rename from ard-work/src/main/java/com/ruoyi/oil/service/impl/OilWallServiceImpl.java
rename to ard-work/src/main/java/com/ruoyi/oil/service/impl/ArdOilWallServiceImpl.java
index 56e5269..feef9fd 100644
--- a/ard-work/src/main/java/com/ruoyi/oil/service/impl/OilWallServiceImpl.java
+++ b/ard-work/src/main/java/com/ruoyi/oil/service/impl/ArdOilWallServiceImpl.java
@@ -2,8 +2,8 @@
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.ruoyi.oil.domain.ArdOilWall;
-import com.ruoyi.oil.mapper.OilWallMapper;
-import com.ruoyi.oil.service.OilWallService;
+import com.ruoyi.oil.mapper.ArdOilWallMapper;
+import com.ruoyi.oil.service.ArdOilWallService;
import com.ruoyi.oil.param.OilWallParam;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
@@ -14,29 +14,29 @@
* @author Administrator
*/
@Service
-public class OilWallServiceImpl implements OilWallService {
+public class ArdOilWallServiceImpl implements ArdOilWallService {
@Autowired
- private OilWallMapper oilWallMapper;
+ private ArdOilWallMapper ardOilWallMapper;
@Override
public int addOilWall(ArdOilWall ardOilWall) {
- return oilWallMapper.insert(ardOilWall);
+ return ardOilWallMapper.insert(ardOilWall);
}
@Override
public int delOilWall(String id) {
- return oilWallMapper.deleteById(id);
+ return ardOilWallMapper.deleteById(id);
}
@Override
public int updOilWall(ArdOilWall ardOilWall) {
- return oilWallMapper.updateById(ardOilWall);
+ return ardOilWallMapper.updateById(ardOilWall);
}
@Override
public ArdOilWall one(String id) {
- return oilWallMapper.selectById(id);
+ return ardOilWallMapper.selectById(id);
}
@Override
@@ -44,6 +44,6 @@
QueryWrapper<ArdOilWall> queryWrapper = new QueryWrapper<>();
queryWrapper.like(oilWallParam.getName()!=null,"name",oilWallParam.getName())
.eq(oilWallParam.getType()!=null,"type",oilWallParam.getType());
- return oilWallMapper.selectList(queryWrapper);
+ return ardOilWallMapper.selectList(queryWrapper);
}
}
diff --git a/ard-work/src/main/java/com/ruoyi/statistical/mapper/PumpStatusMapper.java b/ard-work/src/main/java/com/ruoyi/statistical/mapper/ArdPumpStatusMapper.java
similarity index 71%
rename from ard-work/src/main/java/com/ruoyi/statistical/mapper/PumpStatusMapper.java
rename to ard-work/src/main/java/com/ruoyi/statistical/mapper/ArdPumpStatusMapper.java
index ddbc007..6265165 100644
--- a/ard-work/src/main/java/com/ruoyi/statistical/mapper/PumpStatusMapper.java
+++ b/ard-work/src/main/java/com/ruoyi/statistical/mapper/ArdPumpStatusMapper.java
@@ -7,5 +7,5 @@
/**
* @author Administrator
*/
-public interface PumpStatusMapper extends BaseMapper<ArdPumpStatus> {
+public interface ArdPumpStatusMapper extends BaseMapper<ArdPumpStatus> {
}
diff --git a/ard-work/src/main/java/com/ruoyi/statistical/service/impl/StatisticalServiceImpl.java b/ard-work/src/main/java/com/ruoyi/statistical/service/impl/StatisticalServiceImpl.java
index 8dff69e..24b034c 100644
--- a/ard-work/src/main/java/com/ruoyi/statistical/service/impl/StatisticalServiceImpl.java
+++ b/ard-work/src/main/java/com/ruoyi/statistical/service/impl/StatisticalServiceImpl.java
@@ -22,7 +22,7 @@
import com.ruoyi.device.radar.domain.ArdEquipRadar;
import com.ruoyi.device.radar.mapper.ArdEquipRadarMapper;
import com.ruoyi.statistical.domain.ArdPumpStatus;
-import com.ruoyi.statistical.mapper.PumpStatusMapper;
+import com.ruoyi.statistical.mapper.ArdPumpStatusMapper;
import com.ruoyi.statistical.param.ESParam;
import com.ruoyi.statistical.param.Para;
import com.ruoyi.statistical.service.StatisticalService;
@@ -74,7 +74,7 @@
@Autowired
private ArdCamerasMapper camerasMapper;
@Autowired
- private PumpStatusMapper pumpStatusMapper;
+ private ArdPumpStatusMapper ardPumpStatusMapper;
@Override
@@ -382,14 +382,14 @@
List<TenVo> list = new ArrayList<>();
QueryWrapper<ArdPumpStatus> queryWrapper = new QueryWrapper<>();
queryWrapper.eq("alarm_type","杩愯");
- int y = pumpStatusMapper.selectCount(queryWrapper);
+ int y = ardPumpStatusMapper.selectCount(queryWrapper);
TenVo tenVo = new TenVo();
tenVo.setName("杩愯");
tenVo.setValue(y);
list.add(tenVo);
QueryWrapper<ArdPumpStatus> queryWrapper1 = new QueryWrapper<>();
queryWrapper1.eq("alarm_type","鍋滄満");
- int t = pumpStatusMapper.selectCount(queryWrapper1);
+ int t = ardPumpStatusMapper.selectCount(queryWrapper1);
TenVo tenVo1 = new TenVo();
tenVo1.setName("鍋滄満");
tenVo1.setValue(t);
@@ -407,7 +407,7 @@
JSONObject j = list.get(i);
QueryWrapper<ArdPumpStatus> queryWrapper = new QueryWrapper<>();
queryWrapper.eq("target_id",j.getInteger("targetId")).eq("name",j.getString("name"));
- ArdPumpStatus ardPumpStatus1 = pumpStatusMapper.selectOne(queryWrapper);
+ ArdPumpStatus ardPumpStatus1 = ardPumpStatusMapper.selectOne(queryWrapper);
if(ardPumpStatus1 ==null){
ArdPumpStatus ardPumpStatus = new ArdPumpStatus();
ardPumpStatus.setTargetId(j.getInteger("targetId"));
@@ -418,7 +418,7 @@
ardPumpStatus.setAlarmType(j.getString("alarm"));
}
ardPumpStatus.setAlarmTime(alarmTime);
- pumpStatusMapper.insert(ardPumpStatus);
+ ardPumpStatusMapper.insert(ardPumpStatus);
}else {
String alarmType = ardPumpStatus1.getAlarmType();
Boolean bo = false;
@@ -434,7 +434,7 @@
if(!bo){
ardPumpStatus1.setAlarmType(j.getString("alarmType"));
ardPumpStatus1.setAlarmTime(alarmTime);
- pumpStatusMapper.updateById(ardPumpStatus1);
+ ardPumpStatusMapper.updateById(ardPumpStatus1);
}
}
}
diff --git a/ard-work/src/main/java/com/ruoyi/sy/controller/ArdSyCarLockController.java b/ard-work/src/main/java/com/ruoyi/sy/controller/ArdSyCarLockController.java
index 74027fb..d467c11 100644
--- a/ard-work/src/main/java/com/ruoyi/sy/controller/ArdSyCarLockController.java
+++ b/ard-work/src/main/java/com/ruoyi/sy/controller/ArdSyCarLockController.java
@@ -1,9 +1,12 @@
package com.ruoyi.sy.controller;
+import com.ruoyi.sy.domain.ArdSyCarLock;
import com.ruoyi.utils.result.Results;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.web.bind.annotation.*;
+
+import java.util.List;
@RestController
@RequestMapping("syLock")
@@ -28,21 +31,21 @@
return Results.succeed("鎴愬姛鍒犻櫎"+1+"鏉℃暟鎹�");
}
- @PutMapping("/upd")
- @ApiOperation("淇敼rtu")
- public Results upd(){
- return Results.succeed("鎴愬姛淇敼"+1+"鏉℃暟鎹�");
- }
-
@GetMapping("/one")
- @ApiOperation("鏌ヨ涓�鏉tu")
+ @ApiOperation("鏌ヨ涓�鏉tu鍙婇攣")
public Results one(String id){
return Results.succeed();
}
@GetMapping("/query")
- @ApiOperation("鏌ヨ鎵�鏈塺tu")
+ @ApiOperation("鏌ヨ鎵�鏈塺tu鎸傝浇鐨勮溅杈�")
public Results query(){
return Results.succeed();
}
+
+ @GetMapping("/addLock")
+ @ApiOperation("鏌ヨ鎵�鏈塺tu鎸傝浇鐨勮溅杈�")
+ public Results addLock(@RequestBody List<ArdSyCarLock> locks){
+ return Results.succeed();
+ }
}
diff --git a/ard-work/src/main/java/com/ruoyi/sy/service/ArdSyCarLockService.java b/ard-work/src/main/java/com/ruoyi/sy/service/ArdSyCarLockService.java
index 4001803..b17bc54 100644
--- a/ard-work/src/main/java/com/ruoyi/sy/service/ArdSyCarLockService.java
+++ b/ard-work/src/main/java/com/ruoyi/sy/service/ArdSyCarLockService.java
@@ -1,11 +1,29 @@
package com.ruoyi.sy.service;
+import com.ruoyi.sy.domain.ArdSyCarLock;
+import com.ruoyi.sy.vo.CarLockVo;
import com.ruoyi.sy.vo.CarVo;
import java.util.List;
public interface ArdSyCarLockService {
+ /**
+ * 鎵�鏈夋湭鎸傞攣鐨勮溅杈�
+ */
List<CarVo> car();
+ int addRtu(String carId);
+
+ /**
+ * 鎵�鏈夋寕閿佺殑杞﹁締
+ */
+ List<CarVo> carList();
+
+ int delCar(String CarId);
+
+ List<CarLockVo> carLock(String carId);
+
+ int addUpdLock(ArdSyCarLock ardSyCarLock);
+
}
diff --git a/ard-work/src/main/java/com/ruoyi/sy/service/impl/ArdSyCarLockServiceImpl.java b/ard-work/src/main/java/com/ruoyi/sy/service/impl/ArdSyCarLockServiceImpl.java
new file mode 100644
index 0000000..055a6f3
--- /dev/null
+++ b/ard-work/src/main/java/com/ruoyi/sy/service/impl/ArdSyCarLockServiceImpl.java
@@ -0,0 +1,42 @@
+package com.ruoyi.sy.service.impl;
+
+import com.ruoyi.sy.domain.ArdSyCarLock;
+import com.ruoyi.sy.service.ArdSyCarLockService;
+import com.ruoyi.sy.vo.CarLockVo;
+import com.ruoyi.sy.vo.CarVo;
+import org.springframework.stereotype.Service;
+
+import java.util.List;
+
+@Service
+public class ArdSyCarLockServiceImpl implements ArdSyCarLockService {
+ @Override
+ public List<CarVo> car() {
+ return null;
+ }
+
+ @Override
+ public int addRtu(String carId) {
+ return 0;
+ }
+
+ @Override
+ public List<CarVo> carList() {
+ return null;
+ }
+
+ @Override
+ public int delCar(String CarId) {
+ return 0;
+ }
+
+ @Override
+ public List<CarLockVo> carLock(String carId) {
+ return null;
+ }
+
+ @Override
+ public int addUpdLock(ArdSyCarLock ardSyCarLock) {
+ return 0;
+ }
+}
diff --git a/ard-work/src/main/java/com/ruoyi/sy/vo/CarLockVo.java b/ard-work/src/main/java/com/ruoyi/sy/vo/CarLockVo.java
new file mode 100644
index 0000000..42427ea
--- /dev/null
+++ b/ard-work/src/main/java/com/ruoyi/sy/vo/CarLockVo.java
@@ -0,0 +1,14 @@
+package com.ruoyi.sy.vo;
+
+import com.ruoyi.sy.domain.ArdSyCarLock;
+import lombok.Data;
+import org.checkerframework.checker.units.qual.C;
+
+import java.util.List;
+
+@Data
+public class CarLockVo {
+
+ private CarVo car;
+ private List<ArdSyCarLock> carLockList;
+}
--
Gitblit v1.9.3