feat: 如果物料单位为ST,则改为PC,因为导入SAP时不支持ST

This commit is contained in:
曹鹏飞 2024-05-28 14:59:15 +08:00
parent d4b75545cd
commit ec18157276
2 changed files with 8 additions and 0 deletions

View File

@ -223,6 +223,10 @@ public class EBomImportService {
dto.setRowNum(rowNum.get());
if (StrUtil.equals("ST", dto.getUnit(), true)) {
dto.setUnit("PC");
}
if (StrUtil.equals(dto.getProjectType(), BomConstant.PROJECT_TYPE_TEMPORARY, true)) {
String id = RandomUtil.randomNumbers(9);
dto.setMaterialNo(BomConstant.PROJECT_TYPE_TEMPORARY + id);

View File

@ -162,6 +162,10 @@ public class SapOpUtilService {
if (StrUtil.equals(t.getPOSTP(), "Z", true)) {
t.setPOSTP("L");
}
//如果单位是ST则改为PC
if (StrUtil.equals("ST", t.getMEINS(), true)) {
t.setMEINS("PC");
}
childMapList.add(Convert.convert(new TypeReference<Map<String, String>>() {
}, t));
});