Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
P
patzn-cloud-service-hmhj
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wangweidong
patzn-cloud-service-hmhj
Commits
8ad2988f
Commit
8ad2988f
authored
Nov 26, 2024
by
jiangxuming
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
处理编号顺序与orderBy顺序不一致的问题
parent
403de2a5
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
0 deletions
+3
-0
EntrustServiceImpl.java
...ud/service/lims/hmhj/service/impl/EntrustServiceImpl.java
+3
-0
No files found.
src/main/java/com/patzn/cloud/service/lims/hmhj/service/impl/EntrustServiceImpl.java
View file @
8ad2988f
...
@@ -1705,6 +1705,7 @@ public class EntrustServiceImpl extends BaseServiceImpl<EntrustMapper, Entrust>
...
@@ -1705,6 +1705,7 @@ public class EntrustServiceImpl extends BaseServiceImpl<EntrustMapper, Entrust>
List
<
EntrustSample
>
sampleList
=
entrustSampleService
.
getByEntrustId
(
entrust
.
getId
());
List
<
EntrustSample
>
sampleList
=
entrustSampleService
.
getByEntrustId
(
entrust
.
getId
());
RestAssert
.
fail
(
CollectionUtils
.
isEmpty
(
sampleList
),
String
.
format
(
"委托编号为的【%s】样品为空!"
,
entrust
.
getCode
()));
RestAssert
.
fail
(
CollectionUtils
.
isEmpty
(
sampleList
),
String
.
format
(
"委托编号为的【%s】样品为空!"
,
entrust
.
getCode
()));
// 若存在任何一个样品的编号为空,那么需要自动生成其编号
// 若存在任何一个样品的编号为空,那么需要自动生成其编号
int
incNum
=
10
;
for
(
EntrustSample
sample
:
sampleList
)
{
for
(
EntrustSample
sample
:
sampleList
)
{
sampleSlotNoHandler
(
sample
);
sampleSlotNoHandler
(
sample
);
if
(
StringUtils
.
isBlank
(
sample
.
getCode
())
||
Objects
.
nonNull
(
sample
.
getSamplingId
()))
{
if
(
StringUtils
.
isBlank
(
sample
.
getCode
())
||
Objects
.
nonNull
(
sample
.
getSamplingId
()))
{
...
@@ -1714,6 +1715,8 @@ public class EntrustServiceImpl extends BaseServiceImpl<EntrustMapper, Entrust>
...
@@ -1714,6 +1715,8 @@ public class EntrustServiceImpl extends BaseServiceImpl<EntrustMapper, Entrust>
sampleCodeHandler
(
sample
);
sampleCodeHandler
(
sample
);
// 处理重取原编号
// 处理重取原编号
retakeSourceCodeHandle
(
sample
);
retakeSourceCodeHandle
(
sample
);
sample
.
setOrderBy
(
incNum
);
incNum
+=
10
;
RestAssert
.
fail
(
entrustSampleService
.
isRepeatSampleCode
(
sample
),
String
.
format
(
"样品编号【%s】重复!"
,
sample
.
getCode
()));
RestAssert
.
fail
(
entrustSampleService
.
isRepeatSampleCode
(
sample
),
String
.
format
(
"样品编号【%s】重复!"
,
sample
.
getCode
()));
}
}
entrustSampleService
.
updateBatchById
(
sampleList
);
entrustSampleService
.
updateBatchById
(
sampleList
);
...
...
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