feat:缓存代码修复
parent
f34d4acc1f
commit
a08b98ca95
|
@ -1,2 +1 @@
|
||||||
com.muyu.common.kafka.config.KafkaConsumerConfig
|
|
||||||
com.muyu.common.kafka.config.KafkaProviderConfig
|
|
||||||
|
|
|
@ -25,5 +25,9 @@
|
||||||
<groupId>com.muyu</groupId>
|
<groupId>com.muyu</groupId>
|
||||||
<artifactId>cloud-common-core</artifactId>
|
<artifactId>cloud-common-core</artifactId>
|
||||||
</dependency>
|
</dependency>
|
||||||
|
<dependency>
|
||||||
|
<groupId>com.muyu</groupId>
|
||||||
|
<artifactId>cloud-modules-openbusiness-common</artifactId>
|
||||||
|
</dependency>
|
||||||
</dependencies>
|
</dependencies>
|
||||||
</project>
|
</project>
|
||||||
|
|
|
@ -10,6 +10,7 @@ import com.muyu.common.system.remote.RemoteUserService;
|
||||||
import com.muyu.common.system.domain.SysUser;
|
import com.muyu.common.system.domain.SysUser;
|
||||||
import com.muyu.common.system.domain.LoginUser;
|
import com.muyu.common.system.domain.LoginUser;
|
||||||
|
|
||||||
|
import com.muyu.openbusiness.domain.SysCarMessage;
|
||||||
import org.slf4j.Logger;
|
import org.slf4j.Logger;
|
||||||
import org.slf4j.LoggerFactory;
|
import org.slf4j.LoggerFactory;
|
||||||
import org.springframework.cloud.openfeign.FallbackFactory;
|
import org.springframework.cloud.openfeign.FallbackFactory;
|
||||||
|
@ -47,6 +48,10 @@ public class RemoteUserFallbackFactory implements FallbackFactory<RemoteUserServ
|
||||||
return Result.error("注册用户失败:" + throwable.getMessage());
|
return Result.error("注册用户失败:" + throwable.getMessage());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public Result list(SysCarMessage sysCarMessage) {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public Result<List<SysUser>> companyList() {
|
public Result<List<SysUser>> companyList() {
|
||||||
|
|
|
@ -1,34 +0,0 @@
|
||||||
package com.muyu.openbusiness;
|
|
||||||
|
|
||||||
import com.muyu.common.cache.BasicCacheData;
|
|
||||||
import com.muyu.common.cache.abs.CacheAbs;
|
|
||||||
import com.muyu.openbusiness.domain.SysCar;
|
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
|
||||||
import org.springframework.stereotype.Component;
|
|
||||||
|
|
||||||
@Component
|
|
||||||
public class VehicleCacheService extends CacheAbs<String, SysCar> {
|
|
||||||
|
|
||||||
@Autowired
|
|
||||||
private BasicCacheData<String, SysCar> basicCacheData;
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public SysCar getData(String key) {
|
|
||||||
return basicCacheData.apply(key);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public SysCar defaultValue() {
|
|
||||||
return SysCar.builder().build();
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public String keyPre() {
|
|
||||||
return "car:info:";
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public String decode(String redisKey) {
|
|
||||||
return redisKey.replace(keyPre(), "");
|
|
||||||
}
|
|
||||||
}
|
|
|
@ -0,0 +1,31 @@
|
||||||
|
package com.muyu.openbusiness.apply;
|
||||||
|
|
||||||
|
import com.muyu.common.cache.abs.CacheAbs;
|
||||||
|
import com.muyu.openbusiness.domain.SysCarMessage;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
//车辆全部缓存
|
||||||
|
public class InforMationDataService extends CacheAbs<String, List<SysCarMessage>> {
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public List<SysCarMessage> getData(String key) {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public List<SysCarMessage> defaultValue() {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public String keyPre() {
|
||||||
|
return "";
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public String decode(String redisKey) {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
}
|
|
@ -0,0 +1,34 @@
|
||||||
|
package com.muyu.openbusiness.apply;
|
||||||
|
|
||||||
|
import com.muyu.common.cache.abs.CacheAbs;
|
||||||
|
import com.muyu.openbusiness.domain.SysCarMessage;
|
||||||
|
import org.springframework.stereotype.Component;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
@Component
|
||||||
|
public class MessageValueCacheService extends CacheAbs<String, List<SysCarMessage>> {
|
||||||
|
|
||||||
|
|
||||||
|
//缓存
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public List<SysCarMessage> getData(String key) {
|
||||||
|
return new InforMationDataService().getData(key);
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public List<SysCarMessage> defaultValue() {
|
||||||
|
return new InforMationDataService().defaultValue();
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public String keyPre() {
|
||||||
|
return "messageVlue:info:";
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public String decode(String key){
|
||||||
|
return key.replace("messageValue:info", "");
|
||||||
|
}
|
||||||
|
}
|
|
@ -1,23 +1,23 @@
|
||||||
package com.muyu.openbusiness.apply;
|
//package com.muyu.openbusiness.apply;
|
||||||
|
//
|
||||||
import com.muyu.common.cache.BasicCacheData;
|
//import com.muyu.common.cache.BasicCacheData;
|
||||||
import com.muyu.openbusiness.domain.SysCar;
|
//import com.muyu.openbusiness.domain.SysCar;
|
||||||
import com.muyu.openbusiness.remote.SysCarRemoteService;
|
////import com.muyu.openbusiness.remote.SysCarRemoteService;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
//import org.springframework.beans.factory.annotation.Autowired;
|
||||||
import org.springframework.stereotype.Component;
|
//import org.springframework.stereotype.Component;
|
||||||
|
//
|
||||||
/**
|
///**
|
||||||
* 键和值转换 - 车辆数据
|
// * 键和值转换 - 车辆数据
|
||||||
*/
|
// */
|
||||||
@Component
|
//@Component
|
||||||
public class SysCarCacheRemoteData implements BasicCacheData<String, SysCar> {
|
//public class SysCarCacheRemoteData implements BasicCacheData<String, SysCar> {
|
||||||
|
//
|
||||||
|
//
|
||||||
@Autowired
|
// @Autowired
|
||||||
private SysCarRemoteService sysCarRemoteService;
|
// private SysCarRemoteService sysCarRemoteService;
|
||||||
|
//
|
||||||
@Override
|
// @Override
|
||||||
public SysCar apply(String key) {
|
// public SysCar apply(String key) {
|
||||||
return sysCarRemoteService.findByVin(key).getData();
|
// return sysCarRemoteService.findByVin(key).getData();
|
||||||
}
|
// }
|
||||||
}
|
//}
|
||||||
|
|
|
@ -0,0 +1,22 @@
|
||||||
|
//package com.muyu.openbusiness.apply;
|
||||||
|
//
|
||||||
|
//import com.muyu.common.cache.BasicCacheData;
|
||||||
|
//import com.muyu.openbusiness.domain.SysCar;
|
||||||
|
//import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
//import org.springframework.stereotype.Component;
|
||||||
|
//
|
||||||
|
///**
|
||||||
|
// * 键和值转换 - 车辆数据
|
||||||
|
// */
|
||||||
|
//@Component
|
||||||
|
//public class SysCarCachessRemoteData implements BasicCacheData<String, SysCar> {
|
||||||
|
//
|
||||||
|
//
|
||||||
|
// @Autowired
|
||||||
|
// private SysCarRemoteService sysCarRemoteService;
|
||||||
|
//
|
||||||
|
// @Override
|
||||||
|
// public SysCar apply(String key) {
|
||||||
|
// return sysCarRemoteService.findByVin(key).getData();
|
||||||
|
// }
|
||||||
|
//}
|
|
@ -0,0 +1,37 @@
|
||||||
|
package com.muyu.openbusiness.apply;
|
||||||
|
|
||||||
|
import com.muyu.common.cache.abs.CacheAbs;
|
||||||
|
/**
|
||||||
|
* 车型缓存服务
|
||||||
|
* @version 1.0
|
||||||
|
* @Author zhang yi
|
||||||
|
* @Date 2024/9/30 11:18
|
||||||
|
* @注释
|
||||||
|
*/
|
||||||
|
public class SysCarTypeCacheService extends CacheAbs<String, String> {
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public String defaultValue() {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public String keyPre() {
|
||||||
|
return "sysCarType:info:";
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public String encode(String key){
|
||||||
|
return super.encode(key);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public String decode(String redisKey) {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public String getData(String key) {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
}
|
|
@ -0,0 +1,35 @@
|
||||||
|
package com.muyu.openbusiness.apply;
|
||||||
|
|
||||||
|
import com.muyu.common.cache.abs.CacheAbs;
|
||||||
|
import com.muyu.openbusiness.domain.VehicleMessage;
|
||||||
|
import org.springframework.stereotype.Component;
|
||||||
|
/**
|
||||||
|
* 车辆缓存服务
|
||||||
|
* @className: VehicleCacheService ️✈️
|
||||||
|
* @author: zhang yi 🦅
|
||||||
|
* @date: 2024/9/30 00:36 ⏰
|
||||||
|
* @Version: 1.0
|
||||||
|
* @description:
|
||||||
|
*/
|
||||||
|
@Component
|
||||||
|
public class VehiCachService extends CacheAbs<String, VehicleMessage> {
|
||||||
|
@Override
|
||||||
|
public VehicleMessage getData(String key) {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public VehicleMessage defaultValue() {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public String keyPre() {
|
||||||
|
return "FaultCodeCache:info";
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public String decode(String key){
|
||||||
|
return key.replace("vehicle:info","");
|
||||||
|
}
|
||||||
|
}
|
|
@ -0,0 +1,49 @@
|
||||||
|
package com.muyu.openbusiness.apply;
|
||||||
|
|
||||||
|
import com.muyu.common.cache.abs.CacheAbs;
|
||||||
|
import com.muyu.openbusiness.domain.BreakDown;
|
||||||
|
import com.muyu.openbusiness.domain.VehicleMessage;
|
||||||
|
import com.muyu.openbusiness.domain.WarnRule;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
/**
|
||||||
|
* 预警缓存服务
|
||||||
|
* @Author:yan
|
||||||
|
* @Package:com.muyu.enterpise.cache
|
||||||
|
* @Project:plus
|
||||||
|
* @name:WarnStrategyCacjeService
|
||||||
|
* @Date:2024/10/6 19:26
|
||||||
|
*/
|
||||||
|
public class WarnStrategyCarService extends CacheAbs<String, BreakDown> {
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public BreakDown getData(String key) {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public BreakDown defaultValue() {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public String keyPre() {
|
||||||
|
return "AllFenceGroup:info:";
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public String decode(String key){
|
||||||
|
return key.replace("AllFenceGroup:info:","");
|
||||||
|
}
|
||||||
|
|
||||||
|
public WarnRule findByWarnId(Long id) {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
|
public List<VehicleMessage> List() {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void put(String carVin, WarnRule respList) {
|
||||||
|
}
|
||||||
|
}
|
|
@ -0,0 +1 @@
|
||||||
|
com.muyu.openbusiness.apply.VehiCachService
|
|
@ -26,7 +26,7 @@ import com.baomidou.mybatisplus.annotation.IdType;
|
||||||
@NoArgsConstructor
|
@NoArgsConstructor
|
||||||
@AllArgsConstructor
|
@AllArgsConstructor
|
||||||
@TableName("sys_car")
|
@TableName("sys_car")
|
||||||
public class SysCar {
|
public class SysCar extends VehicleMessage {
|
||||||
private static final long serialVersionUID = 1L;
|
private static final long serialVersionUID = 1L;
|
||||||
|
|
||||||
/** 自增主键 */
|
/** 自增主键 */
|
||||||
|
|
|
@ -1,14 +1,14 @@
|
||||||
package com.muyu.openbusiness.remote;
|
//package com.muyu.openbusiness.remote;
|
||||||
|
//
|
||||||
import com.muyu.common.core.constant.ServiceNameConstants;
|
//import com.muyu.common.core.constant.ServiceNameConstants;
|
||||||
import com.muyu.common.core.domain.Result;
|
//import com.muyu.common.core.domain.Result;
|
||||||
import com.muyu.openbusiness.domain.SysCar;
|
//import com.muyu.openbusiness.domain.SysCar;
|
||||||
import org.springframework.cloud.openfeign.FeignClient;
|
//import org.springframework.cloud.openfeign.FeignClient;
|
||||||
import org.springframework.web.bind.annotation.GetMapping;
|
//import org.springframework.web.bind.annotation.GetMapping;
|
||||||
|
//
|
||||||
@FeignClient(contextId = "sysCarRemoteService", value = ServiceNameConstants.CAR_SERVICE)
|
//@FeignClient(contextId = "sysCarRemoteService", value = ServiceNameConstants.CAR_SERVICE)
|
||||||
public interface SysCarRemoteService {
|
//public interface SysCarRemoteService {
|
||||||
|
//
|
||||||
@GetMapping("/car/findByVin")
|
// @GetMapping("/car/findByVin")
|
||||||
public Result<SysCar> findByVin(String vin);
|
// public Result<SysCar> findByVin(String vin);
|
||||||
}
|
//}
|
||||||
|
|
|
@ -97,10 +97,6 @@
|
||||||
<artifactId>cloud-common-rabbit</artifactId>
|
<artifactId>cloud-common-rabbit</artifactId>
|
||||||
</dependency>
|
</dependency>
|
||||||
|
|
||||||
<dependency>
|
|
||||||
<groupId>com.muyu</groupId>
|
|
||||||
<artifactId>cloud-common-kafka</artifactId>
|
|
||||||
</dependency>
|
|
||||||
|
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>org.bouncycastle</groupId>
|
<groupId>org.bouncycastle</groupId>
|
||||||
|
@ -120,12 +116,7 @@
|
||||||
</dependency>
|
</dependency>
|
||||||
|
|
||||||
|
|
||||||
<dependency>
|
|
||||||
<groupId>com.muyu</groupId>
|
|
||||||
<artifactId>cloud-modules-carmanage</artifactId>
|
|
||||||
<version>3.6.3</version>
|
|
||||||
<scope>compile</scope>
|
|
||||||
</dependency>
|
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>org.springframework.cloud</groupId>
|
<groupId>org.springframework.cloud</groupId>
|
||||||
<artifactId>spring-cloud-starter-openfeign</artifactId>
|
<artifactId>spring-cloud-starter-openfeign</artifactId>
|
||||||
|
|
|
@ -1,4 +0,0 @@
|
||||||
package com.muyu.openbusiness.controller;
|
|
||||||
|
|
||||||
public class RailController {
|
|
||||||
}
|
|
|
@ -1,8 +1,6 @@
|
||||||
package com.muyu.openbusiness.controller;
|
package com.muyu.openbusiness.controller;
|
||||||
|
|
||||||
import com.muyu.common.security.utils.SecurityUtils;
|
import com.muyu.openbusiness.config.SnowflakeIdWorker;
|
||||||
import com.muyu.common.system.domain.SysMember;
|
|
||||||
import com.muyu.common.system.remote.RemoteUserService;
|
|
||||||
import com.muyu.openbusiness.domain.SysCar;
|
import com.muyu.openbusiness.domain.SysCar;
|
||||||
import com.muyu.openbusiness.service.ISysCarService;
|
import com.muyu.openbusiness.service.ISysCarService;
|
||||||
import com.muyu.common.core.domain.Result;
|
import com.muyu.common.core.domain.Result;
|
||||||
|
@ -12,10 +10,10 @@ import com.muyu.common.core.web.page.TableDataInfo;
|
||||||
import com.muyu.common.security.annotation.RequiresPermissions;
|
import com.muyu.common.security.annotation.RequiresPermissions;
|
||||||
import jakarta.servlet.http.HttpServletResponse;
|
import jakarta.servlet.http.HttpServletResponse;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.data.redis.core.RedisTemplate;
|
||||||
import org.springframework.validation.annotation.Validated;
|
import org.springframework.validation.annotation.Validated;
|
||||||
import org.springframework.web.bind.annotation.*;
|
import org.springframework.web.bind.annotation.*;
|
||||||
|
|
||||||
import javax.annotation.Resource;
|
|
||||||
import java.time.Instant;
|
import java.time.Instant;
|
||||||
import java.time.LocalDateTime;
|
import java.time.LocalDateTime;
|
||||||
import java.time.ZoneId;
|
import java.time.ZoneId;
|
||||||
|
@ -36,10 +34,9 @@ public class SysCarController extends BaseController
|
||||||
{
|
{
|
||||||
@Autowired
|
@Autowired
|
||||||
private ISysCarService sysCarService;
|
private ISysCarService sysCarService;
|
||||||
@Resource
|
|
||||||
private RemoteUserService remoteUserService;
|
|
||||||
|
|
||||||
|
|
||||||
|
@Autowired
|
||||||
|
private RedisTemplate redisTemplate;
|
||||||
/**
|
/**
|
||||||
* 查询车辆基础信息列表
|
* 查询车辆基础信息列表
|
||||||
*/
|
*/
|
||||||
|
@ -52,12 +49,6 @@ public class SysCarController extends BaseController
|
||||||
return getDataTable(list);
|
return getDataTable(list);
|
||||||
}
|
}
|
||||||
|
|
||||||
public List<SysCar> sysCarList()
|
|
||||||
{
|
|
||||||
List<SysCar> list = sysCarService.selectSysCarList(new SysCar());
|
|
||||||
return list;
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 导出车辆基础信息列表
|
* 导出车辆基础信息列表
|
||||||
*/
|
*/
|
||||||
|
@ -77,6 +68,13 @@ public class SysCarController extends BaseController
|
||||||
@GetMapping(value = "/{id}")
|
@GetMapping(value = "/{id}")
|
||||||
public Result<List<SysCar>> getInfo(@PathVariable("id") Long id)
|
public Result<List<SysCar>> getInfo(@PathVariable("id") Long id)
|
||||||
{
|
{
|
||||||
|
SnowflakeIdWorker snowMaker = new SnowflakeIdWorker();
|
||||||
|
for (int i = 0; i < 100; i++) {
|
||||||
|
long ids = snowMaker.nextId();
|
||||||
|
System.out.println(ids);
|
||||||
|
|
||||||
|
}
|
||||||
|
redisTemplate.opsForValue().set("ids",sysCarService.selectSysCarById(id));
|
||||||
return success(sysCarService.selectSysCarById(id));
|
return success(sysCarService.selectSysCarById(id));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -88,13 +86,6 @@ public class SysCarController extends BaseController
|
||||||
public Result<Integer> add(
|
public Result<Integer> add(
|
||||||
@Validated @RequestBody SysCar sysCar)
|
@Validated @RequestBody SysCar sysCar)
|
||||||
{
|
{
|
||||||
String saasKey = SecurityUtils.getSaasKey();
|
|
||||||
Result<SysMember> sysMemberResult = remoteUserService.selectSysMemberListById(saasKey);
|
|
||||||
SysMember sysMember = sysMemberResult.getData();
|
|
||||||
List<SysCar> list = this.sysCarList();
|
|
||||||
if(list.size()>=sysMember.getMemberCarNum()){
|
|
||||||
return Result.error("已达到当前会员等级可添加上限,请联系管理员升级会员等级");
|
|
||||||
}
|
|
||||||
// 获取当前时间(没有时区)
|
// 获取当前时间(没有时区)
|
||||||
LocalDateTime now = LocalDateTime.now();
|
LocalDateTime now = LocalDateTime.now();
|
||||||
// 假设我们使用系统默认时区
|
// 假设我们使用系统默认时区
|
||||||
|
|
|
@ -1,10 +1,12 @@
|
||||||
package com.muyu.openbusiness.controller;
|
package com.muyu.openbusiness.controller;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
||||||
import com.muyu.common.system.domain.SysUser;
|
import com.muyu.common.system.domain.SysUser;
|
||||||
import com.muyu.common.system.remote.RemoteDataService;
|
import com.muyu.common.system.remote.RemoteUserService;
|
||||||
|
import com.muyu.openbusiness.apply.VehiCachService;
|
||||||
|
import com.muyu.openbusiness.domain.SysCar;
|
||||||
import com.muyu.openbusiness.domain.SysCarMessage;
|
import com.muyu.openbusiness.domain.SysCarMessage;
|
||||||
|
|
||||||
import com.muyu.openbusiness.domain.req.SysCarMessageReq;
|
|
||||||
import com.muyu.openbusiness.service.ISysCarMessageService;
|
import com.muyu.openbusiness.service.ISysCarMessageService;
|
||||||
import com.muyu.common.core.domain.Result;
|
import com.muyu.common.core.domain.Result;
|
||||||
import com.muyu.common.core.utils.poi.ExcelUtil;
|
import com.muyu.common.core.utils.poi.ExcelUtil;
|
||||||
|
@ -30,24 +32,91 @@ import java.util.concurrent.ExecutionException;
|
||||||
* @date 2024-09-18
|
* @date 2024-09-18
|
||||||
*/
|
*/
|
||||||
@RestController
|
@RestController
|
||||||
@RequestMapping("/messageInfo")
|
@RequestMapping("/messagesInfo")
|
||||||
public class SysCarMessageController extends BaseController
|
public class SysCarMessageController extends BaseController
|
||||||
{
|
{
|
||||||
@Resource
|
@Resource
|
||||||
private ISysCarMessageService sysCarMessageService;
|
private ISysCarMessageService sysCarMessageService;
|
||||||
|
// @Autowired
|
||||||
|
// private SystemFeign feign;
|
||||||
@Resource
|
@Resource
|
||||||
private RemoteDataService remoteDataService;
|
private VehiCachService vehiCachService;
|
||||||
|
@Autowired
|
||||||
|
private HttpSession session;
|
||||||
|
|
||||||
|
@Autowired
|
||||||
|
RemoteUserService remoteUserService;
|
||||||
|
|
||||||
|
static String TEST = "7E 56 45 48 49 43 4C 45 5F 4D 53 47 3A 56 49 4E 31 32 B6 A1 C0 F2 B3 E5 D9 A8 C1 B2 E3 F4 A6 D7 C9 F1 E0 A3 B5 C8 D4 E2 A1 F5 B6 C7 E8 D9 A0 E3 B2 C4 F5 D6 A8 C0 E1 F2 B7 D8 A4 E3 C2 B1 A5 D9 F6 C8 E7 A0 B2 C3 D1 F4 E5 A9 3F 2A 7B D9 1E C8 4D A3 6F 5B 9A 0C 3E 7D F2 8B 46 1A 5E 9F 2D 73 8C 4A B1 6C 5D E2 7E C4 39 0B AD 7C 1F 0E 3C 68 92 B4 5A 7F 6E 81 0D 4B A5 E3 F9 2E 8A 37 6D 14 5C 73 8E D2 04 9B 3A 6C F1 70 BF 29 5F 8C 43 61 24 5D 7A 9C 0A D5 1B 3D 6E F4 78 3E 5B";
|
||||||
|
|
||||||
|
@RequiresPermissions("message:message:test")
|
||||||
|
@GetMapping("/test")
|
||||||
|
public Result test() throws InterruptedException, ExecutionException {
|
||||||
|
List<SysCarMessage> list = (List<SysCarMessage>) session.getAttribute("list");
|
||||||
|
|
||||||
|
// 检查 list 是否为空
|
||||||
|
if (list == null || list.isEmpty()) {
|
||||||
|
return Result.success(new String[0]); // 或者返回一个适当的错误消息
|
||||||
|
}
|
||||||
|
|
||||||
|
String[] test = TEST.split(" ");
|
||||||
|
String[] results = new String[list.size()];
|
||||||
|
|
||||||
|
List<CompletableFuture<String>> futures = new ArrayList<>();
|
||||||
|
|
||||||
|
for (SysCarMessage carMessage : list) {
|
||||||
|
futures.add(CompletableFuture.supplyAsync(() -> {
|
||||||
|
int startIndex = Integer.parseInt(carMessage.getMessageStartIndex()) - 1;
|
||||||
|
int endIndex = Integer.parseInt(carMessage.getMessageEndIndex());
|
||||||
|
StringBuilder hexBuilder = new StringBuilder();
|
||||||
|
|
||||||
|
for (int j = startIndex; j < endIndex; j++) {
|
||||||
|
hexBuilder.append(test[j]);
|
||||||
|
}
|
||||||
|
|
||||||
|
String hex = hexBuilder.toString();
|
||||||
|
char[] result = new char[hex.length() / 2];
|
||||||
|
|
||||||
|
for (int x = 0; x < hex.length(); x += 2) {
|
||||||
|
int high = Character.digit(hex.charAt(x), 16);
|
||||||
|
int low = Character.digit(hex.charAt(x + 1), 16);
|
||||||
|
result[x / 2] = (char) ((high << 4) + low);
|
||||||
|
}
|
||||||
|
|
||||||
|
return new String(result);
|
||||||
|
}));
|
||||||
|
}
|
||||||
|
|
||||||
|
for (int i = 0; i < futures.size(); i++) {
|
||||||
|
results[i] = futures.get(i).get();
|
||||||
|
}
|
||||||
|
|
||||||
|
return Result.success(results);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 查询车辆报文记录列表
|
* 查询车辆报文记录列表
|
||||||
*/
|
*/
|
||||||
@RequiresPermissions("message:message:list")
|
@RequiresPermissions("message:message:list")
|
||||||
@GetMapping("/list")
|
@GetMapping("/list")
|
||||||
public Result<List<SysCarMessage>> list(SysCarMessageReq sysCarMessage)
|
public Result<List<SysCarMessage>> list(SysCarMessage sysCarMessage)
|
||||||
{
|
{
|
||||||
remoteDataService.carRealTimeStatus(sysCarMessage.getCarVin(),sysCarMessage.getFlag());
|
// Result info = feign.getInfo();
|
||||||
SysCarMessage message = new SysCarMessage();
|
// SysUser sysUser = (SysUser) info.getData();
|
||||||
message.setModelCode(sysCarMessage.getModelCode());
|
List<SysCarMessage> list = sysCarMessageService.selectSysCarMessageList(sysCarMessage);
|
||||||
List<SysCarMessage> list = sysCarMessageService.selectSysCarMessageList(message);
|
|
||||||
|
list.forEach(syscar -> {
|
||||||
|
List<SysCar> list1 = sysCarMessageService.selectSysCarMessageList(new LambdaQueryWrapper<SysCar>()
|
||||||
|
.eq(SysCar::getCarType,syscar.getMessageType()));
|
||||||
|
list1.forEach(sysCar -> {
|
||||||
|
|
||||||
|
vehiCachService.put(vehiCachService.keyPre()+sysCar.getCarVin(),sysCar);
|
||||||
|
});
|
||||||
|
});
|
||||||
|
|
||||||
|
|
||||||
|
session.setAttribute("list", list);
|
||||||
return Result.success(list);
|
return Result.success(list);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -68,7 +137,7 @@ public class SysCarMessageController extends BaseController
|
||||||
*/
|
*/
|
||||||
@RequiresPermissions("message:message:query")
|
@RequiresPermissions("message:message:query")
|
||||||
@GetMapping(value = "/{id}")
|
@GetMapping(value = "/{id}")
|
||||||
public Result<SysCarMessage> getInfo(@PathVariable("id") Long id)
|
public Result<List<SysCarMessage>> getInfo(@PathVariable("id") Long id)
|
||||||
{
|
{
|
||||||
return success(sysCarMessageService.selectSysCarMessageById(id));
|
return success(sysCarMessageService.selectSysCarMessageById(id));
|
||||||
}
|
}
|
||||||
|
@ -99,6 +168,8 @@ public class SysCarMessageController extends BaseController
|
||||||
if (!sysCarMessageService.checkIdUnique(sysCarMessage)) {
|
if (!sysCarMessageService.checkIdUnique(sysCarMessage)) {
|
||||||
return error("修改 车辆报文记录 '" + sysCarMessage + "'失败,车辆报文记录不存在");
|
return error("修改 车辆报文记录 '" + sysCarMessage + "'失败,车辆报文记录不存在");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
return toAjax(sysCarMessageService.updateById(sysCarMessage));
|
return toAjax(sysCarMessageService.updateById(sysCarMessage));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
package com.muyu.openbusiness.controller;
|
package com.muyu.openbusiness.controller;
|
||||||
|
|
||||||
import com.muyu.common.system.remote.RemoteDataService;
|
import com.muyu.openbusiness.config.SnowflakeIdWorker;
|
||||||
import com.muyu.openbusiness.domain.SysMessageType;
|
import com.muyu.openbusiness.domain.SysMessageType;
|
||||||
import com.muyu.openbusiness.service.ISysMessageTypeService;
|
import com.muyu.openbusiness.service.ISysMessageTypeService;
|
||||||
import com.muyu.common.core.domain.Result;
|
import com.muyu.common.core.domain.Result;
|
||||||
|
@ -8,6 +8,8 @@ import com.muyu.common.core.utils.poi.ExcelUtil;
|
||||||
import com.muyu.common.core.web.controller.BaseController;
|
import com.muyu.common.core.web.controller.BaseController;
|
||||||
import com.muyu.common.security.annotation.RequiresPermissions;
|
import com.muyu.common.security.annotation.RequiresPermissions;
|
||||||
import jakarta.servlet.http.HttpServletResponse;
|
import jakarta.servlet.http.HttpServletResponse;
|
||||||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.data.redis.core.RedisTemplate;
|
||||||
import org.springframework.validation.annotation.Validated;
|
import org.springframework.validation.annotation.Validated;
|
||||||
import org.springframework.web.bind.annotation.*;
|
import org.springframework.web.bind.annotation.*;
|
||||||
|
|
||||||
|
@ -26,9 +28,8 @@ import java.util.List;
|
||||||
public class SysMessageTypeController extends BaseController {
|
public class SysMessageTypeController extends BaseController {
|
||||||
@Resource
|
@Resource
|
||||||
private ISysMessageTypeService sysMessageTypeService;
|
private ISysMessageTypeService sysMessageTypeService;
|
||||||
@Resource
|
@Autowired
|
||||||
private RemoteDataService remoteDataService;
|
RedisTemplate redisTemplate;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 查询车辆报文类型列表
|
* 查询车辆报文类型列表
|
||||||
*/
|
*/
|
||||||
|
@ -37,6 +38,13 @@ public class SysMessageTypeController extends BaseController {
|
||||||
public Result<List<SysMessageType>> list(SysMessageType sysMessageType)
|
public Result<List<SysMessageType>> list(SysMessageType sysMessageType)
|
||||||
{
|
{
|
||||||
List<SysMessageType> list = sysMessageTypeService.selectSysMessageTypeList(sysMessageType);
|
List<SysMessageType> list = sysMessageTypeService.selectSysMessageTypeList(sysMessageType);
|
||||||
|
SnowflakeIdWorker snowMaker = new SnowflakeIdWorker();
|
||||||
|
for (int i = 0; i < 100; i++) {
|
||||||
|
long ids = snowMaker.nextId();
|
||||||
|
System.out.println(ids);
|
||||||
|
|
||||||
|
}
|
||||||
|
redisTemplate.opsForValue().set("ids",list);
|
||||||
return Result.success(list);
|
return Result.success(list);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -63,6 +71,13 @@ public class SysMessageTypeController extends BaseController {
|
||||||
for (int i = 0; i < messageCodes.length; i++) {
|
for (int i = 0; i < messageCodes.length; i++) {
|
||||||
list[i] = sysMessageTypeService.selectSysMessageTypeByMessageCode(messageCodes[i]);
|
list[i] = sysMessageTypeService.selectSysMessageTypeByMessageCode(messageCodes[i]);
|
||||||
}
|
}
|
||||||
|
SnowflakeIdWorker snowMaker = new SnowflakeIdWorker();
|
||||||
|
for (int i = 0; i < 100; i++) {
|
||||||
|
long ids = snowMaker.nextId();
|
||||||
|
System.out.println(ids);
|
||||||
|
|
||||||
|
}
|
||||||
|
redisTemplate.opsForValue().set("ids",list);
|
||||||
return success(list);
|
return success(list);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -5,9 +5,12 @@ import com.muyu.common.core.utils.poi.ExcelUtil;
|
||||||
import com.muyu.common.core.web.controller.BaseController;
|
import com.muyu.common.core.web.controller.BaseController;
|
||||||
import com.muyu.common.core.web.page.TableDataInfo;
|
import com.muyu.common.core.web.page.TableDataInfo;
|
||||||
import com.muyu.common.security.annotation.RequiresPermissions;
|
import com.muyu.common.security.annotation.RequiresPermissions;
|
||||||
|
import com.muyu.openbusiness.config.SnowflakeIdWorker;
|
||||||
import com.muyu.openbusiness.domain.WarnLogs;
|
import com.muyu.openbusiness.domain.WarnLogs;
|
||||||
import com.muyu.openbusiness.service.IWarnLogsService;
|
import com.muyu.openbusiness.service.IWarnLogsService;
|
||||||
import jakarta.servlet.http.HttpServletResponse;
|
import jakarta.servlet.http.HttpServletResponse;
|
||||||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.data.redis.core.RedisTemplate;
|
||||||
import org.springframework.validation.annotation.Validated;
|
import org.springframework.validation.annotation.Validated;
|
||||||
import org.springframework.web.bind.annotation.*;
|
import org.springframework.web.bind.annotation.*;
|
||||||
|
|
||||||
|
@ -27,6 +30,8 @@ public class WarnLogsController extends BaseController
|
||||||
{
|
{
|
||||||
@Resource
|
@Resource
|
||||||
private IWarnLogsService warnLogsService;
|
private IWarnLogsService warnLogsService;
|
||||||
|
@Autowired
|
||||||
|
private RedisTemplate redisTemplate;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 查询预警日志列表
|
* 查询预警日志列表
|
||||||
|
@ -37,6 +42,13 @@ public class WarnLogsController extends BaseController
|
||||||
{
|
{
|
||||||
startPage();
|
startPage();
|
||||||
List<WarnLogs> list = warnLogsService.selectWarnLogsList(warnLogs);
|
List<WarnLogs> list = warnLogsService.selectWarnLogsList(warnLogs);
|
||||||
|
SnowflakeIdWorker snowMaker = new SnowflakeIdWorker();
|
||||||
|
for (int i = 0; i < 100; i++) {
|
||||||
|
long ids = snowMaker.nextId();
|
||||||
|
System.out.println(ids);
|
||||||
|
|
||||||
|
}
|
||||||
|
redisTemplate.opsForValue().set("ids",list);
|
||||||
return getDataTable(list);
|
return getDataTable(list);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -59,6 +71,15 @@ public class WarnLogsController extends BaseController
|
||||||
@GetMapping(value = "/{id}")
|
@GetMapping(value = "/{id}")
|
||||||
public Result<List<WarnLogs>> getInfo(@PathVariable("id") Long id)
|
public Result<List<WarnLogs>> getInfo(@PathVariable("id") Long id)
|
||||||
{
|
{
|
||||||
|
SnowflakeIdWorker snowMaker = new SnowflakeIdWorker();
|
||||||
|
for (int i = 0; i < 100; i++) {
|
||||||
|
long ids = snowMaker.nextId();
|
||||||
|
System.out.println(ids);
|
||||||
|
|
||||||
|
}
|
||||||
|
redisTemplate.opsForValue().set("ids",warnLogsService.selectWarnLogsById(id));
|
||||||
|
|
||||||
|
|
||||||
return success(warnLogsService.selectWarnLogsById(id));
|
return success(warnLogsService.selectWarnLogsById(id));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -5,10 +5,13 @@ import com.muyu.common.core.utils.poi.ExcelUtil;
|
||||||
import com.muyu.common.core.web.controller.BaseController;
|
import com.muyu.common.core.web.controller.BaseController;
|
||||||
import com.muyu.common.core.web.page.TableDataInfo;
|
import com.muyu.common.core.web.page.TableDataInfo;
|
||||||
import com.muyu.common.security.annotation.RequiresPermissions;
|
import com.muyu.common.security.annotation.RequiresPermissions;
|
||||||
|
import com.muyu.openbusiness.config.SnowflakeIdWorker;
|
||||||
import com.muyu.openbusiness.domain.WarnRule;
|
import com.muyu.openbusiness.domain.WarnRule;
|
||||||
import com.muyu.openbusiness.domain.WarnRuleDTO;
|
import com.muyu.openbusiness.domain.WarnRuleDTO;
|
||||||
import com.muyu.openbusiness.service.IWarnRuleService;
|
import com.muyu.openbusiness.service.IWarnRuleService;
|
||||||
import jakarta.servlet.http.HttpServletResponse;
|
import jakarta.servlet.http.HttpServletResponse;
|
||||||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.data.redis.core.RedisTemplate;
|
||||||
import org.springframework.validation.annotation.Validated;
|
import org.springframework.validation.annotation.Validated;
|
||||||
import org.springframework.web.bind.annotation.*;
|
import org.springframework.web.bind.annotation.*;
|
||||||
|
|
||||||
|
@ -28,6 +31,8 @@ public class WarnRuleController extends BaseController {
|
||||||
@Resource
|
@Resource
|
||||||
private IWarnRuleService warnRuleService;
|
private IWarnRuleService warnRuleService;
|
||||||
|
|
||||||
|
@Autowired
|
||||||
|
RedisTemplate redisTemplate;
|
||||||
/**
|
/**
|
||||||
* 查询预警规则列表
|
* 查询预警规则列表
|
||||||
*/
|
*/
|
||||||
|
@ -41,6 +46,14 @@ public class WarnRuleController extends BaseController {
|
||||||
// .select(WarnStrategy::getStrategyName)
|
// .select(WarnStrategy::getStrategyName)
|
||||||
// .leftJoin(WarnStrategy.class, WarnStrategy::getId, WarnRule::getStrategyId)
|
// .leftJoin(WarnStrategy.class, WarnStrategy::getId, WarnRule::getStrategyId)
|
||||||
// .stringQuery();
|
// .stringQuery();
|
||||||
|
SnowflakeIdWorker snowMaker = new SnowflakeIdWorker();
|
||||||
|
for (int i = 0; i < 100; i++) {
|
||||||
|
long ids = snowMaker.nextId();
|
||||||
|
System.out.println(ids);
|
||||||
|
|
||||||
|
}
|
||||||
|
redisTemplate.opsForValue().set("ids",getDataTable(list));
|
||||||
|
|
||||||
return getDataTable(list);
|
return getDataTable(list);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -52,6 +65,7 @@ public class WarnRuleController extends BaseController {
|
||||||
public void export(HttpServletResponse response, WarnRuleDTO warnRuleDTO) {
|
public void export(HttpServletResponse response, WarnRuleDTO warnRuleDTO) {
|
||||||
List<WarnRuleDTO> list = warnRuleService.selectWarnRuleList(warnRuleDTO);
|
List<WarnRuleDTO> list = warnRuleService.selectWarnRuleList(warnRuleDTO);
|
||||||
ExcelUtil<WarnRuleDTO> util = new ExcelUtil<WarnRuleDTO>(WarnRuleDTO.class);
|
ExcelUtil<WarnRuleDTO> util = new ExcelUtil<WarnRuleDTO>(WarnRuleDTO.class);
|
||||||
|
|
||||||
util.exportExcel(response, list, "预警规则数据");
|
util.exportExcel(response, list, "预警规则数据");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -5,9 +5,12 @@ import com.muyu.common.core.utils.poi.ExcelUtil;
|
||||||
import com.muyu.common.core.web.controller.BaseController;
|
import com.muyu.common.core.web.controller.BaseController;
|
||||||
import com.muyu.common.core.web.page.TableDataInfo;
|
import com.muyu.common.core.web.page.TableDataInfo;
|
||||||
import com.muyu.common.security.annotation.RequiresPermissions;
|
import com.muyu.common.security.annotation.RequiresPermissions;
|
||||||
|
import com.muyu.openbusiness.config.SnowflakeIdWorker;
|
||||||
import com.muyu.openbusiness.domain.WarnStrategy;
|
import com.muyu.openbusiness.domain.WarnStrategy;
|
||||||
import com.muyu.openbusiness.service.IWarnStrategyService;
|
import com.muyu.openbusiness.service.IWarnStrategyService;
|
||||||
import jakarta.servlet.http.HttpServletResponse;
|
import jakarta.servlet.http.HttpServletResponse;
|
||||||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.data.redis.core.RedisTemplate;
|
||||||
import org.springframework.validation.annotation.Validated;
|
import org.springframework.validation.annotation.Validated;
|
||||||
import org.springframework.web.bind.annotation.*;
|
import org.springframework.web.bind.annotation.*;
|
||||||
|
|
||||||
|
@ -26,6 +29,8 @@ import java.util.List;
|
||||||
public class WarnStrategyController extends BaseController {
|
public class WarnStrategyController extends BaseController {
|
||||||
@Resource
|
@Resource
|
||||||
private IWarnStrategyService warnStrategyService;
|
private IWarnStrategyService warnStrategyService;
|
||||||
|
@Autowired
|
||||||
|
private RedisTemplate redisTemplate;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 查询预警策略列表
|
* 查询预警策略列表
|
||||||
|
@ -35,6 +40,15 @@ public class WarnStrategyController extends BaseController {
|
||||||
public Result<TableDataInfo<WarnStrategy>> list(WarnStrategy warnStrategy) {
|
public Result<TableDataInfo<WarnStrategy>> list(WarnStrategy warnStrategy) {
|
||||||
startPage();
|
startPage();
|
||||||
List<WarnStrategy> list = warnStrategyService.selectWarnStrategyList(warnStrategy);
|
List<WarnStrategy> list = warnStrategyService.selectWarnStrategyList(warnStrategy);
|
||||||
|
SnowflakeIdWorker snowMaker = new SnowflakeIdWorker();
|
||||||
|
for (int i = 0; i < 100; i++) {
|
||||||
|
long ids = snowMaker.nextId();
|
||||||
|
System.out.println(ids);
|
||||||
|
|
||||||
|
}
|
||||||
|
redisTemplate.opsForValue().set("ids",getDataTable(list));
|
||||||
|
|
||||||
|
|
||||||
return getDataTable(list);
|
return getDataTable(list);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -1,6 +1,8 @@
|
||||||
package com.muyu.openbusiness.service;
|
package com.muyu.openbusiness.service;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
||||||
import com.baomidou.mybatisplus.extension.service.IService;
|
import com.baomidou.mybatisplus.extension.service.IService;
|
||||||
|
import com.muyu.openbusiness.domain.SysCar;
|
||||||
import com.muyu.openbusiness.domain.SysCarMessage;
|
import com.muyu.openbusiness.domain.SysCarMessage;
|
||||||
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
@ -35,4 +37,6 @@ public interface ISysCarMessageService extends IService<SysCarMessage> {
|
||||||
*/
|
*/
|
||||||
Boolean checkIdUnique(SysCarMessage sysCarMessage);
|
Boolean checkIdUnique(SysCarMessage sysCarMessage);
|
||||||
|
|
||||||
|
|
||||||
|
List<SysCar> selectSysCarMessageList(LambdaQueryWrapper<SysCar> eq);
|
||||||
}
|
}
|
||||||
|
|
|
@ -4,6 +4,7 @@ import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
||||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||||
import com.muyu.common.core.utils.StringUtils;
|
import com.muyu.common.core.utils.StringUtils;
|
||||||
import com.muyu.openbusiness.config.SnowflakeIdWorker;
|
import com.muyu.openbusiness.config.SnowflakeIdWorker;
|
||||||
|
import com.muyu.openbusiness.domain.SysCar;
|
||||||
import com.muyu.openbusiness.domain.SysCarMessage;
|
import com.muyu.openbusiness.domain.SysCarMessage;
|
||||||
import com.muyu.openbusiness.mapper.SysCarMessageMapper;
|
import com.muyu.openbusiness.mapper.SysCarMessageMapper;
|
||||||
import com.muyu.openbusiness.service.ISysCarMessageService;
|
import com.muyu.openbusiness.service.ISysCarMessageService;
|
||||||
|
@ -91,4 +92,11 @@ public class SysCarMessageServiceImpl
|
||||||
return this.count(queryWrapper) > 0;
|
return this.count(queryWrapper) > 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public List<SysCar> selectSysCarMessageList(LambdaQueryWrapper<SysCar> eq) {
|
||||||
|
LambdaQueryWrapper<SysCarMessage> queryWrapper = new LambdaQueryWrapper<>();
|
||||||
|
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -111,6 +111,12 @@
|
||||||
<groupId>io.netty</groupId>
|
<groupId>io.netty</groupId>
|
||||||
<artifactId>netty-codec-mqtt</artifactId>
|
<artifactId>netty-codec-mqtt</artifactId>
|
||||||
</dependency>
|
</dependency>
|
||||||
|
<dependency>
|
||||||
|
<groupId>com.muyu</groupId>
|
||||||
|
<artifactId>cloud-modules-car-gateway</artifactId>
|
||||||
|
<version>3.6.3</version>
|
||||||
|
<scope>compile</scope>
|
||||||
|
</dependency>
|
||||||
</dependencies>
|
</dependencies>
|
||||||
|
|
||||||
<build>
|
<build>
|
||||||
|
|
|
@ -35,7 +35,7 @@ import java.util.concurrent.ExecutionException;
|
||||||
@Slf4j
|
@Slf4j
|
||||||
@RestController
|
@RestController
|
||||||
@RequestMapping("/messageInfo")
|
@RequestMapping("/messageInfo")
|
||||||
public class SysCarMessageController extends BaseController {
|
public class SysCarMessagesController extends BaseController {
|
||||||
@Resource
|
@Resource
|
||||||
private ISysCarMessageService sysCarMessageService;
|
private ISysCarMessageService sysCarMessageService;
|
||||||
@Resource
|
@Resource
|
|
@ -60,7 +60,7 @@ public class SysFirmController extends BaseController
|
||||||
/**
|
/**
|
||||||
* 查询企业基础信息列表
|
* 查询企业基础信息列表
|
||||||
*/
|
*/
|
||||||
@RequiresPermissions("firm:firmInfo:list")
|
// @RequiresPermissions("firm:firmInfo:list")
|
||||||
@GetMapping("/list")
|
@GetMapping("/list")
|
||||||
public Result<TableDataInfo<SysFirm>> list(SysFirm sysFirm)
|
public Result<TableDataInfo<SysFirm>> list(SysFirm sysFirm)
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in New Issue