Commit df0bc8d0 authored by yanghao's avatar yanghao

fix: 在pda中 入仓纪录明细信息需要返回品牌名和产品名

parent 1ce554dc
package cn.iocoder.yudao.module.order.service.orderWarehouseIn;
import cn.hutool.core.bean.BeanUtil;
import cn.hutool.core.collection.CollUtil;
import cn.hutool.core.collection.CollectionUtil;
import cn.hutool.core.date.DateTime;
import cn.hutool.core.date.DateUtil;
......@@ -4717,6 +4718,27 @@ public class OrderWarehouseInServiceImpl extends AbstractService<OrderWarehouseI
}).collect(Collectors.joining(","));
orderWarehouseInBackItemDo.setOrderLocationStr4Merge(orderLocationStr4Merge);
// 设置明细产品名称
List<OrderWarehouseInDetailsVO> orderWarehouseInDetailsVOList = orderWarehouseInBackItemDo.getOrderWarehouseInDetailsVOList();
if (CollUtil.isNotEmpty(orderWarehouseInDetailsVOList)) {
for (OrderWarehouseInDetailsVO orderWarehouseInDetailsVO : orderWarehouseInDetailsVOList) {
if (orderWarehouseInDetailsVO.getProdId() != null) {
ProductDO productDO = productService.getProduct(orderWarehouseInDetailsVO.getProdId());
if (productDO != null) {
orderWarehouseInDetailsVO.setProdTitleZh(productDO.getTitleZh());
orderWarehouseInDetailsVO.setProdTitleEn(productDO.getTitleEn());
}
}
// 品牌名称
if (orderWarehouseInDetailsVO.getBrand() != null) {
ProductBrankDO productBrank = productBrankService.getProductBrank(orderWarehouseInDetailsVO.getBrand());
if (productBrank != null) {
orderWarehouseInDetailsVO.setBrandName(I18nMessage.getLang() == 0 ? productBrank.getTitleZh() : productBrank.getTitleEn());
}
}
}
}
return orderWarehouseInBackItemDo;
}).collect(Collectors.toList());
......
......@@ -77,4 +77,17 @@ public class OrderWarehouseInDetailsVO {
@ApiModelProperty(value = "材质")
private String material;
@ApiModelProperty(value = "产品中文标题")
private String prodTitleZh;
@ApiModelProperty(value = "产品英文标题")
private String prodTitleEn;
@ApiModelProperty(value = "品牌名称")
private String brandName;
}
......@@ -149,7 +149,7 @@ Content-Type: application/json
#### 获取订单的入仓纪录信息
GET {{baseUrl}}/order/order-warehouse-in/get-order-warehouse-in?orderId=19419
GET {{baseUrl}}/order/order-warehouse-in/get-order-warehouse-in?orderId=83641
Authorization: Bearer {{token}}
tenant-id: {{adminTenentId}}
Content-Type: application/json
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment