丽知:存货基本档案默认成套件为true

This commit is contained in:
zhengyf 2024-09-03 16:25:27 +08:00
parent 6ffaffa70d
commit 235d5cb1e9
1 changed files with 46 additions and 44 deletions

View File

@ -239,7 +239,6 @@ public class SKUPluginInitializer extends PluginBaseEntity {
* 过滤成功日志
* rootAppPk
* [code]_[lastUpdated]
*
* @param ofsskuList
* @return
*/
@ -323,6 +322,9 @@ public class SKUPluginInitializer extends PluginBaseEntity {
//memo 备注
parentvo.setMemo(sku.getRemark());
//setpartsflag 成套件默认都是true
parentvo.setSetpartsflag("true");
invbasdoc.setParentvo(parentvo);
//子表,暂时没有要传的值
String jsonStr = JSONUtil.toJsonStr(invbasdoc);
@ -421,7 +423,6 @@ public class SKUPluginInitializer extends PluginBaseEntity {
/**
* 按code分组并按lastUpdated排序
*
* @param ofsskuList
* @return
*/
@ -429,11 +430,13 @@ public class SKUPluginInitializer extends PluginBaseEntity {
List<OFSSKUSearchResponse.OFSSKU> sortSkus=new ArrayList<>();
//根据code进行分组
Map<String, List<OFSSKUSearchResponse.OFSSKU>> collectMapByCode = ofsskuList.stream().collect(Collectors.groupingBy(OFSSKUSearchResponse.OFSSKU::getCode));
Map<String, List<OFSSKUSearchResponse.OFSSKU>> collectMapByCode =
ofsskuList.stream().collect(Collectors.groupingBy(OFSSKUSearchResponse.OFSSKU::getCode));
collectMapByCode.forEach((k,v)->{
//降序排序 (从新到旧),根据最后修改时间倒排
List<OFSSKUSearchResponse.OFSSKU> sorted = v.stream().sorted(Comparator.comparing(OFSSKUSearchResponse.OFSSKU::getLastUpdated).reversed()).collect(Collectors.toList());
List<OFSSKUSearchResponse.OFSSKU> sorted =
v.stream().sorted(Comparator.comparing(OFSSKUSearchResponse.OFSSKU::getLastUpdated).reversed()).collect(Collectors.toList());
//排除status==0的
for (int i = 0; i < sorted.size(); i++) {
@ -493,7 +496,6 @@ public class SKUPluginInitializer extends PluginBaseEntity {
}
return all;
}
private InvBasDocVO resultDataHandle(String resultData) {
try {
if (resultData != null && !"".equals(resultData)) {