Skip to content
切换导航条
切换导航条
当前项目
正在载入...
登录
孙克
/
smf-core
转到一个项目
切换导航栏
切换导航栏固定状态
项目
群组
代码片段
帮助
项目
活动
版本库
流水线
图表
问题
0
合并请求
0
维基
网络
创建新的问题
作业
提交
问题看板
文件
提交
网络
比较
分支
标签
Commit 9eedf462
由
LN
编写于
2024-03-06 15:30:32 +0800
浏览文件
选项
浏览文件
标签
下载
电子邮件补丁
差异文件
扫码亮灯修改
1 个父辈
b7df5340
隐藏空白字符变更
内嵌
并排
正在显示
2 个修改的文件
包含
10 行增加
和
3 行删除
src/main/java/com/neotel/smfcore/core/shelf/util/TaskShelfUtil.java
src/main/java/com/neotel/smfcore/custom/gree20242/CodeLightController.java
src/main/java/com/neotel/smfcore/core/shelf/util/TaskShelfUtil.java
查看文件 @
9eedf46
...
@@ -54,6 +54,11 @@ public class TaskShelfUtil {
...
@@ -54,6 +54,11 @@ public class TaskShelfUtil {
}
}
public
static
String
getCid
(
String
loc
){
public
static
String
getCid
(
String
loc
){
String
[]
array
=
loc
.
split
(
"-"
);
if
(
array
.
length
>
0
){
return
array
[
0
];
}
return
loc
;
return
loc
;
}
}
...
@@ -604,7 +609,7 @@ public class TaskShelfUtil {
...
@@ -604,7 +609,7 @@ public class TaskShelfUtil {
String
cid
=
getCid
(
shelfLoc
);
String
cid
=
getCid
(
shelfLoc
);
Storage
storage
=
dataCache
.
getStorage
(
cid
);
Storage
storage
=
dataCache
.
getStorage
(
cid
);
if
(
storage
==
null
)
{
if
(
storage
==
null
)
{
log
.
error
(
"OpenShelfLed 料架
"
+
shelfInfo
.
getRealRfid
()
+
" , 位置:"
+
shelfLoc
+
",cid "
+
cid
+
"
未找到对应的亮灯料架"
);
log
.
error
(
"OpenShelfLed 料架
["
+
shelfInfo
.
getRealRfid
()
+
"] , 位置:["
+
shelfLoc
+
"],cid ["
+
cid
+
" ]
未找到对应的亮灯料架"
);
return
false
;
return
false
;
}
}
for
(
ShelfLoc
loc
:
locs
for
(
ShelfLoc
loc
:
locs
...
@@ -616,8 +621,8 @@ public class TaskShelfUtil {
...
@@ -616,8 +621,8 @@ public class TaskShelfUtil {
if
(
loc
.
isReelLeave
())
{
if
(
loc
.
isReelLeave
())
{
continue
;
continue
;
}
else
{
}
else
{
DevicesStatusUtil
.
appendOp
(
storage
.
getCid
(),
"open"
,
posname
+
"="
+
Color
.
GREEN
.
toString
()
);
DevicesStatusUtil
.
appendOp
(
storage
.
getCid
(),
"open"
,
posname
+
"="
+
"green"
);
log
.
info
(
"亮灯料架CID:
"
+
storage
.
getCid
()
+
",料架RFID:"
+
shelfInfo
.
getRealRfid
()
+
" ,库位: "
+
posname
+
" 亮灯 :"
+
Color
.
GREEN
.
toString
()
);
log
.
info
(
"亮灯料架CID:
["
+
storage
.
getCid
()
+
"],料架RFID:["
+
shelfInfo
.
getRealRfid
()
+
"] ,库位: ["
+
posname
+
"=green]"
);
}
}
}
}
return
true
;
return
true
;
...
...
src/main/java/com/neotel/smfcore/custom/gree20242/CodeLightController.java
查看文件 @
9eedf46
...
@@ -216,11 +216,13 @@ public class CodeLightController {
...
@@ -216,11 +216,13 @@ public class CodeLightController {
Storage
storage
=
dataCache
.
getStorage
(
cid
);
Storage
storage
=
dataCache
.
getStorage
(
cid
);
if
(
storage
==
null
)
{
if
(
storage
==
null
)
{
log
.
error
(
"lightOff code["
+
code
+
"],shelfLoc["
+
shelfLoc
+
"],cid["
+
cid
+
"],posName["
+
posname
+
"]未找到料架"
);
return
ResultBean
.
newErrorResult
(
99
,
"smfcore.light.error.noStorage"
,
"未找到料架["
+
cid
+
"]"
,
new
String
[]{
cid
});
return
ResultBean
.
newErrorResult
(
99
,
"smfcore.light.error.noStorage"
,
"未找到料架["
+
cid
+
"]"
,
new
String
[]{
cid
});
}
}
StoragePos
pos
=
storagePosManager
.
getByPosName
(
posname
);
StoragePos
pos
=
storagePosManager
.
getByPosName
(
posname
);
if
(
pos
==
null
)
{
if
(
pos
==
null
)
{
log
.
error
(
"lightOff code["
+
code
+
"],shelfLoc["
+
shelfLoc
+
"],cid["
+
cid
+
"],posName["
+
posname
+
"]未找到库位"
);
return
ResultBean
.
newErrorResult
(
99
,
"smfcore.light.error.noStoragePos"
,
"未找到料架库位["
+
posname
+
"]"
,
new
String
[]{
posname
});
return
ResultBean
.
newErrorResult
(
99
,
"smfcore.light.error.noStoragePos"
,
"未找到料架库位["
+
posname
+
"]"
,
new
String
[]{
posname
});
}
}
...
...
编写
预览
支持
Markdown
格式
附加文件
你添加了
0
人
到此讨论。请谨慎行事。
Finish editing this message first!
Cancel
请
注册
或
登录
后发表评论