Skip to content
切换导航条
切换导航条
当前项目
正在载入...
登录
孙克
/
smf-core
转到一个项目
切换导航栏
切换导航栏固定状态
项目
群组
代码片段
帮助
项目
活动
版本库
流水线
图表
问题
0
合并请求
0
维基
网络
创建新的问题
作业
提交
问题看板
文件
提交
网络
比较
分支
标签
Commit 70fa8428
由
zshaohui
编写于
2023-12-11 09:33:30 +0800
浏览文件
选项
浏览文件
标签
下载
电子邮件补丁
差异文件
1.发送email修改
2.物料已过期 提示修改
1 个父辈
18ca3b71
隐藏空白字符变更
内嵌
并排
正在显示
4 个修改的文件
包含
8 行增加
和
7 行删除
src/main/java/com/neotel/smfcore/custom/micron20031/MicronSpApiListener.java
src/main/java/com/neotel/smfcore/custom/micron20031/manager/MicronSpTimerProcess.java
src/main/resources/config/application.yml
src/main/resources/messages_en_US.properties
src/main/java/com/neotel/smfcore/custom/micron20031/MicronSpApiListener.java
查看文件 @
70fa842
...
@@ -72,7 +72,7 @@ public class MicronSpApiListener extends BaseSmfApiListener {
...
@@ -72,7 +72,7 @@ public class MicronSpApiListener extends BaseSmfApiListener {
Date
expireDate
=
barcode
.
getExpireDate
();
Date
expireDate
=
barcode
.
getExpireDate
();
if
(
expireDate
!=
null
)
{
if
(
expireDate
!=
null
)
{
if
(
System
.
currentTimeMillis
()
>
expireDate
.
getTime
())
{
if
(
System
.
currentTimeMillis
()
>
expireDate
.
getTime
())
{
throw
new
ValidateException
(
"smfcore.error.barcode.expired"
,
"
Ree
l expired, storage failed"
);
throw
new
ValidateException
(
"smfcore.error.barcode.expired"
,
"
Materia
l expired, storage failed"
);
}
}
}
}
...
...
src/main/java/com/neotel/smfcore/custom/micron20031/manager/MicronSpTimerProcess.java
查看文件 @
70fa842
...
@@ -71,7 +71,7 @@ public class MicronSpTimerProcess {
...
@@ -71,7 +71,7 @@ public class MicronSpTimerProcess {
//当前开始的入库单,如果超过一小时还未完成,发送邮件
//当前开始的入库单,如果超过一小时还未完成,发送邮件
try
{
try
{
Integer
depositExceedTime
=
dataCache
.
getCache
(
Constants
.
CACHE_Deposit_Exceed_Time
);
Integer
depositExceedTime
=
dataCache
.
getCache
(
Constants
.
CACHE_Deposit_Exceed_Time
);
if
(
depositExceedTime
==
null
){
if
(
depositExceedTime
==
null
)
{
depositExceedTime
=
1
;
depositExceedTime
=
1
;
}
}
long
timeOutTime
=
60
*
60
*
1000
*
depositExceedTime
;
long
timeOutTime
=
60
*
60
*
1000
*
depositExceedTime
;
...
@@ -83,13 +83,14 @@ public class MicronSpTimerProcess {
...
@@ -83,13 +83,14 @@ public class MicronSpTimerProcess {
if
(
inList
.
getStartTime
()
>
0
&&
(
inList
.
getStatus
()
!=
INLIST_STATUS
.
OK
)
&&
(
inList
.
isSendEmail
()
==
false
))
{
if
(
inList
.
getStartTime
()
>
0
&&
(
inList
.
getStatus
()
!=
INLIST_STATUS
.
OK
)
&&
(
inList
.
isSendEmail
()
==
false
))
{
if
(
System
.
currentTimeMillis
()
>
(
inList
.
getStartTime
()
+
timeOutTime
))
{
if
(
System
.
currentTimeMillis
()
>
(
inList
.
getStartTime
()
+
timeOutTime
))
{
List
<
InListItem
>
newItemsList
=
new
ArrayList
<>();
List
<
InListItem
>
newItemsList
=
new
ArrayList
<>();
for
(
InListItem
item
:
for
(
InListItem
item
:
inList
.
getInListItems
())
{
inList
.
getInListItems
())
{
if
(
item
.
getNum
()
-
item
.
getInNum
()
>
0
)
{
if
(
item
.
getNum
()
-
item
.
getInNum
()
>
0
)
{
//发送邮件
//发送邮件
log
.
info
(
"sendEmail入库单:"
+
inList
.
getName
());
log
.
info
(
"sendEmail入库单:"
+
inList
.
getName
());
Micron20031Api
.
sendEmail
(
Micron20031Api
.
Email_TO
,
Micron20031Api
.
Email_CC
,
inList
.
getName
(),
item
.
getRi
());
String
content
=
"Matreq ["
+
inList
.
getName
()
+
"] has exceed expected loading time"
;
Micron20031Api
.
sendEmail
(
Micron20031Api
.
Email_TO
,
Micron20031Api
.
Email_CC
,
inList
.
getName
(),
content
);
log
.
info
(
"sendEmail ["
+
inList
.
getName
()
+
"] ["
+
item
.
getRi
()
+
"] 给["
+
Micron20031Api
.
Email_TO
+
"]["
+
Micron20031Api
.
Email_CC
+
"] 成功"
);
log
.
info
(
"sendEmail ["
+
inList
.
getName
()
+
"] ["
+
item
.
getRi
()
+
"] 给["
+
Micron20031Api
.
Email_TO
+
"]["
+
Micron20031Api
.
Email_CC
+
"] 成功"
);
item
.
setSendEmail
(
true
);
item
.
setSendEmail
(
true
);
inListItemManager
.
save
(
item
);
inListItemManager
.
save
(
item
);
...
...
src/main/resources/config/application.yml
查看文件 @
70fa842
...
@@ -17,7 +17,7 @@ micron:
...
@@ -17,7 +17,7 @@ micron:
defToken
:
Bearer 0f1a4408-7235-3f01-b671-f71491dc6bfa
defToken
:
Bearer 0f1a4408-7235-3f01-b671-f71491dc6bfa
getTokenUrl
:
https://apim-opc-prod.micron.com/token
getTokenUrl
:
https://apim-opc-prod.micron.com/token
email
:
email
:
to
:
leandraang@micron.com
to
:
leandraang@micron.com
,eileentanyl@micron.com
cc
:
eileentanyl@micron.com
cc
:
eileentanyl@micron.com
#登录信息配置
#登录信息配置
...
...
src/main/resources/messages_en_US.properties
查看文件 @
70fa842
...
@@ -28,7 +28,7 @@ smfcore.roleCannotDel=Role[{0}]has[{1}]user assiciations, deletion failed
...
@@ -28,7 +28,7 @@ smfcore.roleCannotDel=Role[{0}]has[{1}]user assiciations, deletion failed
smfcore.notFindPos
=
Locked position not found
smfcore.notFindPos
=
Locked position not found
smfcore.error.barcode.empty
=
Barcode empty
smfcore.error.barcode.empty
=
Barcode empty
smfcore.error.barcode.many
=
Found several barcodes, storage failed
smfcore.error.barcode.many
=
Found several barcodes, storage failed
smfcore.error.barcode.expired
=
Ree
l expired, storage failed
smfcore.error.barcode.expired
=
Materia
l expired, storage failed
smfcore.allBoxView.noReel
=
No reel in position {0}
smfcore.allBoxView.noReel
=
No reel in position {0}
smfcore.error.barcode.many
=
Found several barcodes
smfcore.error.barcode.many
=
Found several barcodes
smfcore.error.barcode.noValidCode
=
Invalid barcode
smfcore.error.barcode.noValidCode
=
Invalid barcode
...
...
编写
预览
支持
Markdown
格式
附加文件
你添加了
0
人
到此讨论。请谨慎行事。
Finish editing this message first!
Cancel
请
注册
或
登录
后发表评论