From a759f5fd41414651325494926583843568bac334 Mon Sep 17 00:00:00 2001 From: admin <15939171744@163.com> Date: 星期二, 04 六月 2024 20:42:47 +0800 Subject: [PATCH] - --- jcdm-main/src/main/java/com/jcdm/main/om/productionOrde/service/impl/OmProductionOrdeInfoServiceImpl.java | 20 +++++++++++++++++++- 1 files changed, 19 insertions(+), 1 deletions(-) diff --git a/jcdm-main/src/main/java/com/jcdm/main/om/productionOrde/service/impl/OmProductionOrdeInfoServiceImpl.java b/jcdm-main/src/main/java/com/jcdm/main/om/productionOrde/service/impl/OmProductionOrdeInfoServiceImpl.java index be96501..b8b1408 100644 --- a/jcdm-main/src/main/java/com/jcdm/main/om/productionOrde/service/impl/OmProductionOrdeInfoServiceImpl.java +++ b/jcdm-main/src/main/java/com/jcdm/main/om/productionOrde/service/impl/OmProductionOrdeInfoServiceImpl.java @@ -3,6 +3,7 @@ import java.util.List; import java.util.stream.Collectors; +import cn.hutool.core.util.ObjectUtil; import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; import com.jcdm.common.core.domain.AjaxResult; @@ -154,6 +155,11 @@ @Override public AjaxResult trolleyYardBinDing(OmProductionOrdeInfo omProductionOrdeInfo) { + OmProductionOrdeInfo clearTrolleyYard = omProductionOrdeInfoService.getOne(new LambdaQueryWrapper<OmProductionOrdeInfo>().eq(OmProductionOrdeInfo::getTrolleyYard, omProductionOrdeInfo.getTrolleyYard())); + if(clearTrolleyYard!=null){ + clearTrolleyYard.setTrolleyYard(""); + omProductionOrdeInfoService.saveOrUpdate(clearTrolleyYard); + } OmProductionOrdeInfo one = omProductionOrdeInfoService.getOne(new LambdaQueryWrapper<OmProductionOrdeInfo>().eq(OmProductionOrdeInfo::getProductNum, omProductionOrdeInfo.getProductNum())); one.setTrolleyYard(omProductionOrdeInfo.getTrolleyYard()); omProductionOrdeInfoService.saveOrUpdate(one); @@ -168,7 +174,19 @@ @Override public AjaxResult findBytrolleyYardGetOne(OmProductionOrdeInfo omProductionOrdeInfo) { + String str = ""; OmProductionOrdeInfo one = omProductionOrdeInfoService.getOne(new LambdaQueryWrapper<OmProductionOrdeInfo>().eq(OmProductionOrdeInfo::getTrolleyYard, omProductionOrdeInfo.getTrolleyYard())); - return AjaxResult.success(one.getProductNum()); + if(one == null){ + str = "2"; + }else { + str = one.getProductNum(); + } + return AjaxResult.success(str); + } + + @Override + public List<OmProductionOrdeInfo> checkCarCode(OmProductionOrdeInfo omProductionOrdeInfo) { + List<OmProductionOrdeInfo> list = omProductionOrdeInfoService.list(new LambdaQueryWrapper<OmProductionOrdeInfo>().eq(OmProductionOrdeInfo::getProductNum, omProductionOrdeInfo.getProductNum()).isNotNull(OmProductionOrdeInfo::getTrolleyYard)); + return list; } } -- Gitblit v1.9.3