Skip to content
切换导航条
切换导航条
当前项目
正在载入...
登录
孙克
/
smf-core
转到一个项目
切换导航栏
切换导航栏固定状态
项目
群组
代码片段
帮助
项目
活动
版本库
流水线
图表
问题
0
合并请求
0
维基
网络
创建新的问题
作业
提交
问题看板
文件
提交
网络
比较
分支
标签
Commit a15294d5
由
张少辉
编写于
2026-05-14 13:43:56 +0800
浏览文件
选项
浏览文件
标签
下载
电子邮件补丁
差异文件
1.每20箱子自动抛送
1 个父辈
cbbe4c92
隐藏空白字符变更
内嵌
并排
正在显示
1 个修改的文件
包含
10 行增加
和
12 行删除
src/main/java/com/neotel/smfcore/custom/luxsan/factory_c/wipstor/controller/AutoDispatchInventoryController.java
src/main/java/com/neotel/smfcore/custom/luxsan/factory_c/wipstor/controller/AutoDispatchInventoryController.java
查看文件 @
a15294d
...
...
@@ -124,7 +124,7 @@ public class AutoDispatchInventoryController {
AutoStoRequest
autoStoRequest
=
new
AutoStoRequest
();
List
<
StoragePos
>
autoStoPosList
=
new
ArrayList
<>();
while
(
needNum
<
checkOutNum
&&
count
<
20
)
{
while
(
count
<
20
)
{
StoragePos
pos
=
storagePosManager
.
findPartNumberInStorages
(
storageIdList
,
partNumber
,
excludeOutPosIds
,
checkOutType
);
if
(
pos
==
null
)
{
log
.
info
(
"【自动出库】料号{}未找到可用库位,退出分配"
,
partNumber
);
...
...
@@ -168,21 +168,18 @@ public class AutoDispatchInventoryController {
autoStoRequest
.
setWarehouse_code
(
barcode
.
getWarehouseCode
());
autoStoRequest
.
setModel
(
barcode
.
getModelFamily
());
//同时更新barcode信息
barcode
.
setCurrentRequestId
(
autoStoRequest
.
getKey_id
());
barcodeManager
.
save
(
barcode
);
pos
.
setBarcode
(
barcode
);
storagePosManager
.
save
(
pos
);
autoStoPosList
.
add
(
pos
);
log
.
info
(
"【自动出库】锁定库位{},条码数量:{},累计已选数量:{}"
,
pos
.
getId
(),
barcode
.
getAmount
(),
autoStoRequest
.
getQty
());
autoStoPosList
.
add
(
pos
);
excludeOutPosIds
.
add
(
pos
.
getId
());
//更新信息
needNum
=
needNum
+
barcode
.
getAmount
();
count
++;
}
if
(
count
<
20
)
{
continue
;
}
int
qty
=
autoStoRequest
.
getQty
();
if
(
qty
<=
0
)
{
log
.
warn
(
"【自动出库】料号{}未选中任何库存,跳过接口调用"
,
partNumber
);
...
...
@@ -200,7 +197,7 @@ public class AutoDispatchInventoryController {
for
(
StoragePos
pos
:
autoStoPosList
)
{
Barcode
barcode
=
pos
.
getBarcode
();
if
(
barcode
!=
null
)
{
if
(
autoStoRequest
.
getKey_id
().
equals
(
barcode
.
getCurrentRequestId
()))
{
//
if (autoStoRequest.getKey_id().equals(barcode.getCurrentRequestId())) {
barcode
.
setCurrentRequestId
(
""
);
barcode
.
setOdn
(
""
);
barcode
.
setMemo
(
autoStoResult
.
getMSGTX
());
...
...
@@ -209,7 +206,7 @@ public class AutoDispatchInventoryController {
pos
.
setBarcode
(
barcode
);
storagePosManager
.
save
(
pos
);
log
.
info
(
"【自动出库】回滚库位{}完成"
,
pos
.
getId
());
}
//
}
}
}
log
.
error
(
"【自动出库】料号{}接口失败,全部回滚完成"
,
partNumber
);
...
...
@@ -220,14 +217,15 @@ public class AutoDispatchInventoryController {
for
(
StoragePos
pos
:
autoStoPosList
)
{
Barcode
barcode
=
pos
.
getBarcode
();
if
(
barcode
!=
null
)
{
if
(
autoStoRequest
.
getKey_id
().
equals
(
barcode
.
getCurrentRequestId
()))
{
//if (autoStoRequest.getKey_id().equals(barcode.getCurrentRequestId())) {
barcode
.
setCurrentRequestId
(
autoStoRequest
.
getKey_id
());
barcode
.
setOdn
(
data
);
barcode
.
setSto
(
autoStoResult
.
getDETAIL
());
barcodeManager
.
save
(
barcode
);
pos
.
setBarcode
(
barcode
);
storagePosManager
.
save
(
pos
);
log
.
info
(
"【自动出库】更新库位{} ODN:{} 成功"
,
pos
.
getId
(),
data
);
}
//
}
}
}
log
.
info
(
"【自动出库】料号{}所有库位更新完成"
,
partNumber
);
...
...
编写
预览
支持
Markdown
格式
附加文件
你添加了
0
人
到此讨论。请谨慎行事。
Finish editing this message first!
Cancel
请
注册
或
登录
后发表评论