批次规则bug修改

This commit is contained in:
秦鸿展
2026-01-29 17:26:05 +08:00
parent e0d3e40847
commit 43aec4ac0d
11 changed files with 967 additions and 54 deletions
@@ -120,7 +120,11 @@ public class MaterialBaseInfoApplicationService {
throw new ServiceException("获取货主信息失败");
}
UserPo userPo = JSON.parseObject(JSONObject.toJSONString(ajaxResult.get("data")), UserPo.class);
materialBaseInfoDO.setShipperName(userPo.getUserName());
// 如果原始shipperName不为空,保留原始值(导入或手动输入时应该保留完整名称)
// 只有在原始shipperName为空时,才使用查询到的userName
if (materialBaseInfoDO.getShipperName() == null || materialBaseInfoDO.getShipperName().trim().isEmpty()) {
materialBaseInfoDO.setShipperName(userPo.getUserName());
}
}
public List<MaterialStockInfoVo> getMaterialStockList(String shipperName, String materialName,