Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
huang.tao
/
jmai-platform
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
fcd3258d
authored
Jan 20, 2026
by
zhu.zewen
Browse files
Options
_('Browse Files')
Download
Email Patches
Plain Diff
修复交接班状态过滤
parent
3445cc84
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
2 deletions
jmai-physic/src/main/java/com/jmai/physic/service/impl/PhysicBillServiceImpl.java
jmai-physic/src/main/java/com/jmai/physic/service/impl/PhysicBillServiceImpl.java
View file @
fcd3258d
...
@@ -191,6 +191,8 @@ public class PhysicBillServiceImpl extends AbstractService implements PhysicBill
...
@@ -191,6 +191,8 @@ public class PhysicBillServiceImpl extends AbstractService implements PhysicBill
private
Optional
<
PhysicBillHandover
>
getLastHandover
(
Long
deptId
)
{
private
Optional
<
PhysicBillHandover
>
getLastHandover
(
Long
deptId
)
{
PhysicBillHandover
lastHandover
=
physicBillHandoverMapper
.
selectOne
(
Wrappers
.
lambdaQuery
(
PhysicBillHandover
.
class
)
PhysicBillHandover
lastHandover
=
physicBillHandoverMapper
.
selectOne
(
Wrappers
.
lambdaQuery
(
PhysicBillHandover
.
class
)
.
eq
(
PhysicBillHandover:
:
getDeptId
,
deptId
)
.
eq
(
PhysicBillHandover:
:
getDeptId
,
deptId
)
// 未取消
.
ge
(
PhysicBillHandover:
:
getStatus
,
0
)
.
orderByDesc
(
PhysicBillHandover:
:
getId
)
.
orderByDesc
(
PhysicBillHandover:
:
getId
)
.
last
(
" LIMIT 1 "
));
.
last
(
" LIMIT 1 "
));
if
(
ObjectUtil
.
isEmpty
(
lastHandover
))
{
if
(
ObjectUtil
.
isEmpty
(
lastHandover
))
{
...
@@ -210,6 +212,8 @@ public class PhysicBillServiceImpl extends AbstractService implements PhysicBill
...
@@ -210,6 +212,8 @@ public class PhysicBillServiceImpl extends AbstractService implements PhysicBill
// 获取最新的交接单
// 获取最新的交接单
PhysicBillHandover
lastHandover
=
physicBillHandoverMapper
.
selectOne
(
Wrappers
.
lambdaQuery
(
PhysicBillHandover
.
class
)
PhysicBillHandover
lastHandover
=
physicBillHandoverMapper
.
selectOne
(
Wrappers
.
lambdaQuery
(
PhysicBillHandover
.
class
)
.
eq
(
PhysicBillHandover:
:
getDeptId
,
deptId
)
.
eq
(
PhysicBillHandover:
:
getDeptId
,
deptId
)
// 未取消
.
ge
(
PhysicBillHandover:
:
getStatus
,
0
)
.
orderByDesc
(
PhysicBillHandover:
:
getId
));
.
orderByDesc
(
PhysicBillHandover:
:
getId
));
if
(
ObjectUtil
.
isEmpty
(
lastHandover
))
{
if
(
ObjectUtil
.
isEmpty
(
lastHandover
))
{
return
Collections
.
emptyList
();
return
Collections
.
emptyList
();
...
@@ -235,8 +239,10 @@ public class PhysicBillServiceImpl extends AbstractService implements PhysicBill
...
@@ -235,8 +239,10 @@ public class PhysicBillServiceImpl extends AbstractService implements PhysicBill
// 验证是否存在未完成的交接单
// 验证是否存在未完成的交接单
PhysicBillHandover
unfinishedHandover
=
physicBillHandoverMapper
.
selectOne
(
Wrappers
.
lambdaQuery
(
PhysicBillHandover
.
class
)
PhysicBillHandover
unfinishedHandover
=
physicBillHandoverMapper
.
selectOne
(
Wrappers
.
lambdaQuery
(
PhysicBillHandover
.
class
)
.
eq
(
PhysicBillHandover:
:
getDeptId
,
deptId
)
.
eq
(
PhysicBillHandover:
:
getDeptId
,
deptId
)
.
ne
(
PhysicBillHandover:
:
getStatus
,
100
)
// 未完成
.
ne
(
PhysicBillHandover:
:
getStatus
,
-
100
)
.
lt
(
PhysicBillHandover:
:
getStatus
,
100
)
// 未取消
.
ge
(
PhysicBillHandover:
:
getStatus
,
0
)
.
orderByDesc
(
PhysicBillHandover:
:
getId
));
.
orderByDesc
(
PhysicBillHandover:
:
getId
));
if
(
ObjectUtil
.
isNotEmpty
(
unfinishedHandover
))
{
if
(
ObjectUtil
.
isNotEmpty
(
unfinishedHandover
))
{
throw
new
ServiceException
(
"存在未完成交接单"
);
throw
new
ServiceException
(
"存在未完成交接单"
);
...
...
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