Commit 53183c68 by 刘宇峰

V1.3.0需求开发-业务日志

1 parent bf8b64c7
package cn.com.glsx.admin.modules.model.param;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
/**
* 新增试驾车辆的实体类
*/
@Data
@NoArgsConstructor
@AllArgsConstructor
public class TestVehicleBo {
/**
* 车辆Id
......
......@@ -477,7 +477,7 @@ public class VehicleService {
.setModule("车辆管理")
.setAction("车辆解绑")
.setRemark("删除车辆试驾关系")
.setRequestData(JsonUtils.toJsonStr(vdId));
.setRequestData(JsonUtils.toJsonStr(new TestVehicleBo(vehicleDevice.getVehicleId(), vehicleDevice.getSn())));
logginApiService.addCustomLog(log);
}
......
......@@ -2,6 +2,7 @@ package cn.com.glsx.admin.modules.service;
import cn.com.glsx.Application;
import cn.com.glsx.admin.modules.model.param.TrackInfoBo;
import cn.com.glsx.loggincenter.api.dto.request.CustomLogRequest;
import lombok.extern.slf4j.Slf4j;
import org.junit.Test;
import org.junit.runner.RunWith;
......@@ -17,6 +18,9 @@ public class DeviceServiceTest {
@Autowired
private DeviceService deviceService;
@Autowired
private LogginApiService logginApiService;
@Test
public void testRemoteGetDeviceBySnAndSave() {
TrackInfoBo trackInfoBo = deviceService.remoteGetDeviceBySn("8130902002");
......@@ -24,4 +28,12 @@ public class DeviceServiceTest {
deviceService.saveTrackInfoBo(trackInfoBo, 10001L);
}
@Test
public void testLogs() {
//自定义日志
CustomLogRequest log = new CustomLogRequest();
log.setModule("车辆管理").setAction("车辆解绑").setRemark("删除车辆试驾关系");
logginApiService.addCustomLog(log);
}
}
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!