Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
jinli gu
JSH ERP
Commits
c004f872
Commit
c004f872
authored
Aug 22, 2021
by
季圣华
Browse files
优化调拨出库单据的仓库判断
parent
47b5d2d8
Changes
2
Hide whitespace changes
Inline
Side-by-side
jshERP-boot/src/main/java/com/jsh/erp/constants/ExceptionConstants.java
View file @
c004f872
...
...
@@ -324,6 +324,9 @@ public class ExceptionConstants {
//单据录入-退货单不能欠款
public
static
final
int
DEPOT_HEAD_BACK_BILL_DEBT_FAILED_CODE
=
8500009
;
public
static
final
String
DEPOT_HEAD_BACK_BILL_DEBT_FAILED_MSG
=
"退货单不能欠款"
;
//单据录入-调入仓库与原仓库不能重复
public
static
final
int
DEPOT_HEAD_ANOTHER_DEPOT_EQUAL_FAILED_CODE
=
8500010
;
public
static
final
String
DEPOT_HEAD_ANOTHER_DEPOT_EQUAL_FAILED_MSG
=
"调入仓库与原仓库不能重复"
;
/**
* 单据明细信息
* type = 90
...
...
jshERP-boot/src/main/java/com/jsh/erp/service/depotItem/DepotItemService.java
View file @
c004f872
...
...
@@ -368,7 +368,12 @@ public class DepotItemService {
}
if
(
BusinessConstants
.
SUB_TYPE_TRANSFER
.
equals
(
depotHead
.
getSubType
()))
{
if
(
StringUtil
.
isExist
(
rowObj
.
get
(
"anotherDepotId"
)))
{
depotItem
.
setAnotherDepotId
(
rowObj
.
getLong
(
"anotherDepotId"
));
if
(
rowObj
.
getLong
(
"anotherDepotId"
).
equals
(
rowObj
.
getLong
(
"depotId"
)))
{
throw
new
BusinessRunTimeException
(
ExceptionConstants
.
DEPOT_HEAD_ANOTHER_DEPOT_EQUAL_FAILED_CODE
,
String
.
format
(
ExceptionConstants
.
DEPOT_HEAD_ANOTHER_DEPOT_EQUAL_FAILED_MSG
));
}
else
{
depotItem
.
setAnotherDepotId
(
rowObj
.
getLong
(
"anotherDepotId"
));
}
}
else
{
throw
new
BusinessRunTimeException
(
ExceptionConstants
.
DEPOT_HEAD_ANOTHER_DEPOT_FAILED_CODE
,
String
.
format
(
ExceptionConstants
.
DEPOT_HEAD_ANOTHER_DEPOT_FAILED_MSG
));
...
...
Write
Preview
Supports
Markdown
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