Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
王蔡翾
operation_platform
Commits
43f0dd0a
Commit
43f0dd0a
authored
Apr 03, 2025
by
zhuxiang
Browse files
联调优化
parent
6335b95e
Changes
5
Show whitespace changes
Inline
Side-by-side
src/main/java/com/example/operation_platform/model/vo/OperationJobVO.java
View file @
43f0dd0a
package
com.example.operation_platform.model.vo
;
package
com.example.operation_platform.model.vo
;
import
com.example.operation_platform.model.entity.OperationJob
;
import
com.example.operation_platform.model.entity.OperationJob
;
import
com.fasterxml.jackson.annotation.JsonInclude
;
import
com.fasterxml.jackson.annotation.JsonInclude
;
import
lombok.Data
;
import
lombok.Data
;
...
@@ -11,6 +12,7 @@ import java.time.LocalDate;
...
@@ -11,6 +12,7 @@ import java.time.LocalDate;
public
class
OperationJobVO
extends
OperationJob
{
public
class
OperationJobVO
extends
OperationJob
{
private
String
robotName
;
private
String
robotName
;
private
String
stationName
;
private
String
stationName
;
private
String
address
;
private
String
operationType
;
private
String
operationType
;
private
String
workerName
;
private
String
workerName
;
private
Integer
id
;
private
Integer
id
;
...
...
src/main/java/com/example/operation_platform/model/vo/PeopleMessageVO.java
View file @
43f0dd0a
...
@@ -15,6 +15,7 @@ public class PeopleMessageVO {
...
@@ -15,6 +15,7 @@ public class PeopleMessageVO {
private
Long
operationNumber
;
private
Long
operationNumber
;
private
Integer
id
;
private
Integer
id
;
private
String
stationName
;
private
String
stationName
;
private
String
address
;
private
String
robotName
;
private
String
robotName
;
private
String
lon
;
private
String
lon
;
...
...
src/main/java/com/example/operation_platform/util/AliOSSUtils.java
View file @
43f0dd0a
...
@@ -34,8 +34,12 @@ public class AliOSSUtils {
...
@@ -34,8 +34,12 @@ public class AliOSSUtils {
// 避免文件覆盖
// 避免文件覆盖
String
originalFilename
=
multipartFile
.
getOriginalFilename
();
String
originalFilename
=
multipartFile
.
getOriginalFilename
();
String
fileName
=
dir
+
UUID
.
randomUUID
().
toString
()
+
originalFilename
.
substring
(
originalFilename
.
lastIndexOf
(
"."
));
String
fileName
;
try
{
fileName
=
dir
+
UUID
.
randomUUID
()
+
originalFilename
.
substring
(
originalFilename
.
lastIndexOf
(
"."
));
}
catch
(
StringIndexOutOfBoundsException
e
){
fileName
=
UUID
.
randomUUID
()
+
originalFilename
;
}
//上传文件到 OSS
//上传文件到 OSS
OSS
ossClient
=
new
OSSClientBuilder
().
build
(
endpoint
,
accessKeyId
,
accessKeySecret
);
OSS
ossClient
=
new
OSSClientBuilder
().
build
(
endpoint
,
accessKeyId
,
accessKeySecret
);
ossClient
.
putObject
(
bucketName
,
fileName
,
inputStream
);
ossClient
.
putObject
(
bucketName
,
fileName
,
inputStream
);
...
...
src/main/resources/mapper/MessageMapper.xml
View file @
43f0dd0a
...
@@ -81,6 +81,7 @@
...
@@ -81,6 +81,7 @@
SELECT
SELECT
tm.id id,
tm.id id,
tor.name stationName,
tor.name stationName,
tor.address,
COALESCE(br.name, dr.name) robotName,
COALESCE(br.name, dr.name) robotName,
tor.contact_phone phoneNumber,
tor.contact_phone phoneNumber,
tp.worker_name softwareWorker,
tp.worker_name softwareWorker,
...
...
src/main/resources/mapper/OperationJobMapper.xml
View file @
43f0dd0a
...
@@ -173,6 +173,7 @@
...
@@ -173,6 +173,7 @@
<select
id=
"queryRunLogJobList"
resultType=
"com.example.operation_platform.model.vo.OperationJobVO"
>
<select
id=
"queryRunLogJobList"
resultType=
"com.example.operation_platform.model.vo.OperationJobVO"
>
SELECT
SELECT
top.id,
top.id,
top.operation_id operationId,
tp.operation_type AS operationType,
tp.operation_type AS operationType,
bs.name AS stationName,
bs.name AS stationName,
-- 合并 robot 和 drone 的 name 到 robotName(优先取 robot)
-- 合并 robot 和 drone 的 name 到 robotName(优先取 robot)
...
@@ -190,7 +191,8 @@
...
@@ -190,7 +191,8 @@
tp.tb_run_log_id AS runLogId,
tp.tb_run_log_id AS runLogId,
tp.station_id AS stationId,
tp.station_id AS stationId,
bs.lon lon,
bs.lon lon,
bs.lat lat
bs.lat lat,
bs.address
-- 保留操作人员名称
-- 保留操作人员名称
FROM
FROM
tb_operation_job top
tb_operation_job top
...
@@ -308,8 +310,10 @@
...
@@ -308,8 +310,10 @@
<select
id=
"queryJobAndOperationTypeList"
resultType=
"com.example.operation_platform.model.vo.OperationJobVO"
>
<select
id=
"queryJobAndOperationTypeList"
resultType=
"com.example.operation_platform.model.vo.OperationJobVO"
>
SELECT
SELECT
top.id,
top.id,
top.operation_id operationId,
tp.operation_type AS operationType,
tp.operation_type AS operationType,
bs.name AS stationName,
bs.name AS stationName,
bs.address address,
bs.lon,
bs.lon,
bs.lat,
bs.lat,
-- 合并 robot 和 drone 的 name 到 robotName(优先取 robot)
-- 合并 robot 和 drone 的 name 到 robotName(优先取 robot)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment