From 7b5d4c535ab770db4238389759c5e6a66ea7e661 Mon Sep 17 00:00:00 2001
From: Xiajijian <1176061145@qq.com>
Date: Wed, 04 Mar 2026 11:12:35 +0800
Subject: [PATCH] 1. 增加点云文件信息接口业务。 2. yml文件增加路径配置。
---
ard-admin/src/main/java/com/ard/web/controller/inspection/BigFileUploadController.java | 14
ard-route/src/main/java/com/ard/route/domain/djuav/TargetPosObj.java | 29 ++
ard-route/src/main/java/com/ard/route/domain/route/ArdRouteInfo.java | 9
ard-admin/src/main/java/com/ard/web/controller/inspection/ArdPointCloudController.java | 104 ++++++++++
ard-route/src/main/java/com/ard/route/util/ToolUtils.java | 4
ard-admin/src/main/resources/application.yml | 8
ard-route/src/main/java/com/ard/route/domain/djuav/RoutePointReq.java | 16 +
ard-inspection/src/main/java/com/ard/inspection/service/IArdPointCloudService.java | 61 ++++++
ard-inspection/src/main/resources/mapper/ArdPointCloudMapper.xml | 105 ++++++++++
ard-inspection/src/main/java/com/ard/inspection/domain/ArdPointCloud.java | 47 ++++
ard-route/src/main/java/com/ard/route/domain/djuav/WaypointTurnReq.java | 1
ard-inspection/src/main/java/com/ard/inspection/mapper/ArdPointCloudMapper.java | 61 ++++++
ard-inspection/src/main/java/com/ard/inspection/service/impl/ArdPointCloudServiceImpl.java | 92 +++++++++
13 files changed, 539 insertions(+), 12 deletions(-)
diff --git a/ard-admin/src/main/java/com/ard/web/controller/inspection/ArdPointCloudController.java b/ard-admin/src/main/java/com/ard/web/controller/inspection/ArdPointCloudController.java
new file mode 100644
index 0000000..4250fb1
--- /dev/null
+++ b/ard-admin/src/main/java/com/ard/web/controller/inspection/ArdPointCloudController.java
@@ -0,0 +1,104 @@
+package com.ard.web.controller.inspection;
+
+import java.util.List;
+import javax.servlet.http.HttpServletResponse;
+
+import com.ard.common.annotation.Log;
+import com.ard.common.core.controller.BaseController;
+import com.ard.common.core.domain.AjaxResult;
+import com.ard.common.core.page.TableDataInfo;
+import com.ard.common.enums.BusinessType;
+import com.ard.common.utils.poi.ExcelUtil;
+import io.swagger.annotations.Api;
+import lombok.extern.slf4j.Slf4j;
+import org.springframework.security.access.prepost.PreAuthorize;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.web.bind.annotation.GetMapping;
+import org.springframework.web.bind.annotation.PostMapping;
+import org.springframework.web.bind.annotation.PutMapping;
+import org.springframework.web.bind.annotation.DeleteMapping;
+import org.springframework.web.bind.annotation.PathVariable;
+import org.springframework.web.bind.annotation.RequestBody;
+import org.springframework.web.bind.annotation.RequestMapping;
+import org.springframework.web.bind.annotation.RestController;
+import com.ard.inspection.domain.ArdPointCloud;
+import com.ard.inspection.service.IArdPointCloudService;
+
+/**
+ * 点云文件Controller
+ *
+ * @author xia
+ * @date 2026-03-03
+ */
+@Api(tags = "点云文件信息")
+@RestController
+@RequestMapping("/inspection/cloud")
+@Slf4j
+public class ArdPointCloudController extends BaseController {
+
+ @Autowired
+ private IArdPointCloudService ardPointCloudService;
+
+ /**
+ * 查询点云文件列表
+ */
+ @PreAuthorize("@ss.hasPermi('inspection:cloud:list')")
+ @GetMapping("/list")
+ public TableDataInfo list(ArdPointCloud ardPointCloud) {
+ startPage();
+ List<ArdPointCloud> list = ardPointCloudService.selectArdPointCloudList(ardPointCloud);
+ return getDataTable(list);
+ }
+
+ /**
+ * 导出点云文件列表
+ */
+ @PreAuthorize("@ss.hasPermi('inspection:cloud:export')")
+ @Log(title = "点云文件", businessType = BusinessType.EXPORT)
+ @PostMapping("/export")
+ public void export(HttpServletResponse response, ArdPointCloud ardPointCloud) {
+ List<ArdPointCloud> list = ardPointCloudService.selectArdPointCloudList(ardPointCloud);
+ ExcelUtil<ArdPointCloud> util = new ExcelUtil<ArdPointCloud>(ArdPointCloud.class);
+ util.exportExcel(response, list, "点云文件数据");
+ }
+
+ /**
+ * 获取点云文件详细信息
+ */
+ @PreAuthorize("@ss.hasPermi('inspection:cloud:query')")
+ @GetMapping(value = "/{id}")
+ public AjaxResult getInfo(@PathVariable("id") String id) {
+ return success(ardPointCloudService.selectArdPointCloudById(id));
+ }
+
+ /**
+ * 新增点云文件
+ */
+ @PreAuthorize("@ss.hasPermi('inspection:cloud:add')")
+ @Log(title = "点云文件", businessType = BusinessType.INSERT)
+ @PostMapping
+ public AjaxResult add(@RequestBody ArdPointCloud ardPointCloud) {
+ return toAjax(ardPointCloudService.insertArdPointCloud(ardPointCloud));
+ }
+
+ /**
+ * 修改点云文件
+ */
+ @PreAuthorize("@ss.hasPermi('inspection:cloud:edit')")
+ @Log(title = "点云文件", businessType = BusinessType.UPDATE)
+ @PutMapping
+ public AjaxResult edit(@RequestBody ArdPointCloud ardPointCloud) {
+ return toAjax(ardPointCloudService.updateArdPointCloud(ardPointCloud));
+ }
+
+ /**
+ * 删除点云文件
+ */
+ @PreAuthorize("@ss.hasPermi('inspection:cloud:remove')")
+ @Log(title = "点云文件", businessType = BusinessType.DELETE)
+ @DeleteMapping("/{ids}")
+ public AjaxResult remove(@PathVariable String[] ids) {
+ return toAjax(ardPointCloudService.deleteArdPointCloudByIds(ids));
+ }
+
+}
diff --git a/ard-admin/src/main/java/com/ard/web/controller/inspection/BigFileUploadController.java b/ard-admin/src/main/java/com/ard/web/controller/inspection/BigFileUploadController.java
index 314e429..de174e2 100644
--- a/ard-admin/src/main/java/com/ard/web/controller/inspection/BigFileUploadController.java
+++ b/ard-admin/src/main/java/com/ard/web/controller/inspection/BigFileUploadController.java
@@ -5,6 +5,7 @@
import com.ard.common.core.domain.AjaxResult;
import com.ard.common.enums.BusinessType;
import com.ard.inspection.service.IBigFileUploadService;
+import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Value;
import io.swagger.annotations.Api;
@@ -26,16 +27,17 @@
@Autowired
private IBigFileUploadService bigFileUploadService;
- //@Value(value = "${inspection.profile}")
+ @Value(value = "${inspection.profile}")
private String uploadPath;
- //@Value(value = "${inspection.chunk.path}")
+ @Value(value = "${inspection.chunk.path}")
private String chunkPath;
/**
* 检查分片是否存在
*/
- @GetMapping("/chunks/{fileMd5}")
+ @ApiOperation("检查分片是否存在")
+ @GetMapping("/bigfile/{fileMd5}")
public AjaxResult checkChunk(@PathVariable String fileMd5) {
Map<String, Object> result = bigFileUploadService.checkChunk(fileMd5,chunkPath);
return AjaxResult.success(result);
@@ -44,7 +46,8 @@
/**
* 上传分片
*/
- @PostMapping("/chunk")
+ @ApiOperation("上传分片")
+ @PostMapping("/bigfile/chunk")
public AjaxResult uploadChunk(@RequestParam("file") MultipartFile file,
@RequestParam("chunkNumber") Integer chunkNumber,
@RequestParam("fileMd5") String fileMd5) {
@@ -55,8 +58,9 @@
/**
* 合并切片
*/
+ @ApiOperation("合并分片")
@Log(title = "合并切片", businessType = BusinessType.IMPORT)
- @PostMapping("/merge")
+ @PostMapping("/bigfile/merge")
public AjaxResult mergeChunks(@RequestParam("md5") String md5,
@RequestParam("fileName") String fileName) {
Map<String, Object> result = bigFileUploadService.mergeChunks(md5, fileName, uploadPath);
diff --git a/ard-admin/src/main/resources/application.yml b/ard-admin/src/main/resources/application.yml
index b039b51..45cc7c4 100644
--- a/ard-admin/src/main/resources/application.yml
+++ b/ard-admin/src/main/resources/application.yml
@@ -160,7 +160,11 @@
management-url: http://127.0.0.1:8080/actuator
service-url: http://127.0.0.1:8080/
-
# 激活配置文件
profiles:
- active: @spring.profiles.active@
\ No newline at end of file
+ active: @spring.profiles.active@
+
+inspection:
+ profile: /home/inspection/uploadPath # 上传文件存储路径
+ chunk:
+ path: /home/inspection/uploadPath/chunks # 切片临时目录
diff --git a/ard-inspection/src/main/java/com/ard/inspection/domain/ArdPointCloud.java b/ard-inspection/src/main/java/com/ard/inspection/domain/ArdPointCloud.java
new file mode 100644
index 0000000..0d2755a
--- /dev/null
+++ b/ard-inspection/src/main/java/com/ard/inspection/domain/ArdPointCloud.java
@@ -0,0 +1,47 @@
+package com.ard.inspection.domain;
+
+import com.ard.common.core.domain.BaseEntity;
+import lombok.Data;
+import lombok.EqualsAndHashCode;
+
+/**
+ * 点云文件
+ * @author xia
+ */
+@EqualsAndHashCode(callSuper = true)
+@Data
+public class ArdPointCloud extends BaseEntity {
+
+ /**
+ * ID
+ */
+ private String id;
+
+ /**
+ * 文件名称
+ */
+ private String fileName;
+
+ /**
+ * 文件大小
+ */
+ private Long fileSize;
+
+ /**
+ * 关联状态
+ * 0:未关联
+ * 1:已关联
+ */
+ private String associatedState;
+
+ /**
+ * 航线ID
+ */
+ private String routeId;
+
+ /**
+ * 分组ID
+ */
+ private String groupId;
+
+}
diff --git a/ard-inspection/src/main/java/com/ard/inspection/mapper/ArdPointCloudMapper.java b/ard-inspection/src/main/java/com/ard/inspection/mapper/ArdPointCloudMapper.java
new file mode 100644
index 0000000..3842125
--- /dev/null
+++ b/ard-inspection/src/main/java/com/ard/inspection/mapper/ArdPointCloudMapper.java
@@ -0,0 +1,61 @@
+package com.ard.inspection.mapper;
+
+import java.util.List;
+import com.ard.inspection.domain.ArdPointCloud;
+
+/**
+ * 点云文件Mapper接口
+ *
+ * @author xia
+ * @date 2026-03-03
+ */
+public interface ArdPointCloudMapper {
+
+ /**
+ * 查询点云文件
+ *
+ * @param id 点云文件主键
+ * @return 点云文件
+ */
+ public ArdPointCloud selectArdPointCloudById(String id);
+
+ /**
+ * 查询点云文件列表
+ *
+ * @param ardPointCloud 点云文件
+ * @return 点云文件集合
+ */
+ public List<ArdPointCloud> selectArdPointCloudList(ArdPointCloud ardPointCloud);
+
+ /**
+ * 新增点云文件
+ *
+ * @param ardPointCloud 点云文件
+ * @return 结果
+ */
+ public int insertArdPointCloud(ArdPointCloud ardPointCloud);
+
+ /**
+ * 修改点云文件
+ *
+ * @param ardPointCloud 点云文件
+ * @return 结果
+ */
+ public int updateArdPointCloud(ArdPointCloud ardPointCloud);
+
+ /**
+ * 删除点云文件
+ *
+ * @param id 点云文件主键
+ * @return 结果
+ */
+ public int deleteArdPointCloudById(String id);
+
+ /**
+ * 批量删除点云文件
+ *
+ * @param ids 需要删除的数据主键集合
+ * @return 结果
+ */
+ public int deleteArdPointCloudByIds(String[] ids);
+}
diff --git a/ard-inspection/src/main/java/com/ard/inspection/service/IArdPointCloudService.java b/ard-inspection/src/main/java/com/ard/inspection/service/IArdPointCloudService.java
new file mode 100644
index 0000000..17caff2
--- /dev/null
+++ b/ard-inspection/src/main/java/com/ard/inspection/service/IArdPointCloudService.java
@@ -0,0 +1,61 @@
+package com.ard.inspection.service;
+
+import java.util.List;
+import com.ard.inspection.domain.ArdPointCloud;
+
+/**
+ * 点云文件Service接口
+ *
+ * @author xia
+ * @date 2026-03-03
+ */
+public interface IArdPointCloudService {
+
+ /**
+ * 查询点云文件
+ *
+ * @param id 点云文件主键
+ * @return 点云文件
+ */
+ public ArdPointCloud selectArdPointCloudById(String id);
+
+ /**
+ * 查询点云文件列表
+ *
+ * @param ardPointCloud 点云文件
+ * @return 点云文件集合
+ */
+ public List<ArdPointCloud> selectArdPointCloudList(ArdPointCloud ardPointCloud);
+
+ /**
+ * 新增点云文件
+ *
+ * @param ardPointCloud 点云文件
+ * @return 结果
+ */
+ public int insertArdPointCloud(ArdPointCloud ardPointCloud);
+
+ /**
+ * 修改点云文件
+ *
+ * @param ardPointCloud 点云文件
+ * @return 结果
+ */
+ public int updateArdPointCloud(ArdPointCloud ardPointCloud);
+
+ /**
+ * 批量删除点云文件
+ *
+ * @param ids 需要删除的点云文件主键集合
+ * @return 结果
+ */
+ public int deleteArdPointCloudByIds(String[] ids);
+
+ /**
+ * 删除点云文件信息
+ *
+ * @param id 点云文件主键
+ * @return 结果
+ */
+ public int deleteArdPointCloudById(String id);
+}
diff --git a/ard-inspection/src/main/java/com/ard/inspection/service/impl/ArdPointCloudServiceImpl.java b/ard-inspection/src/main/java/com/ard/inspection/service/impl/ArdPointCloudServiceImpl.java
new file mode 100644
index 0000000..7a3a888
--- /dev/null
+++ b/ard-inspection/src/main/java/com/ard/inspection/service/impl/ArdPointCloudServiceImpl.java
@@ -0,0 +1,92 @@
+package com.ard.inspection.service.impl;
+
+import java.util.List;
+
+import com.ard.common.utils.DateUtils;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+import com.ard.inspection.mapper.ArdPointCloudMapper;
+import com.ard.inspection.domain.ArdPointCloud;
+import com.ard.inspection.service.IArdPointCloudService;
+
+/**
+ * 点云文件Service业务层处理
+ *
+ * @author xia
+ * @date 2026-03-03
+ */
+@Service
+public class ArdPointCloudServiceImpl implements IArdPointCloudService {
+
+ @Autowired
+ private ArdPointCloudMapper ardPointCloudMapper;
+
+ /**
+ * 查询点云文件
+ *
+ * @param id 点云文件主键
+ * @return 点云文件
+ */
+ @Override
+ public ArdPointCloud selectArdPointCloudById(String id) {
+ return ardPointCloudMapper.selectArdPointCloudById(id);
+ }
+
+ /**
+ * 查询点云文件列表
+ *
+ * @param ardPointCloud 点云文件
+ * @return 点云文件
+ */
+ @Override
+ public List<ArdPointCloud> selectArdPointCloudList(ArdPointCloud ardPointCloud) {
+ return ardPointCloudMapper.selectArdPointCloudList(ardPointCloud);
+ }
+
+ /**
+ * 新增点云文件
+ *
+ * @param ardPointCloud 点云文件
+ * @return 结果
+ */
+ @Override
+ public int insertArdPointCloud(ArdPointCloud ardPointCloud) {
+ ardPointCloud.setCreateTime(DateUtils.getNowDate());
+ return ardPointCloudMapper.insertArdPointCloud(ardPointCloud);
+ }
+
+ /**
+ * 修改点云文件
+ *
+ * @param ardPointCloud 点云文件
+ * @return 结果
+ */
+ @Override
+ public int updateArdPointCloud(ArdPointCloud ardPointCloud) {
+ ardPointCloud.setUpdateTime(DateUtils.getNowDate());
+ return ardPointCloudMapper.updateArdPointCloud(ardPointCloud);
+ }
+
+ /**
+ * 批量删除点云文件
+ *
+ * @param ids 需要删除的点云文件主键
+ * @return 结果
+ */
+ @Override
+ public int deleteArdPointCloudByIds(String[] ids) {
+ return ardPointCloudMapper.deleteArdPointCloudByIds(ids);
+ }
+
+ /**
+ * 删除点云文件信息
+ *
+ * @param id 点云文件主键
+ * @return 结果
+ */
+ @Override
+ public int deleteArdPointCloudById(String id) {
+ return ardPointCloudMapper.deleteArdPointCloudById(id);
+ }
+
+}
diff --git a/ard-inspection/src/main/resources/mapper/ArdPointCloudMapper.xml b/ard-inspection/src/main/resources/mapper/ArdPointCloudMapper.xml
new file mode 100644
index 0000000..b05f5c2
--- /dev/null
+++ b/ard-inspection/src/main/resources/mapper/ArdPointCloudMapper.xml
@@ -0,0 +1,105 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!DOCTYPE mapper
+PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
+"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
+<mapper namespace="com.ard.inspection.mapper.ArdPointCloudMapper">
+
+ <resultMap type="ArdPointCloud" id="ArdPointCloudResult">
+ <result property="id" column="id" />
+ <result property="fileName" column="file_name" />
+ <result property="fileSize" column="file_size" />
+ <result property="associatedState" column="associated_state" />
+ <result property="routeId" column="route_id" />
+ <result property="groupId" column="group_id" />
+ <result property="createBy" column="create_by" />
+ <result property="createTime" column="create_time" />
+ <result property="updateBy" column="update_by" />
+ <result property="updateTime" column="update_time" />
+ </resultMap>
+
+ <sql id="selectArdPointCloudVo">
+ select id,
+ file_name,
+ file_size,
+ associated_state,
+ route_id,
+ group_id,
+ create_by,
+ create_time,
+ update_by,
+ update_time
+ from ard_point_cloud
+ </sql>
+
+ <select id="selectArdPointCloudList" parameterType="ArdPointCloud" resultMap="ArdPointCloudResult">
+ <include refid="selectArdPointCloudVo"/>
+ <where>
+ <if test="fileName != null and fileName != ''"> and file_name like concat('%', #{fileName}, '%')</if>
+ <if test="fileSize != null "> and file_size = #{fileSize}</if>
+ <if test="associatedState != null and associatedState != ''"> and associated_state = #{associatedState}</if>
+ <if test="routeId != null and routeId != ''"> and route_id = #{routeId}</if>
+ <if test="groupId != null and groupId != ''"> and group_id = #{groupId}</if>
+ </where>
+ </select>
+
+ <select id="selectArdPointCloudById" parameterType="String" resultMap="ArdPointCloudResult">
+ <include refid="selectArdPointCloudVo"/>
+ where id = #{id}
+ </select>
+
+ <insert id="insertArdPointCloud" parameterType="ArdPointCloud">
+ insert into ard_point_cloud
+ <trim prefix="(" suffix=")" suffixOverrides=",">
+ <if test="id != null">id,</if>
+ <if test="fileName != null">file_name,</if>
+ <if test="fileSize != null">file_size,</if>
+ <if test="associatedState != null">associated_state,</if>
+ <if test="routeId != null">route_id,</if>
+ <if test="groupId != null">group_id,</if>
+ <if test="createBy != null">create_by,</if>
+ <if test="createTime != null">create_time,</if>
+ <if test="updateBy != null">update_by,</if>
+ <if test="updateTime != null">update_time,</if>
+ </trim>
+ <trim prefix="values (" suffix=")" suffixOverrides=",">
+ <if test="id != null">#{id},</if>
+ <if test="fileName != null">#{fileName},</if>
+ <if test="fileSize != null">#{fileSize},</if>
+ <if test="associatedState != null">#{associatedState},</if>
+ <if test="routeId != null">#{routeId},</if>
+ <if test="groupId != null">#{groupId},</if>
+ <if test="createBy != null">#{createBy},</if>
+ <if test="createTime != null">#{createTime},</if>
+ <if test="updateBy != null">#{updateBy},</if>
+ <if test="updateTime != null">#{updateTime},</if>
+ </trim>
+ </insert>
+
+ <update id="updateArdPointCloud" parameterType="ArdPointCloud">
+ update ard_point_cloud
+ <trim prefix="SET" suffixOverrides=",">
+ <if test="fileName != null">file_name = #{fileName},</if>
+ <if test="fileSize != null">file_size = #{fileSize},</if>
+ <if test="associatedState != null">associated_state = #{associatedState},</if>
+ <if test="routeId != null">route_id = #{routeId},</if>
+ <if test="groupId != null">group_id = #{groupId},</if>
+ <if test="createBy != null">create_by = #{createBy},</if>
+ <if test="createTime != null">create_time = #{createTime},</if>
+ <if test="updateBy != null">update_by = #{updateBy},</if>
+ <if test="updateTime != null">update_time = #{updateTime},</if>
+ </trim>
+ where id = #{id}
+ </update>
+
+ <delete id="deleteArdPointCloudById" parameterType="String">
+ delete from ard_point_cloud where id = #{id}
+ </delete>
+
+ <delete id="deleteArdPointCloudByIds" parameterType="String">
+ delete from ard_point_cloud where id in
+ <foreach item="id" collection="array" open="(" separator="," close=")">
+ #{id}
+ </foreach>
+ </delete>
+
+</mapper>
\ No newline at end of file
diff --git a/ard-route/src/main/java/com/ard/route/domain/djuav/RoutePointReq.java b/ard-route/src/main/java/com/ard/route/domain/djuav/RoutePointReq.java
index 07882b2..03fbdcf 100644
--- a/ard-route/src/main/java/com/ard/route/domain/djuav/RoutePointReq.java
+++ b/ard-route/src/main/java/com/ard/route/domain/djuav/RoutePointReq.java
@@ -7,6 +7,7 @@
/**
* 航点列表实体类
+ * @author xia
*/
@Data
public class RoutePointReq implements Serializable {
@@ -56,4 +57,19 @@
*/
private List<ActionGroupReq> actionGroupList;
+ /**
+ * 目标点
+ */
+ private TargetPosObj targetPosObj;
+
+ /**
+ * 当前航线距离
+ */
+ private Double distance;
+
+ /**
+ * 当前航线速度
+ */
+ private Integer nowGlobalFlightSpeed;
+
}
diff --git a/ard-route/src/main/java/com/ard/route/domain/djuav/TargetPosObj.java b/ard-route/src/main/java/com/ard/route/domain/djuav/TargetPosObj.java
new file mode 100644
index 0000000..dcb2596
--- /dev/null
+++ b/ard-route/src/main/java/com/ard/route/domain/djuav/TargetPosObj.java
@@ -0,0 +1,29 @@
+package com.ard.route.domain.djuav;
+
+import lombok.Data;
+
+import java.io.Serializable;
+
+/**
+ * 目标点
+ * @author xia
+ */
+@Data
+public class TargetPosObj implements Serializable {
+
+ /**
+ * 经度
+ */
+ private Double longitude;
+
+ /**
+ * 纬度
+ */
+ private Double latitude;
+
+ /**
+ * 高度
+ */
+ private Double height;
+
+}
diff --git a/ard-route/src/main/java/com/ard/route/domain/djuav/WaypointTurnReq.java b/ard-route/src/main/java/com/ard/route/domain/djuav/WaypointTurnReq.java
index 865a049..306bf98 100644
--- a/ard-route/src/main/java/com/ard/route/domain/djuav/WaypointTurnReq.java
+++ b/ard-route/src/main/java/com/ard/route/domain/djuav/WaypointTurnReq.java
@@ -26,5 +26,4 @@
*/
private Integer useStraightLine;
-
}
diff --git a/ard-route/src/main/java/com/ard/route/domain/route/ArdRouteInfo.java b/ard-route/src/main/java/com/ard/route/domain/route/ArdRouteInfo.java
index 54fece0..50ce0f9 100644
--- a/ard-route/src/main/java/com/ard/route/domain/route/ArdRouteInfo.java
+++ b/ard-route/src/main/java/com/ard/route/domain/route/ArdRouteInfo.java
@@ -5,6 +5,8 @@
import lombok.Data;
import lombok.EqualsAndHashCode;
+import java.io.Serializable;
+
/**
* 航线(kmz)对象 ard_route_info
*
@@ -13,9 +15,7 @@
*/
@EqualsAndHashCode(callSuper = true)
@Data
-public class ArdRouteInfo extends BaseEntity {
-
- private static final long serialVersionUID = 1L;
+public class ArdRouteInfo extends BaseEntity implements Serializable{
/** ID */
private String id;
@@ -78,4 +78,7 @@
/** 航线任务ID */
private String missionId;
+ /** 点云数据 */
+ //private List<>
+
}
diff --git a/ard-route/src/main/java/com/ard/route/util/ToolUtils.java b/ard-route/src/main/java/com/ard/route/util/ToolUtils.java
index 38bb620..a08e8c5 100644
--- a/ard-route/src/main/java/com/ard/route/util/ToolUtils.java
+++ b/ard-route/src/main/java/com/ard/route/util/ToolUtils.java
@@ -1,7 +1,6 @@
package com.ard.route.util;
import com.ard.route.domain.djuav.UavRouteReq;
-
import java.io.*;
import java.time.LocalDateTime;
import java.time.format.DateTimeFormatter;
@@ -86,6 +85,9 @@
// 对象序列化为字节数组
public static byte[] serialize(Object obj) throws IOException {
+ if (obj == null) {
+ return null;
+ }
try (ByteArrayOutputStream baos = new ByteArrayOutputStream();
ObjectOutputStream oos = new ObjectOutputStream(baos)) {
oos.writeObject(obj);
--
Gitblit v1.9.3