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
8e3005c1
Commit
8e3005c1
authored
Jul 05, 2021
by
wangweidong
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
hmhj增加原始记录样品信息
parent
e0c67824
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
14 additions
and
3 deletions
+14
-3
EntrustSampleItemServiceImpl.java
.../lims/hmhj/service/impl/EntrustSampleItemServiceImpl.java
+14
-3
No files found.
src/main/java/com/patzn/cloud/service/lims/hmhj/service/impl/EntrustSampleItemServiceImpl.java
View file @
8e3005c1
...
...
@@ -366,12 +366,20 @@ public class EntrustSampleItemServiceImpl extends BaseServiceImpl<EntrustSampleI
e
.
printStackTrace
();
}
Map
<
String
,
String
>
mapReplace
=
new
HashMap
<>();
mapReplace
.
put
(
"#{nowDate}"
,
DateUtils
.
toYearMonthDay
(
new
Date
()));
mapReplace
.
put
(
"#{sampleNum}"
,
entrustSampleService
.
countByEntrustId
(
entrust
.
getId
())+
""
);
if
(
null
!=
template
.
getMoreItem
()
&&
1
==
template
.
getMoreItem
())
{
Set
<
Long
>
sampleIdsList
=
new
HashSet
<>();
for
(
EntrustSampleItemVO
itemVO
:
voList
)
{
sampleIdsList
.
add
(
itemVO
.
getEntrustSampleId
());
}
List
<
EntrustSample
>
sampleList
=
entrustSampleService
.
list
(
Condition
.
create
().
in
(
"id"
,
sampleIdsList
));
if
(
CollectionUtils
.
isNotEmpty
(
sampleList
)){
mapReplace
.
put
(
"#{sampleFrom}"
,
sampleList
.
get
(
0
).
getSampleFrom
());
mapReplace
.
put
(
"#{sampleName}"
,
sampleList
.
get
(
0
).
getName
());
}
List
<
EntrustSampleVO
>
sampleVOList
=
new
ArrayList
<>(
sampleList
.
size
());
for
(
EntrustSample
sample
:
sampleList
)
{
...
...
@@ -394,6 +402,12 @@ public class EntrustSampleItemServiceImpl extends BaseServiceImpl<EntrustSampleI
}
else
{
if
(
CollectionUtils
.
isNotEmpty
(
voList
)){
mapReplace
.
put
(
"#{sampleFrom}"
,
voList
.
get
(
0
).
getSampleFrom
());
mapReplace
.
put
(
"#{sampleName}"
,
voList
.
get
(
0
).
getSampleName
());
}
OriginalFactory
factory
=
new
OriginalFactory
(
template
,
voList
,
entrust
,
configList
,
xssfWorkbook
);
Operation
operation
=
factory
.
getOperation
();
if
(
null
!=
operation
)
{
...
...
@@ -403,9 +417,6 @@ public class EntrustSampleItemServiceImpl extends BaseServiceImpl<EntrustSampleI
Map
<
String
,
String
>
mapReplace
=
new
HashMap
<>();
mapReplace
.
put
(
"#{nowDate}"
,
DateUtils
.
toYearMonthDay
(
new
Date
()));
mapReplace
.
put
(
"#{sampleNum}"
,
entrustSampleService
.
countByEntrustId
(
entrust
.
getId
())+
""
);
HSSFWorkbookUtil
.
replaceModel
(
mapReplace
,
xssfWorkbook
,
0
);
FileOutputStream
os
=
null
;
...
...
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