Skip to content
切换导航条
切换导航条
当前项目
正在载入...
登录
孙克
/
smf-core
转到一个项目
切换导航栏
切换导航栏固定状态
项目
群组
代码片段
帮助
项目
活动
版本库
流水线
图表
问题
0
合并请求
0
维基
网络
创建新的问题
作业
提交
问题看板
文件
提交
网络
比较
分支
标签
Commit 878b5481
由
zshaohui
编写于
2025-01-03 13:14:31 +0800
浏览文件
选项
浏览文件
标签
下载
电子邮件补丁
差异文件
1.增加过期报表
1 个父辈
bd25c3f1
隐藏空白字符变更
内嵌
并排
正在显示
9 个修改的文件
包含
104 行增加
和
39 行删除
src/main/java/com/neotel/smfcore/core/barcode/bean/BarcodeRule.java
src/main/java/com/neotel/smfcore/core/barcode/utils/CodeResolve.java
src/main/java/com/neotel/smfcore/custom/lizhen/LizhenApi.java
src/main/java/com/neotel/smfcore/custom/lizhen/report/outer/OuterReportController.java
src/main/java/com/neotel/smfcore/custom/luxsan/factory_c/rawstor/controller/CDeviceController.java
src/main/java/com/neotel/smfcore/custom/luxsan/factory_c/rawstor/controller/manual/ManualGrPutInController.java
src/main/java/com/neotel/smfcore/custom/luxsan/factory_c/rawstor/controller/manual/ManualReturnTowerController.java
src/main/java/com/neotel/smfcore/custom/luxsan/factory_c/rawstor/controller/manual/ManualTicketReturnController.java
src/main/java/com/neotel/smfcore/custom/luxsan/factory_c/rawstor/controller/manual/ManualTicketTransferController.java
src/main/java/com/neotel/smfcore/core/barcode/bean/BarcodeRule.java
查看文件 @
878b548
...
@@ -653,8 +653,8 @@ public class BarcodeRule {
...
@@ -653,8 +653,8 @@ public class BarcodeRule {
}
}
b
.
setDateCode
(
dateCode
);
b
.
setDateCode
(
dateCode
);
//设置生产日期
//设置生产日期
produceDate
=
ExpireDateUtil
.
getExpireDate
(
dateCode
,
supplier
);
//
produceDate = ExpireDateUtil.getExpireDate(dateCode, supplier);
b
.
setProduceDate
(
produceDate
);
//
b.setProduceDate(produceDate);
}
}
if
(
providerNumber_item
.
hasThisField
()){
if
(
providerNumber_item
.
hasThisField
()){
...
...
src/main/java/com/neotel/smfcore/core/barcode/utils/CodeResolve.java
查看文件 @
878b548
...
@@ -150,7 +150,7 @@ public class CodeResolve {
...
@@ -150,7 +150,7 @@ public class CodeResolve {
Date
produceDate
=
barcodeFromRule
.
getProduceDate
();
Date
produceDate
=
barcodeFromRule
.
getProduceDate
();
if
(
produceDate
!=
null
){
if
(
produceDate
!=
null
){
//抓取到了生产日期,未抓取到过期日期,重新设置过期日期
//抓取到了生产日期,未抓取到过期日期,重新设置过期日期
if
(
barcode
.
getExpireDate
()
==
null
){
/*
if(barcode.getExpireDate() == null){
if(validDay > 0){
if(validDay > 0){
log.info("重新设置"+codeBeanFromRule.getCodeStr()+"生产日期和过期日期");
log.info("重新设置"+codeBeanFromRule.getCodeStr()+"生产日期和过期日期");
Date expireDate = DateUtil.addDays(produceDate, validDay);
Date expireDate = DateUtil.addDays(produceDate, validDay);
...
@@ -158,7 +158,7 @@ public class CodeResolve {
...
@@ -158,7 +158,7 @@ public class CodeResolve {
barcode.setProduceDate(produceDate);
barcode.setProduceDate(produceDate);
needUpdate = true;
needUpdate = true;
}
}
}
}
*/
}
}
//判断供应商代码是否为空
//判断供应商代码是否为空
String
providerNumber
=
barcodeFromRule
.
getProviderNumber
();
String
providerNumber
=
barcodeFromRule
.
getProviderNumber
();
...
@@ -186,12 +186,12 @@ public class CodeResolve {
...
@@ -186,12 +186,12 @@ public class CodeResolve {
needUpdate
=
true
;
needUpdate
=
true
;
}
}
//判断是否为空
//判断是否为空
if
(
barcodeFromRule
.
getProduceDate
()
!=
null
)
{
/*
if (barcodeFromRule.getProduceDate() != null) {
barcode.setExpireDate(cn.hutool.core.date.DateUtil.offsetMonth(barcodeFromRule.getProduceDate(),12));
barcode.setExpireDate(cn.hutool.core.date.DateUtil.offsetMonth(barcodeFromRule.getProduceDate(),12));
needUpdate = true;
needUpdate = true;
} else {
} else {
barcode.setExpireDate(null);
barcode.setExpireDate(null);
}
}
*/
//设置label数量
//设置label数量
if
(
barcodeFromRule
.
getLabelAmount
()
!=
barcode
.
getLabelAmount
())
{
if
(
barcodeFromRule
.
getLabelAmount
()
!=
barcode
.
getLabelAmount
())
{
barcode
.
setLabelAmount
(
barcodeFromRule
.
getLabelAmount
());
barcode
.
setLabelAmount
(
barcodeFromRule
.
getLabelAmount
());
...
@@ -305,7 +305,7 @@ public class CodeResolve {
...
@@ -305,7 +305,7 @@ public class CodeResolve {
if (expiredSetting != null){
if (expiredSetting != null){
barcodeFromRule.setExpireDate(cn.hutool.core.date.DateUtil.offsetMonth(barcodeFromRule.getProduceDate(),expiredSetting.getMonth()));
barcodeFromRule.setExpireDate(cn.hutool.core.date.DateUtil.offsetMonth(barcodeFromRule.getProduceDate(),expiredSetting.getMonth()));
}*/
}*/
barcodeFromRule
.
setExpireDate
(
cn
.
hutool
.
core
.
date
.
DateUtil
.
offsetMonth
(
barcodeFromRule
.
getProduceDate
(),
12
));
//
barcodeFromRule.setExpireDate(cn.hutool.core.date.DateUtil.offsetMonth(barcodeFromRule.getProduceDate(),12));
}
}
...
...
src/main/java/com/neotel/smfcore/custom/lizhen/LizhenApi.java
查看文件 @
878b548
...
@@ -276,7 +276,7 @@ public class LizhenApi extends DefaultSmfApiListener {
...
@@ -276,7 +276,7 @@ public class LizhenApi extends DefaultSmfApiListener {
}
}
//保存禁用料记录
//保存禁用料记录
Barcode
barcodeOri
=
barcodeManager
.
findByBarcode
(
barcode
.
getBarcode
());
/*
Barcode barcodeOri = barcodeManager.findByBarcode(barcode.getBarcode());
if (barcodeOri != null){
if (barcodeOri != null){
barcodeOri.setDisableMsg(resultStr);
barcodeOri.setDisableMsg(resultStr);
barcode = barcodeManager.save(barcodeOri);
barcode = barcodeManager.save(barcodeOri);
...
@@ -285,7 +285,7 @@ public class LizhenApi extends DefaultSmfApiListener {
...
@@ -285,7 +285,7 @@ public class LizhenApi extends DefaultSmfApiListener {
storagePos.setBarcode(barcode);
storagePos.setBarcode(barcode);
storagePosManager.save(storagePos);
storagePosManager.save(storagePos);
}
}
}
}
*/
if
(
StringUtils
.
isNotBlank
(
resultStr
))
{
if
(
StringUtils
.
isNotBlank
(
resultStr
))
{
throw
new
ValidateException
(
"smfcore.mesApi.inCheck.ng"
,
/*"MES验证失败:" + */
barcode
.
getBarcode
()
+
"验证失败:"
+
resultStr
);
throw
new
ValidateException
(
"smfcore.mesApi.inCheck.ng"
,
/*"MES验证失败:" + */
barcode
.
getBarcode
()
+
"验证失败:"
+
resultStr
);
...
...
src/main/java/com/neotel/smfcore/custom/lizhen/report/outer/OuterReportController.java
查看文件 @
878b548
...
@@ -788,7 +788,7 @@ public class OuterReportController {
...
@@ -788,7 +788,7 @@ public class OuterReportController {
public
PageData
<
ExpireDto
>
expireInfo
(
ReportQueryCondition
queryCondition
,
Pageable
pageable
)
{
public
PageData
<
ExpireDto
>
expireInfo
(
ReportQueryCondition
queryCondition
,
Pageable
pageable
)
{
Query
query
=
QueryHelp
.
getQuery
(
queryCondition
);
Query
query
=
QueryHelp
.
getQuery
(
queryCondition
);
Criteria
c
=
Criteria
.
where
(
"posName"
).
exists
(
true
).
ne
(
""
).
and
(
"partNumber"
).
nin
(
Arrays
.
asList
(
"C
S"
,
"CM"
,
"CB
"
));
Criteria
c
=
Criteria
.
where
(
"posName"
).
exists
(
true
).
ne
(
""
).
and
(
"partNumber"
).
nin
(
Arrays
.
asList
(
"C
07"
,
"C13"
,
"C15
"
));
//判断传入的类型
//判断传入的类型
String
expireStatus
=
queryCondition
.
getExpireStatus
();
String
expireStatus
=
queryCondition
.
getExpireStatus
();
Date
startDate
,
endDate
;
Date
startDate
,
endDate
;
...
@@ -802,8 +802,8 @@ public class OuterReportController {
...
@@ -802,8 +802,8 @@ public class OuterReportController {
c
.
and
(
"expireDate"
).
gte
(
startDate
).
lt
(
endDate
);
c
.
and
(
"expireDate"
).
gte
(
startDate
).
lt
(
endDate
);
}
else
if
(
"2"
.
equals
(
expireStatus
))
{
}
else
if
(
"2"
.
equals
(
expireStatus
))
{
List
<
Criteria
>
orCriList
=
new
ArrayList
<>();
List
<
Criteria
>
orCriList
=
new
ArrayList
<>();
orCriList
.
add
(
Criteria
.
where
(
"expireDate"
).
gt
(
new
Date
()).
and
(
"posName"
).
exists
(
true
).
ne
(
""
).
and
(
"partNumber"
).
nin
(
Arrays
.
asList
(
"C
S"
,
"CM"
,
"CB
"
)));
orCriList
.
add
(
Criteria
.
where
(
"expireDate"
).
gt
(
new
Date
()).
and
(
"posName"
).
exists
(
true
).
ne
(
""
).
and
(
"partNumber"
).
nin
(
Arrays
.
asList
(
"C
07"
,
"C13"
,
"C15
"
)));
orCriList
.
add
(
Criteria
.
where
(
"expireDate"
).
exists
(
false
).
and
(
"posName"
).
exists
(
true
).
ne
(
""
).
and
(
"partNumber"
).
nin
(
Arrays
.
asList
(
"C
S"
,
"CM"
,
"CB
"
)));
orCriList
.
add
(
Criteria
.
where
(
"expireDate"
).
exists
(
false
).
and
(
"posName"
).
exists
(
true
).
ne
(
""
).
and
(
"partNumber"
).
nin
(
Arrays
.
asList
(
"C
07"
,
"C13"
,
"C15
"
)));
c
.
orOperator
(
orCriList
);
c
.
orOperator
(
orCriList
);
}
else
if
(
"3"
.
equals
(
expireStatus
))
{
}
else
if
(
"3"
.
equals
(
expireStatus
))
{
endDate
=
new
Date
();
endDate
=
new
Date
();
...
@@ -819,7 +819,7 @@ public class OuterReportController {
...
@@ -819,7 +819,7 @@ public class OuterReportController {
//提取出来料箱信息
//提取出来料箱信息
List
<
String
>
boxStrList
=
barcodeList
.
stream
().
filter
(
item
->
{
List
<
String
>
boxStrList
=
barcodeList
.
stream
().
filter
(
item
->
{
String
posName
=
item
.
getPosName
();
String
posName
=
item
.
getPosName
();
if
(
posName
.
startsWith
(
"C
S"
)
||
posName
.
startsWith
(
"CM"
)
||
posName
.
startsWith
(
"CB
"
))
{
if
(
posName
.
startsWith
(
"C
07"
)
||
posName
.
startsWith
(
"C13"
)
||
posName
.
startsWith
(
"C15
"
))
{
if
(
posName
.
indexOf
(
"-"
)
!=
-
1
)
{
if
(
posName
.
indexOf
(
"-"
)
!=
-
1
)
{
return
true
;
return
true
;
}
}
...
@@ -849,9 +849,9 @@ public class OuterReportController {
...
@@ -849,9 +849,9 @@ public class OuterReportController {
}
else
{
}
else
{
dto
.
setExpireDays
(
0
);
dto
.
setExpireDays
(
0
);
}
}
dto
.
setPlant
(
"W337"
);
//
dto.setPlant("W337");
dto
.
setFactory
(
"B15"
);
//
dto.setFactory("B15");
dto
.
setFloor
(
"1F"
);
//
dto.setFloor("1F");
dto
.
setFirstPutInDate
(
new
Date
(
barcode
.
getPutInTime
()));
dto
.
setFirstPutInDate
(
new
Date
(
barcode
.
getPutInTime
()));
if
(
StringUtils
.
isNotBlank
(
dto
.
getStorageId
()))
{
if
(
StringUtils
.
isNotBlank
(
dto
.
getStorageId
()))
{
Storage
storage
=
dataCache
.
getStorageById
(
dto
.
getStorageId
());
Storage
storage
=
dataCache
.
getStorageById
(
dto
.
getStorageId
());
...
@@ -877,7 +877,7 @@ public class OuterReportController {
...
@@ -877,7 +877,7 @@ public class OuterReportController {
@AnonymousAccess
@AnonymousAccess
public
void
expireInfoDownload
(
ReportQueryCondition
queryCondition
,
Pageable
pageable
,
HttpServletResponse
response
)
throws
IOException
{
public
void
expireInfoDownload
(
ReportQueryCondition
queryCondition
,
Pageable
pageable
,
HttpServletResponse
response
)
throws
IOException
{
Query
query
=
QueryHelp
.
getQuery
(
queryCondition
);
Query
query
=
QueryHelp
.
getQuery
(
queryCondition
);
Criteria
c
=
Criteria
.
where
(
"posName"
).
exists
(
true
).
ne
(
""
).
and
(
"partNumber"
).
nin
(
Arrays
.
asList
(
"C
S"
,
"CM"
,
"CB
"
));
Criteria
c
=
Criteria
.
where
(
"posName"
).
exists
(
true
).
ne
(
""
).
and
(
"partNumber"
).
nin
(
Arrays
.
asList
(
"C
07"
,
"C13"
,
"C15
"
));
//判断传入的类型
//判断传入的类型
String
expireStatus
=
queryCondition
.
getExpireStatus
();
String
expireStatus
=
queryCondition
.
getExpireStatus
();
...
@@ -892,8 +892,8 @@ public class OuterReportController {
...
@@ -892,8 +892,8 @@ public class OuterReportController {
c
.
and
(
"expireDate"
).
gte
(
startDate
).
lt
(
endDate
);
c
.
and
(
"expireDate"
).
gte
(
startDate
).
lt
(
endDate
);
}
else
if
(
"2"
.
equals
(
expireStatus
))
{
}
else
if
(
"2"
.
equals
(
expireStatus
))
{
List
<
Criteria
>
orCriList
=
new
ArrayList
<>();
List
<
Criteria
>
orCriList
=
new
ArrayList
<>();
orCriList
.
add
(
Criteria
.
where
(
"expireDate"
).
gt
(
new
Date
()).
and
(
"posName"
).
exists
(
true
).
ne
(
""
).
and
(
"partNumber"
).
nin
(
Arrays
.
asList
(
"C
S"
,
"CM"
,
"CB
"
)));
orCriList
.
add
(
Criteria
.
where
(
"expireDate"
).
gt
(
new
Date
()).
and
(
"posName"
).
exists
(
true
).
ne
(
""
).
and
(
"partNumber"
).
nin
(
Arrays
.
asList
(
"C
07"
,
"C13"
,
"C15
"
)));
orCriList
.
add
(
Criteria
.
where
(
"expireDate"
).
exists
(
false
).
and
(
"posName"
).
exists
(
true
).
ne
(
""
).
and
(
"partNumber"
).
nin
(
Arrays
.
asList
(
"C
S"
,
"CM"
,
"CB
"
)));
orCriList
.
add
(
Criteria
.
where
(
"expireDate"
).
exists
(
false
).
and
(
"posName"
).
exists
(
true
).
ne
(
""
).
and
(
"partNumber"
).
nin
(
Arrays
.
asList
(
"C
07"
,
"C13"
,
"C15
"
)));
c
.
orOperator
(
orCriList
);
c
.
orOperator
(
orCriList
);
}
else
if
(
"3"
.
equals
(
expireStatus
))
{
}
else
if
(
"3"
.
equals
(
expireStatus
))
{
endDate
=
new
Date
();
endDate
=
new
Date
();
...
@@ -905,25 +905,25 @@ public class OuterReportController {
...
@@ -905,25 +905,25 @@ public class OuterReportController {
@Override
@Override
public
List
<
List
<
String
>>
getHeader
()
{
public
List
<
List
<
String
>>
getHeader
()
{
List
<
List
<
String
>>
header
=
new
ArrayList
<>();
List
<
List
<
String
>>
header
=
new
ArrayList
<>();
header
.
add
(
Lists
.
newArrayList
(
"厂别"
));
//
header.add(Lists.newArrayList("厂别"));
header
.
add
(
Lists
.
newArrayList
(
"厂区"
));
//
header.add(Lists.newArrayList("厂区"));
header
.
add
(
Lists
.
newArrayList
(
"库别"
));
header
.
add
(
Lists
.
newArrayList
(
"库别"
));
header
.
add
(
Lists
.
newArrayList
(
"楼层"
));
header
.
add
(
Lists
.
newArrayList
(
"楼层"
));
header
.
add
(
Lists
.
newArrayList
(
"储位"
));
header
.
add
(
Lists
.
newArrayList
(
"储位"
));
header
.
add
(
Lists
.
newArrayList
(
"隔口码"
));
header
.
add
(
Lists
.
newArrayList
(
"隔口码"
));
header
.
add
(
Lists
.
newArrayList
(
"隔口数量"
));
header
.
add
(
Lists
.
newArrayList
(
"隔口数量"
));
header
.
add
(
Lists
.
newArrayList
(
"料号"
));
header
.
add
(
Lists
.
newArrayList
(
"料号"
));
header
.
add
(
Lists
.
newArrayList
(
"物料描述"
));
//
header.add(Lists.newArrayList("物料描述"));
header
.
add
(
Lists
.
newArrayList
(
"数量"
));
header
.
add
(
Lists
.
newArrayList
(
"数量"
));
header
.
add
(
Lists
.
newArrayList
(
"LOT"
));
header
.
add
(
Lists
.
newArrayList
(
"LOT"
));
header
.
add
(
Lists
.
newArrayList
(
"D/C"
));
header
.
add
(
Lists
.
newArrayList
(
"D/C"
));
header
.
add
(
Lists
.
newArrayList
(
"ID NO"
));
header
.
add
(
Lists
.
newArrayList
(
"ID NO"
));
header
.
add
(
Lists
.
newArrayList
(
"厂商"
));
header
.
add
(
Lists
.
newArrayList
(
"厂商"
));
header
.
add
(
Lists
.
newArrayList
(
"厂商代码"
));
header
.
add
(
Lists
.
newArrayList
(
"厂商代码"
));
header
.
add
(
Lists
.
newArrayList
(
"keeper"
));
//
header.add(Lists.newArrayList("keeper"));
header
.
add
(
Lists
.
newArrayList
(
"过期天数"
));
header
.
add
(
Lists
.
newArrayList
(
"过期天数"
));
header
.
add
(
Lists
.
newArrayList
(
"过期日期"
));
header
.
add
(
Lists
.
newArrayList
(
"过期日期"
));
header
.
add
(
Lists
.
newArrayList
(
"工号"
));
//
header.add(Lists.newArrayList("工号"));
header
.
add
(
Lists
.
newArrayList
(
"首次入库时间"
));
header
.
add
(
Lists
.
newArrayList
(
"首次入库时间"
));
header
.
add
(
Lists
.
newArrayList
(
"当前入库时间"
));
header
.
add
(
Lists
.
newArrayList
(
"当前入库时间"
));
header
.
add
(
Lists
.
newArrayList
(
"来源"
));
header
.
add
(
Lists
.
newArrayList
(
"来源"
));
...
@@ -939,7 +939,7 @@ public class OuterReportController {
...
@@ -939,7 +939,7 @@ public class OuterReportController {
//提取出来料箱信息
//提取出来料箱信息
List
<
String
>
boxStrList
=
barcodeList
.
stream
().
filter
(
item
->
{
List
<
String
>
boxStrList
=
barcodeList
.
stream
().
filter
(
item
->
{
String
posName
=
item
.
getPosName
();
String
posName
=
item
.
getPosName
();
if
(
posName
.
startsWith
(
"C
S"
)
||
posName
.
startsWith
(
"CM"
)
||
posName
.
startsWith
(
"CB
"
))
{
if
(
posName
.
startsWith
(
"C
07"
)
||
posName
.
startsWith
(
"C13"
)
||
posName
.
startsWith
(
"C15
"
))
{
if
(
posName
.
indexOf
(
"-"
)
!=
-
1
)
{
if
(
posName
.
indexOf
(
"-"
)
!=
-
1
)
{
return
true
;
return
true
;
}
}
...
@@ -981,25 +981,25 @@ public class OuterReportController {
...
@@ -981,25 +981,25 @@ public class OuterReportController {
dto
.
setPartitionCount
(
BoxUtil
.
getPartitionCount
(
dto
.
getPosName
(),
pidBarcode
.
getSubCodeList
()));
dto
.
setPartitionCount
(
BoxUtil
.
getPartitionCount
(
dto
.
getPosName
(),
pidBarcode
.
getSubCodeList
()));
dto
.
setStoragePosName
(
pidBarcode
.
getPosName
());
dto
.
setStoragePosName
(
pidBarcode
.
getPosName
());
}
}
data
.
add
(
dto
.
getPlant
());
//
data.add(dto.getPlant());
data
.
add
(
dto
.
getFactory
());
//
data.add(dto.getFactory());
data
.
add
(
dto
.
getWarehouseCode
());
data
.
add
(
dto
.
getWarehouseCode
());
data
.
add
(
dto
.
getFloor
());
data
.
add
(
dto
.
getFloor
());
data
.
add
(
dto
.
getStoragePosName
());
data
.
add
(
dto
.
getStoragePosName
());
data
.
add
(
dto
.
getPosName
());
data
.
add
(
dto
.
getPosName
());
data
.
add
(
dto
.
getPartitionCount
());
data
.
add
(
dto
.
getPartitionCount
());
data
.
add
(
dto
.
getPartNumber
());
data
.
add
(
dto
.
getPartNumber
());
data
.
add
(
dto
.
getDescribe
());
//
data.add(dto.getDescribe());
data
.
add
(
dto
.
getAmount
());
data
.
add
(
dto
.
getAmount
());
data
.
add
(
dto
.
getBatch
());
data
.
add
(
dto
.
getBatch
());
data
.
add
(
dto
.
getDateCode
());
data
.
add
(
dto
.
getDateCode
());
data
.
add
(
dto
.
getBarcode
());
data
.
add
(
dto
.
getBarcode
());
data
.
add
(
dto
.
getProvider
());
data
.
add
(
dto
.
getProvider
());
data
.
add
(
dto
.
getProviderNumber
());
data
.
add
(
dto
.
getProviderNumber
());
data
.
add
(
dto
.
getKeeperCode
());
//
data.add(dto.getKeeperCode());
data
.
add
(
dto
.
getExpireDays
());
data
.
add
(
dto
.
getExpireDays
());
data
.
add
(
dto
.
getExpireDate
());
data
.
add
(
dto
.
getExpireDate
());
data
.
add
(
dto
.
getCreator
());
//
data.add(dto.getCreator());
data
.
add
(
dto
.
getFirstPutInDate
());
data
.
add
(
dto
.
getFirstPutInDate
());
data
.
add
(
dto
.
getPutInDate
());
data
.
add
(
dto
.
getPutInDate
());
data
.
add
(
dto
.
getSource
());
data
.
add
(
dto
.
getSource
());
...
...
src/main/java/com/neotel/smfcore/custom/luxsan/factory_c/rawstor/controller/CDeviceController.java
查看文件 @
878b548
...
@@ -228,6 +228,19 @@ public class CDeviceController {
...
@@ -228,6 +228,19 @@ public class CDeviceController {
soucre
=
MaterialUtil
.
getBindGrInfo
(
materialStr
).
getGrCode
();
soucre
=
MaterialUtil
.
getBindGrInfo
(
materialStr
).
getGrCode
();
}
}
//设置barcode的过期时间
int
days
=
LuxsanApi
.
getInDate
(
new
GetInDateRequest
(
CommonUtil
.
plantCode
,
barcode
.
getPartNumber
(),
barcode
.
getProvider
(),
barcode
.
getDateCode
()));
log
.
info
(
barcode
.
getBarcode
()+
"的剩余过期时间为:"
+
days
);
if
(
days
>
0
)
{
Date
expireDate
=
cn
.
hutool
.
core
.
date
.
DateUtil
.
offsetDay
(
new
Date
(),
days
);
barcode
.
setExpireDate
(
expireDate
);
}
if
(
barcode
.
getExpireDate
()
!=
null
){
if
(
System
.
currentTimeMillis
()
>
barcode
.
getExpireDate
().
getTime
())
{
throw
new
ValidateException
(
"smfcore.error.barcode.expired"
,
"物料已过期,无法入库."
);
}
}
//判断料格是否正常
//判断料格是否正常
Barcode
boxBarcode
=
null
;
Barcode
boxBarcode
=
null
;
...
@@ -735,12 +748,13 @@ public class CDeviceController {
...
@@ -735,12 +748,13 @@ public class CDeviceController {
}
}
//清理条码档案信息
//清理条码档案信息
log
.
info
(
barcode
.
getBarcode
()+
"的库位置为空"
);
barcode
.
setPosName
(
""
);
barcode
.
setPosName
(
""
);
barcode
.
setOut
(
false
);
barcode
.
setOut
(
false
);
barcode
.
setOrderId
(
""
);
barcode
.
setOrderId
(
""
);
barcode
.
setOrderItemId
(
""
);
barcode
.
setOrderItemId
(
""
);
barcode
.
setBarSource
(
""
);
barcode
.
setBarSource
(
""
);
barcodeManager
.
save
Barcode
(
barcode
);
barcodeManager
.
save
(
barcode
);
Map
<
String
,
String
>
resultMap
=
new
HashMap
<>();
Map
<
String
,
String
>
resultMap
=
new
HashMap
<>();
resultMap
.
put
(
"binCode"
,
boxStr
);
resultMap
.
put
(
"binCode"
,
boxStr
);
...
...
src/main/java/com/neotel/smfcore/custom/luxsan/factory_c/rawstor/controller/manual/ManualGrPutInController.java
查看文件 @
878b548
...
@@ -27,6 +27,7 @@ import com.neotel.smfcore.core.system.util.TaskService;
...
@@ -27,6 +27,7 @@ import com.neotel.smfcore.core.system.util.TaskService;
import
com.neotel.smfcore.custom.lizhen.agvBox.util.BoxUtil
;
import
com.neotel.smfcore.custom.lizhen.agvBox.util.BoxUtil
;
import
com.neotel.smfcore.custom.luxsan.api.LuxsanApi
;
import
com.neotel.smfcore.custom.luxsan.api.LuxsanApi
;
import
com.neotel.smfcore.custom.luxsan.api.bean.request.BrandQtyRequest
;
import
com.neotel.smfcore.custom.luxsan.api.bean.request.BrandQtyRequest
;
import
com.neotel.smfcore.custom.luxsan.api.bean.request.GetInDateRequest
;
import
com.neotel.smfcore.custom.luxsan.api.bean.request.NewLabelToCellRequest
;
import
com.neotel.smfcore.custom.luxsan.api.bean.request.NewLabelToCellRequest
;
import
com.neotel.smfcore.custom.luxsan.api.bean.request.QueryGrStatusRequest
;
import
com.neotel.smfcore.custom.luxsan.api.bean.request.QueryGrStatusRequest
;
import
com.neotel.smfcore.custom.luxsan.api.bean.result.BrandQtyResult
;
import
com.neotel.smfcore.custom.luxsan.api.bean.result.BrandQtyResult
;
...
@@ -271,6 +272,7 @@ public class ManualGrPutInController {
...
@@ -271,6 +272,7 @@ public class ManualGrPutInController {
return
ResultBean
.
newErrorResult
(-
1
,
""
,
barcode
.
getBarcode
()
+
"已经存在料格"
+
barcode
.
getPosName
());
return
ResultBean
.
newErrorResult
(-
1
,
""
,
barcode
.
getBarcode
()
+
"已经存在料格"
+
barcode
.
getPosName
());
}
}
//找到box信息
//找到box信息
Barcode
boxBarcode
=
null
;
Barcode
boxBarcode
=
null
;
StoragePos
inPos
=
null
;
StoragePos
inPos
=
null
;
...
@@ -294,6 +296,20 @@ public class ManualGrPutInController {
...
@@ -294,6 +296,20 @@ public class ManualGrPutInController {
barcode
.
setWarehouseCode
(
warhouseCode
);
barcode
.
setWarehouseCode
(
warhouseCode
);
int
days
=
LuxsanApi
.
getInDate
(
new
GetInDateRequest
(
CommonUtil
.
plantCode
,
barcode
.
getPartNumber
(),
barcode
.
getProvider
(),
barcode
.
getDateCode
()));
log
.
info
(
barcode
.
getBarcode
()+
"的剩余过期时间为:"
+
days
);
if
(
days
>
0
)
{
Date
expireDate
=
cn
.
hutool
.
core
.
date
.
DateUtil
.
offsetDay
(
new
Date
(),
days
);
barcode
.
setExpireDate
(
expireDate
);
}
if
(
barcode
.
getExpireDate
()
!=
null
){
if
(
System
.
currentTimeMillis
()
>
barcode
.
getExpireDate
().
getTime
())
{
throw
new
ValidateException
(
"smfcore.error.barcode.expired"
,
"物料已过期,无法入库."
);
}
}
//判断隔口能否放入
//判断隔口能否放入
if
(
boxBarcode
!=
null
){
if
(
boxBarcode
!=
null
){
...
...
src/main/java/com/neotel/smfcore/custom/luxsan/factory_c/rawstor/controller/manual/ManualReturnTowerController.java
查看文件 @
878b548
...
@@ -18,6 +18,7 @@ import com.neotel.smfcore.core.system.util.TaskService;
...
@@ -18,6 +18,7 @@ import com.neotel.smfcore.core.system.util.TaskService;
import
com.neotel.smfcore.custom.luxsan.api.LuxsanApi
;
import
com.neotel.smfcore.custom.luxsan.api.LuxsanApi
;
import
com.neotel.smfcore.custom.luxsan.api.bean.request.BackToWarehouseRequest
;
import
com.neotel.smfcore.custom.luxsan.api.bean.request.BackToWarehouseRequest
;
import
com.neotel.smfcore.custom.luxsan.api.bean.request.BrandQtyRequest
;
import
com.neotel.smfcore.custom.luxsan.api.bean.request.BrandQtyRequest
;
import
com.neotel.smfcore.custom.luxsan.api.bean.request.GetInDateRequest
;
import
com.neotel.smfcore.custom.luxsan.api.bean.result.BackToWarehouseResult
;
import
com.neotel.smfcore.custom.luxsan.api.bean.result.BackToWarehouseResult
;
import
com.neotel.smfcore.custom.luxsan.api.bean.result.BrandQtyResult
;
import
com.neotel.smfcore.custom.luxsan.api.bean.result.BrandQtyResult
;
import
com.neotel.smfcore.custom.luxsan.factory_c.common.util.CommonUtil
;
import
com.neotel.smfcore.custom.luxsan.factory_c.common.util.CommonUtil
;
...
@@ -156,6 +157,19 @@ public class ManualReturnTowerController {
...
@@ -156,6 +157,19 @@ public class ManualReturnTowerController {
//判断在WMS系统中,是否存在
//判断在WMS系统中,是否存在
barcode
=
LuxsanApi
.
fetchReel
(
barcode
);
barcode
=
LuxsanApi
.
fetchReel
(
barcode
);
int
days
=
LuxsanApi
.
getInDate
(
new
GetInDateRequest
(
CommonUtil
.
plantCode
,
barcode
.
getPartNumber
(),
barcode
.
getProvider
(),
barcode
.
getDateCode
()));
log
.
info
(
barcode
.
getBarcode
()+
"的剩余过期时间为:"
+
days
);
if
(
days
>
0
)
{
Date
expireDate
=
cn
.
hutool
.
core
.
date
.
DateUtil
.
offsetDay
(
new
Date
(),
days
);
barcode
.
setExpireDate
(
expireDate
);
}
if
(
barcode
.
getExpireDate
()
!=
null
){
if
(
System
.
currentTimeMillis
()
>
barcode
.
getExpireDate
().
getTime
())
{
throw
new
ValidateException
(
"smfcore.error.barcode.expired"
,
"物料已过期,无法入库."
);
}
}
//找到box信息
//找到box信息
Barcode
boxBarcode
=
null
;
Barcode
boxBarcode
=
null
;
StoragePos
inPos
=
null
;
StoragePos
inPos
=
null
;
...
...
src/main/java/com/neotel/smfcore/custom/luxsan/factory_c/rawstor/controller/manual/ManualTicketReturnController.java
查看文件 @
878b548
...
@@ -16,10 +16,7 @@ import com.neotel.smfcore.core.storage.service.po.StoragePos;
...
@@ -16,10 +16,7 @@ import com.neotel.smfcore.core.storage.service.po.StoragePos;
import
com.neotel.smfcore.core.system.service.po.DataLog
;
import
com.neotel.smfcore.core.system.service.po.DataLog
;
import
com.neotel.smfcore.core.system.util.TaskService
;
import
com.neotel.smfcore.core.system.util.TaskService
;
import
com.neotel.smfcore.custom.luxsan.api.LuxsanApi
;
import
com.neotel.smfcore.custom.luxsan.api.LuxsanApi
;
import
com.neotel.smfcore.custom.luxsan.api.bean.request.BrandQtyRequest
;
import
com.neotel.smfcore.custom.luxsan.api.bean.request.*
;
import
com.neotel.smfcore.custom.luxsan.api.bean.request.TicketPickLabelList
;
import
com.neotel.smfcore.custom.luxsan.api.bean.request.TicketPickRequest
;
import
com.neotel.smfcore.custom.luxsan.api.bean.request.TicketUpRequest
;
import
com.neotel.smfcore.custom.luxsan.api.bean.result.BrandQtyResult
;
import
com.neotel.smfcore.custom.luxsan.api.bean.result.BrandQtyResult
;
import
com.neotel.smfcore.custom.luxsan.api.bean.result.TicketUpResult
;
import
com.neotel.smfcore.custom.luxsan.api.bean.result.TicketUpResult
;
import
com.neotel.smfcore.custom.luxsan.factory_c.common.util.CommonUtil
;
import
com.neotel.smfcore.custom.luxsan.factory_c.common.util.CommonUtil
;
...
@@ -163,6 +160,20 @@ public class ManualTicketReturnController {
...
@@ -163,6 +160,20 @@ public class ManualTicketReturnController {
//判断是否为禁用料
//判断是否为禁用料
barcode
=
smfApi
.
canPutInAfterResolve
(
barcode
);
barcode
=
smfApi
.
canPutInAfterResolve
(
barcode
);
int
days
=
LuxsanApi
.
getInDate
(
new
GetInDateRequest
(
CommonUtil
.
plantCode
,
barcode
.
getPartNumber
(),
barcode
.
getProvider
(),
barcode
.
getDateCode
()));
log
.
info
(
barcode
.
getBarcode
()+
"的剩余过期时间为:"
+
days
);
if
(
days
>
0
)
{
Date
expireDate
=
cn
.
hutool
.
core
.
date
.
DateUtil
.
offsetDay
(
new
Date
(),
days
);
barcode
.
setExpireDate
(
expireDate
);
}
if
(
barcode
.
getExpireDate
()
!=
null
){
if
(
System
.
currentTimeMillis
()
>
barcode
.
getExpireDate
().
getTime
())
{
throw
new
ValidateException
(
"smfcore.error.barcode.expired"
,
"物料已过期,无法入库."
);
}
}
if
(
StringUtils
.
isEmpty
(
barcode
.
getWarehouseCode
()))
{
if
(
StringUtils
.
isEmpty
(
barcode
.
getWarehouseCode
()))
{
String
wareHouse
=
StringUtils
.
isNotEmpty
(
dstWarehouse
)
?
dstWarehouse
:
srcWarehouse
;
String
wareHouse
=
StringUtils
.
isNotEmpty
(
dstWarehouse
)
?
dstWarehouse
:
srcWarehouse
;
barcode
.
setWarehouseCode
(
wareHouse
);
barcode
.
setWarehouseCode
(
wareHouse
);
...
...
src/main/java/com/neotel/smfcore/custom/luxsan/factory_c/rawstor/controller/manual/ManualTicketTransferController.java
查看文件 @
878b548
...
@@ -17,10 +17,7 @@ import com.neotel.smfcore.core.storage.service.po.StoragePos;
...
@@ -17,10 +17,7 @@ import com.neotel.smfcore.core.storage.service.po.StoragePos;
import
com.neotel.smfcore.core.system.service.po.DataLog
;
import
com.neotel.smfcore.core.system.service.po.DataLog
;
import
com.neotel.smfcore.core.system.util.TaskService
;
import
com.neotel.smfcore.core.system.util.TaskService
;
import
com.neotel.smfcore.custom.luxsan.api.LuxsanApi
;
import
com.neotel.smfcore.custom.luxsan.api.LuxsanApi
;
import
com.neotel.smfcore.custom.luxsan.api.bean.request.BrandQtyRequest
;
import
com.neotel.smfcore.custom.luxsan.api.bean.request.*
;
import
com.neotel.smfcore.custom.luxsan.api.bean.request.NewLabelToCellRequest
;
import
com.neotel.smfcore.custom.luxsan.api.bean.request.TicketPickLabelList
;
import
com.neotel.smfcore.custom.luxsan.api.bean.request.TicketPickRequest
;
import
com.neotel.smfcore.custom.luxsan.api.bean.result.BrandQtyResult
;
import
com.neotel.smfcore.custom.luxsan.api.bean.result.BrandQtyResult
;
import
com.neotel.smfcore.custom.luxsan.api.bean.result.NewLabelToCellResult
;
import
com.neotel.smfcore.custom.luxsan.api.bean.result.NewLabelToCellResult
;
import
com.neotel.smfcore.custom.luxsan.factory_c.common.util.CommonUtil
;
import
com.neotel.smfcore.custom.luxsan.factory_c.common.util.CommonUtil
;
...
@@ -171,6 +168,19 @@ public class ManualTicketTransferController {
...
@@ -171,6 +168,19 @@ public class ManualTicketTransferController {
barcode
.
setWarehouseCode
(
dstWarehouse
);
barcode
.
setWarehouseCode
(
dstWarehouse
);
int
days
=
LuxsanApi
.
getInDate
(
new
GetInDateRequest
(
CommonUtil
.
plantCode
,
barcode
.
getPartNumber
(),
barcode
.
getProvider
(),
barcode
.
getDateCode
()));
log
.
info
(
barcode
.
getBarcode
()+
"的剩余过期时间为:"
+
days
);
if
(
days
>
0
)
{
Date
expireDate
=
cn
.
hutool
.
core
.
date
.
DateUtil
.
offsetDay
(
new
Date
(),
days
);
barcode
.
setExpireDate
(
expireDate
);
}
if
(
barcode
.
getExpireDate
()
!=
null
){
if
(
System
.
currentTimeMillis
()
>
barcode
.
getExpireDate
().
getTime
())
{
throw
new
ValidateException
(
"smfcore.error.barcode.expired"
,
"物料已过期,无法入库."
);
}
}
//判断隔口能否放入
//判断隔口能否放入
if
(
boxBarcode
!=
null
)
{
if
(
boxBarcode
!=
null
)
{
...
...
编写
预览
支持
Markdown
格式
附加文件
你添加了
0
人
到此讨论。请谨慎行事。
Finish editing this message first!
Cancel
请
注册
或
登录
后发表评论