Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
M
manager
Project
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
reyun
manager
Commits
601bacca
Commit
601bacca
authored
Jul 21, 2021
by
lzxry
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
bugfix
parent
c120c07a
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
15 additions
and
1 deletion
+15
-1
ContractRepository.java
src/main/java/common/repository/ContractRepository.java
+3
-0
ShareIncomeServiceImpl.java
...main/java/common/service/impl/ShareIncomeServiceImpl.java
+12
-1
No files found.
src/main/java/common/repository/ContractRepository.java
View file @
601bacca
...
...
@@ -147,4 +147,7 @@ public interface ContractRepository extends JpaRepository<Contract, Long> {
@Query
(
value
=
"select * from contract where contract_code = ?1 and status != 'del'"
,
nativeQuery
=
true
)
Contract
findByCodeAndNotDel
(
String
contractCode
);
@Query
(
value
=
"select * from contract where relation_code = ?1 and status != 'del'"
,
nativeQuery
=
true
)
List
<
Contract
>
findByRelationCode
(
String
contractCode
);
}
src/main/java/common/service/impl/ShareIncomeServiceImpl.java
View file @
601bacca
...
...
@@ -535,10 +535,21 @@ public class ShareIncomeServiceImpl implements ShareIncomeService {
//if(contract==null){
List
<
Contract
>
contractList
=
contractRepository
.
findByCreateTimeAndCodeNotOwn
(
groupContract
.
getRelationCode
(),
DateUtil
.
format
(
groupContract
.
getCreateTime
(),
DateUtil
.
C_TIME_PATTON_DEFAULT
),
groupContract
.
getId
());
for
(
Contract
contract1
:
contractList
)
{
map
.
put
(
contract1
.
getContractCode
(),
contract1
);
if
(
StringUtils
.
isEmpty
(
map
.
get
(
contract1
.
getContractCode
()))){
map
.
put
(
contract1
.
getContractCode
(),
contract1
);
}
}
groupContracts
=
map
.
values
();
//只要不加入传进来的那个list里面就不会影响查询的列表
break
;
}
else
if
((
groupContracts
.
size
()==
1
&&!
StringUtils
.
isEmpty
(
groupContract
.
getNextSignedDate
()))||(!
"2"
.
equals
(
groupContract
.
getContractType
())
&&
map
.
get
(
groupContract
.
getNextSignedContractCode
())==
null
)){
List
<
Contract
>
contractList
=
contractRepository
.
findByRelationCode
(
groupContract
.
getContractCode
());
for
(
Contract
contract1
:
contractList
)
{
if
(
StringUtils
.
isEmpty
(
map
.
get
(
contract1
.
getContractCode
()))){
map
.
put
(
contract1
.
getContractCode
(),
contract1
);
}
}
groupContracts
=
map
.
values
();
break
;
}
}
...
...
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