Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
eshiled-new
/
ne-shield-trialdrive-admin
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit 4828effe
authored
Jan 02, 2022
by
levphon
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
工单详情-导入
1 parent
6f36472d
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
13 additions
and
0 deletions
src/main/java/cn/com/glsx/admin/modules/model/imports/WorkOrderImportListener.java
src/main/java/cn/com/glsx/admin/modules/model/imports/WorkOrderImportListener.java
View file @
4828eff
...
...
@@ -22,6 +22,10 @@ import org.apache.commons.collections.CollectionUtils;
import
java.io.ByteArrayOutputStream
;
import
java.lang.reflect.Field
;
import
java.time.Duration
;
import
java.time.Instant
;
import
java.time.ZoneId
;
import
java.time.ZonedDateTime
;
import
java.util.ArrayList
;
import
java.util.List
;
import
java.util.Map
;
...
...
@@ -147,6 +151,15 @@ public class WorkOrderImportListener extends AnalysisEventListener<WorkOrderImpo
return
false
;
}
}
ZonedDateTime
nowTime
=
ZonedDateTime
.
now
();
ZonedDateTime
dateTime
=
ZonedDateTime
.
ofInstant
(
Instant
.
ofEpochMilli
(
woi
.
getServiceTime
().
toInstant
().
toEpochMilli
()),
ZoneId
.
systemDefault
());
Duration
duration
=
Duration
.
between
(
nowTime
,
dateTime
).
abs
();
if
(
duration
.
toDays
()
<
0
)
{
woi
.
setImportFailReason
(
"期望安装日期不能小于当前日期"
);
log
.
warn
(
woi
.
toString
());
return
false
;
}
//检查未完成工单
WorkOrder
workOrder
=
workOrderService
.
getIncompleteWorkOrder
(
BizServiceTypeEnum
.
INSTALL
.
getType
(),
woi
.
getVin
());
...
...
Write
Preview
Markdown
is supported
Attach a file
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 post a comment