fix(oa):修复项目更新时客户ID为0的处理逻辑

- 修复了当客户ID为0时未正确设置为null的问题- 添加了对客户ID非空的前置判断,避免空指针异常
This commit is contained in:
2025-10-22 14:42:12 +08:00
parent fe7ac6a523
commit cc7eb18025

View File

@@ -227,7 +227,7 @@ public class SysOaProjectServiceImpl implements ISysOaProjectService {
SysOaProject update = BeanUtil.toBean(bo, SysOaProject.class);
// 当 customerId 为 0 时,设置为 null
if (bo.getCustomerId() == 0) {
if (bo.getCustomerId() != null && bo.getCustomerId() == 0) {
update.setCustomerId(null);
}