public AffairHandingContext getOne(String orderId) {
Assert.notNull(orderId,"orderId cannot null");
OrderHandingContextDO orderHandingContextDO = orderHandingContextDOMapper.selectHandingContextByOrderId(orderId, DISTRIBUTEDINDEX);
if (Objects.isNull(orderHandingContextDO)){
return null;
}
AffairHandingContext affairHandingContext = AffairHandingContextConvertor.convert(orderHandingContextDO);
//此时还需要去查询上下文详情
List<OrderHandingContextDetailDO> orderHandingContextDetailDOS = orderHandingContextDetailDOMapper.selectHandContextDetailByOrderId(orderId);
if (orderHandingContextDetailDOS.size() > 0 ){
affairHandingContext.setDetailList(orderHandingContextDetailDOS.stream().map(affairHandingContextDetailMapper::convert).collect(Collectors.toList()));
}
return affairHandingContext;
}