From 71916e3a23b4f74e5f2705f3c1c740eff679b1bf Mon Sep 17 00:00:00 2001 From: "liang.chao" <1360241448@qq.com> Date: Tue, 10 Dec 2024 16:22:42 +0800 Subject: [PATCH] =?UTF-8?q?=E7=BB=93=E7=AE=97=E6=8A=A5=E9=94=99bug?= =?UTF-8?q?=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../material/service/impl/SltAgreementInfoServiceImpl.java | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/sgzb-modules/sgzb-material/src/main/java/com/bonus/sgzb/material/service/impl/SltAgreementInfoServiceImpl.java b/sgzb-modules/sgzb-material/src/main/java/com/bonus/sgzb/material/service/impl/SltAgreementInfoServiceImpl.java index 2686fe89..0ba34816 100644 --- a/sgzb-modules/sgzb-material/src/main/java/com/bonus/sgzb/material/service/impl/SltAgreementInfoServiceImpl.java +++ b/sgzb-modules/sgzb-material/src/main/java/com/bonus/sgzb/material/service/impl/SltAgreementInfoServiceImpl.java @@ -15,6 +15,7 @@ import com.bonus.sgzb.material.domain.TmTask; import com.bonus.sgzb.material.mapper.SltAgreementInfoMapper; import com.bonus.sgzb.material.service.SltAgreementInfoService; import com.bonus.sgzb.material.vo.GlobalContants; +import org.apache.commons.lang3.StringUtils; import org.springframework.stereotype.Service; import org.springframework.transaction.annotation.Transactional; @@ -254,10 +255,10 @@ public class SltAgreementInfoServiceImpl implements SltAgreementInfoService { loseList.addAll(oneOfList); } for (SltAgreementInfo bean : loseList) { - if (bean.getBuyPrice() == null) { + if (StringUtils.isBlank(bean.getBuyPrice())) { bean.setBuyPrice("0"); } - if (bean.getNum() == null) { + if (StringUtils.isBlank(bean.getNum())) { bean.setNum("0"); } BigDecimal buyPrice = new BigDecimal(bean.getBuyPrice());