Commit 9d26c074 by 徐康

特制属性

parent ea0a418d
......@@ -2768,9 +2768,6 @@ public class OrderSdkAdapter {
extInfo.setThirdCensusCategoryId(product.getClassificationId());
extInfo.setThirdCensusCategoryName(product.getClassificationName());
}
if(CollectionUtils.isNotEmpty(product.getSpecialCodes())) {
extInfo.setSpecialCodes(product.getSpecialCodes());
}
if(CollectionUtils.isNotEmpty(product.getSpecialAttrs())) {
extInfo.setSpecialAttrs(product.getSpecialAttrs());
}
......
......@@ -177,7 +177,5 @@ public class CreateOrderProductRequest extends BaseConfig {
private String taxId;
private List<String> specialCodes;
private List<OrderSpecialExtraAttrRequest> specialAttrs;
}
......@@ -71,7 +71,5 @@ public class OrderProductAddInfoDto extends BaseConfig {
private String taxId;
private List<String> specialCodes;
private List<OrderSpecialExtraAttrRequest> specialAttrs;
}
......@@ -11,6 +11,10 @@ import java.util.List;
@NoArgsConstructor
public class OrderSpecialExtraAttrRequest {
/**
* 属性id
*/
private String attributeId;
/**
* 属性名
*/
private String attributeName;
......
......@@ -2292,12 +2292,9 @@ public class OrderAdapter {
createOrderProductDemoDto.setClassificationId(cartGoodsDetailDto.getClassificationId());
createOrderProductDemoDto.setClassificationName(cartGoodsDetailDto.getClassificationName());
if(CollectionUtils.isNotEmpty(cartGoodsDetailDto.getSpecialExtra())) {
// createOrderProductDemoDto.setSpecialCodes(cartGoodsDetailDto.getSpecialExtra().stream().map(ShoppingCartGoodsDto.CartGoodsDetailDto.CartGoodsExtra::getSpecialCode).collect(Collectors.toList()));
createOrderProductDemoDto.setSpecialAttrs(new ArrayList<>());
createOrderProductDemoDto.setSpecialCodes(new ArrayList<>());
cartGoodsDetailDto.getSpecialExtra().stream().forEach(o -> {
createOrderProductDemoDto.getSpecialAttrs().add(new OrderSpecialExtraAttrRequest(o.getAttributeName(), o.getSpecialCode()));
createOrderProductDemoDto.getSpecialCodes().add(o.getSpecialCode());
createOrderProductDemoDto.getSpecialAttrs().add(new OrderSpecialExtraAttrRequest(o.getAttributeId(), o.getAttributeName(), o.getSpecialCode()));
});
}
return createOrderProductDemoDto;
......
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