diff --git a/stdiet-custom/src/main/java/com/stdiet/custom/service/impl/SysCustomerHealthyServiceImpl.java b/stdiet-custom/src/main/java/com/stdiet/custom/service/impl/SysCustomerHealthyServiceImpl.java index 66619c53b..b311864d1 100644 --- a/stdiet-custom/src/main/java/com/stdiet/custom/service/impl/SysCustomerHealthyServiceImpl.java +++ b/stdiet-custom/src/main/java/com/stdiet/custom/service/impl/SysCustomerHealthyServiceImpl.java @@ -112,7 +112,7 @@ public class SysCustomerHealthyServiceImpl implements ISysCustomerHealthyService @Override public int updateSysCustomerHealthy(SysCustomerHealthy sysCustomerHealthy){ int rows = sysCustomerHealthyMapper.updateSysCustomerHealthy(sysCustomerHealthy); - if(rows > 0){ + if(rows > 0 && sysCustomerHealthy.getHealthyExtend() != null && sysCustomerHealthy.getHealthyExtend().getId() != null){ rows = sysCustomerHealthyExtendedMapper.updateSysCustomerHealthyExtended(sysCustomerHealthy.getHealthyExtend()); } return rows;