丽知:供应商同步修改。
This commit is contained in:
parent
bc7556e1ee
commit
1a01a66203
|
@ -280,9 +280,9 @@ public class SupplierPluginInitializer extends PluginBaseEntity {
|
|||
String def1 = null;
|
||||
String url = null;
|
||||
String custName = k;//客商名称
|
||||
try {
|
||||
//查询u8c客商基本档案
|
||||
BdCubasdocEntity bdCubasdocEntity = queryU8CEntityUtil.queryBdCubasdocByName(custName);
|
||||
try {
|
||||
if (bdCubasdocEntity == null) {
|
||||
//新增
|
||||
url = OverallConstant.getOverAllValue("custdocSaveCode");
|
||||
|
@ -295,6 +295,9 @@ public class SupplierPluginInitializer extends PluginBaseEntity {
|
|||
//拼接def1,如果存在则跳过转换,如果不存在则新增
|
||||
// def1 = v.stream().map(OfsSupplierDto::getBizCode).collect(Collectors.joining(","));
|
||||
List<String> def1_new = v.stream().map(OfsSupplierDto::getBizCode).collect(Collectors.toList());
|
||||
if(bdCubasdocEntity==null){
|
||||
def1 = String.join(",", def1_new);
|
||||
}else {
|
||||
String def1_old = bdCubasdocEntity.getDef1();
|
||||
String[] def1_split_old = def1_old.split(",");
|
||||
// 将数组转换为列表
|
||||
|
@ -307,6 +310,8 @@ public class SupplierPluginInitializer extends PluginBaseEntity {
|
|||
}
|
||||
}
|
||||
def1 = String.join(",", def1_all);
|
||||
}
|
||||
|
||||
|
||||
CustdocEntityDto parentvo = new CustdocEntityDto();
|
||||
CustdocRequestVo CustdocEntityDto = new CustdocRequestVo();
|
||||
|
@ -351,7 +356,11 @@ public class SupplierPluginInitializer extends PluginBaseEntity {
|
|||
integrationTaskLivingDetailsEntity.setRootAppPk(ofsSupplierDto.getBizCode() + "_" + ofsSupplierDto.getLastUpdated());
|
||||
integrationTaskLivingDetailsEntity.setRootAppBill(ofsSupplierDto.getBizCode());
|
||||
integrationTaskLivingDetailsEntity.setPluginId(getPluginId());
|
||||
if(bdCubasdocEntity!=null){
|
||||
integrationTaskLivingDetailsEntity.setNewSystemNumber(bdCubasdocEntity.getCustcode());
|
||||
}else {
|
||||
integrationTaskLivingDetailsEntity.setNewSystemNumber(res_custdoc.getParentvo().getCustcode());
|
||||
}
|
||||
integrationTaskLivingDetailsEntity.setNewSystemPrimary(res_custdoc.getParentvo().getPk_cubasdoc());
|
||||
saveOrUpdateBusinessLogUtil.saveOrUpdate(integrationTaskLivingDetailsEntity);
|
||||
}
|
||||
|
@ -369,6 +378,9 @@ public class SupplierPluginInitializer extends PluginBaseEntity {
|
|||
integrationTaskLivingDetailsEntity.setRootAppPk(ofsSupplierDto.getBizCode() + "_" + ofsSupplierDto.getLastUpdated());
|
||||
integrationTaskLivingDetailsEntity.setRootAppBill(ofsSupplierDto.getBizCode());
|
||||
integrationTaskLivingDetailsEntity.setPluginId(getPluginId());
|
||||
if(bdCubasdocEntity!=null){
|
||||
integrationTaskLivingDetailsEntity.setNewSystemNumber(bdCubasdocEntity.getCustcode());
|
||||
}
|
||||
saveOrUpdateBusinessLogUtil.saveOrUpdate(integrationTaskLivingDetailsEntity);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue