feat: 导入sap添加I_EMPNO字段,表示创建人
This commit is contained in:
parent
c70ead664b
commit
be9702a415
|
|
@ -935,11 +935,7 @@ public class BomNewEbomParentService extends ServiceImpl<BomNewEbomParentMapper,
|
|||
sapDto.setZID(RandomUtil.randomNumbers(5));
|
||||
sapDto.setI_WERKS("1");
|
||||
sapDto.setI_STLAN("2");
|
||||
UserInfoVO userInfoVO = SpringUtil.getBean(UserInfoService.class).getUserInfoByUserCode(root.getCreatedBy());
|
||||
if (Objects.isNull(userInfoVO)) {
|
||||
throw new NflgBusinessException(STATE.BusinessError, StrUtil.format("用户[{}]不存在", root.getCreatedBy()));
|
||||
}
|
||||
sapDto.setI_EMPNO(userInfoVO.getRealName());
|
||||
sapDto.setI_EMPNO(root.getCreatedBy());
|
||||
List<T1DTO> t1s = new ArrayList<>();
|
||||
buildChildrenForSap(root, t1s);
|
||||
sapDto.setT1(t1s);
|
||||
|
|
|
|||
|
|
@ -10,7 +10,6 @@ import cn.hutool.extra.spring.SpringUtil;
|
|||
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
import com.google.common.collect.ImmutableList;
|
||||
import com.nflg.product.base.core.exception.NflgBusinessException;
|
||||
import com.nflg.product.bomnew.constant.BomConstant;
|
||||
import com.nflg.product.bomnew.constant.EBomConstant;
|
||||
import com.nflg.product.bomnew.constant.EBomSuperMaterialStatusEnum;
|
||||
|
|
@ -23,7 +22,6 @@ import com.nflg.product.bomnew.pojo.entity.BomNewMbomParentEntity;
|
|||
import com.nflg.product.bomnew.pojo.query.BomNewMbomParentQuery;
|
||||
import com.nflg.product.bomnew.pojo.vo.BomNewMbomMiddleVO;
|
||||
import com.nflg.product.bomnew.pojo.vo.OperationErrorMsgVO;
|
||||
import com.nflg.product.bomnew.pojo.vo.UserInfoVO;
|
||||
import com.nflg.product.bomnew.service.domain.MBom.IndexListTree;
|
||||
import com.nflg.product.bomnew.util.VUtils;
|
||||
import nflg.product.common.constant.STATE;
|
||||
|
|
@ -273,11 +271,7 @@ public class BomNewMbomParentService extends ServiceImpl<BomNewMbomParentMapper,
|
|||
}
|
||||
|
||||
result.setI_STLAN(BomConstant.SAP_MBOM);
|
||||
UserInfoVO userInfoVO = SpringUtil.getBean(UserInfoService.class).getUserInfoByUserCode(parentVO.getCreatedBy());
|
||||
if (Objects.isNull(userInfoVO)) {
|
||||
throw new NflgBusinessException(STATE.BusinessError, StrUtil.format("用户[{}]不存在", parentVO.getCreatedBy()));
|
||||
}
|
||||
result.setI_EMPNO(userInfoVO.getRealName());
|
||||
result.setI_EMPNO(parentVO.getCreatedBy());
|
||||
String dateYMD= DateUtil.format(new Date(),"yyyyMMdd");
|
||||
|
||||
List<BomNewMbomMiddleVO> parentList=list.stream().filter(u -> u.getBomExist().intValue()>0).collect(Collectors.toList());
|
||||
|
|
|
|||
|
|
@ -1108,11 +1108,7 @@ public class BomNewPbomParentService extends ServiceImpl<BomNewPbomParentMapper,
|
|||
sapDto.setZID(RandomUtil.randomNumbers(5));
|
||||
sapDto.setI_WERKS("1");
|
||||
sapDto.setI_STLAN("1");
|
||||
UserInfoVO userInfoVO = SpringUtil.getBean(UserInfoService.class).getUserInfoByUserCode(root.getCreatedBy());
|
||||
if (Objects.isNull(userInfoVO)) {
|
||||
throw new NflgBusinessException(STATE.BusinessError, StrUtil.format("用户[{}]不存在", root.getCreatedBy()));
|
||||
}
|
||||
sapDto.setI_EMPNO(userInfoVO.getRealName());
|
||||
sapDto.setI_EMPNO(root.getCreatedBy());
|
||||
List<T1DTO> t1s = new ArrayList<>();
|
||||
buildChildrenForSap(root, t1s);
|
||||
sapDto.setT1(t1s);
|
||||
|
|
|
|||
|
|
@ -11,7 +11,6 @@ import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
|||
import com.baomidou.mybatisplus.core.toolkit.IdWorker;
|
||||
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||
import com.nflg.product.base.core.conmon.util.SessionUtil;
|
||||
import com.nflg.product.base.core.exception.NflgBusinessException;
|
||||
import com.nflg.product.bomnew.constant.*;
|
||||
import com.nflg.product.bomnew.pojo.dto.sap.impart2.ImportSapParamDTO;
|
||||
import com.nflg.product.bomnew.pojo.dto.sap.impart2.T1DTO;
|
||||
|
|
@ -404,11 +403,7 @@ public class DQBomService {
|
|||
sapDto.setZID(RandomUtil.randomNumbers(5));
|
||||
sapDto.setI_WERKS("1");
|
||||
sapDto.setI_STLAN("1");
|
||||
UserInfoVO userInfoVO = SpringUtil.getBean(UserInfoService.class).getUserInfoByUserCode(root.getCreatedBy());
|
||||
if (Objects.isNull(userInfoVO)) {
|
||||
throw new NflgBusinessException(STATE.BusinessError, StrUtil.format("用户[{}]不存在", root.getCreatedBy()));
|
||||
}
|
||||
sapDto.setI_EMPNO(userInfoVO.getRealName());
|
||||
sapDto.setI_EMPNO(root.getCreatedBy());
|
||||
List<T1DTO> t1s = new ArrayList<>();
|
||||
String dateYMD = DateUtil.format(new Date(), "yyyyMMdd");
|
||||
datas.forEach(d -> {
|
||||
|
|
|
|||
|
|
@ -30,7 +30,6 @@ import com.nflg.product.bomnew.pojo.query.OptionalMbomMaterialListQuery;
|
|||
import com.nflg.product.bomnew.pojo.query.OptionalMbomMaterialQuery;
|
||||
import com.nflg.product.bomnew.pojo.vo.OperationErrorMsgVO;
|
||||
import com.nflg.product.bomnew.pojo.vo.OptionalMbomMaterialListVO;
|
||||
import com.nflg.product.bomnew.pojo.vo.UserInfoVO;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import nflg.product.common.constant.STATE;
|
||||
import nflg.product.common.vo.ResultVO;
|
||||
|
|
@ -134,11 +133,7 @@ public class OptionalMbomMaterialService extends ServiceImpl<OptionalMbomMateria
|
|||
result.setZID(RandomUtil.randomNumbers(5));
|
||||
result.setI_WERKS("1");
|
||||
result.setI_STLAN(BomConstant.SAP_YDBOM);
|
||||
UserInfoVO userInfoVO = SpringUtil.getBean(UserInfoService.class).getUserInfoByUserCode(entity.getCreatedBy());
|
||||
if (Objects.isNull(userInfoVO)) {
|
||||
throw new NflgBusinessException(STATE.BusinessError, StrUtil.format("用户[{}]不存在", entity.getCreatedBy()));
|
||||
}
|
||||
result.setI_EMPNO(userInfoVO.getRealName());
|
||||
result.setI_EMPNO(entity.getCreatedBy());
|
||||
|
||||
String dateYMD=DateUtil.format(new Date(),"yyyyMMdd");
|
||||
for (OptionalMbomMaterialListVO parent:
|
||||
|
|
|
|||
Loading…
Reference in New Issue