Authored by caoyan

添加尺码

  1 +package com.yohoufo.dal.product;
  2 +
  3 +import java.util.List;
  4 +
  5 +import org.apache.ibatis.annotations.Param;
  6 +
  7 +import com.yohoufo.dal.product.model.SizeAddRecord;
  8 +
  9 +public interface SizeAddRecordMapper {
  10 +
  11 + int insertBatch(@Param("list") List<SizeAddRecord> list);
  12 +
  13 +}
@@ -3,6 +3,8 @@ package com.yohoufo.dal.product; @@ -3,6 +3,8 @@ package com.yohoufo.dal.product;
3 import com.yohoufo.dal.product.model.Size; 3 import com.yohoufo.dal.product.model.Size;
4 import java.util.List; 4 import java.util.List;
5 5
  6 +import org.apache.ibatis.annotations.Param;
  7 +
6 public interface SizeMapper { 8 public interface SizeMapper {
7 9
8 int insert(Size record); 10 int insert(Size record);
@@ -14,4 +16,11 @@ public interface SizeMapper { @@ -14,4 +16,11 @@ public interface SizeMapper {
14 int updateByPrimaryKey(Size record); 16 int updateByPrimaryKey(Size record);
15 17
16 List<Size> selectByIds(List<Integer> ids); 18 List<Size> selectByIds(List<Integer> ids);
  19 +
  20 + /**
  21 + * 根据品类查询所有的尺码
  22 + * @param sortId
  23 + * @return
  24 + */
  25 + List<Size> selectAllSizeBySortIdList(@Param("sortIdList") List<Integer> sortIdList);
17 } 26 }
  1 +package com.yohoufo.dal.product.model;
  2 +
  3 +public class SizeAddRecord {
  4 + private Integer id;
  5 +
  6 + private Integer productId;
  7 +
  8 + private Integer goodsId;
  9 +
  10 + private Integer sizeId;
  11 +
  12 + private Integer applyUid;
  13 +
  14 + private Integer createTime;
  15 +
  16 + private Integer auditTime;
  17 +
  18 + private Integer auditUid;
  19 +
  20 + private Integer status;
  21 +
  22 + public Integer getId() {
  23 + return id;
  24 + }
  25 +
  26 + public void setId(Integer id) {
  27 + this.id = id;
  28 + }
  29 +
  30 + public Integer getProductId() {
  31 + return productId;
  32 + }
  33 +
  34 + public void setProductId(Integer productId) {
  35 + this.productId = productId;
  36 + }
  37 +
  38 + public Integer getGoodsId() {
  39 + return goodsId;
  40 + }
  41 +
  42 + public void setGoodsId(Integer goodsId) {
  43 + this.goodsId = goodsId;
  44 + }
  45 +
  46 + public Integer getSizeId() {
  47 + return sizeId;
  48 + }
  49 +
  50 + public void setSizeId(Integer sizeId) {
  51 + this.sizeId = sizeId;
  52 + }
  53 +
  54 + public Integer getApplyUid() {
  55 + return applyUid;
  56 + }
  57 +
  58 + public void setApplyUid(Integer applyUid) {
  59 + this.applyUid = applyUid;
  60 + }
  61 +
  62 + public Integer getCreateTime() {
  63 + return createTime;
  64 + }
  65 +
  66 + public void setCreateTime(Integer createTime) {
  67 + this.createTime = createTime;
  68 + }
  69 +
  70 + public Integer getAuditTime() {
  71 + return auditTime;
  72 + }
  73 +
  74 + public void setAuditTime(Integer auditTime) {
  75 + this.auditTime = auditTime;
  76 + }
  77 +
  78 + public Integer getAuditUid() {
  79 + return auditUid;
  80 + }
  81 +
  82 + public void setAuditUid(Integer auditUid) {
  83 + this.auditUid = auditUid;
  84 + }
  85 +
  86 + public Integer getStatus() {
  87 + return status;
  88 + }
  89 +
  90 + public void setStatus(Integer status) {
  91 + this.status = status;
  92 + }
  93 +
  94 +}
  1 +<?xml version="1.0" encoding="UTF-8"?>
  2 +<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
  3 +<mapper namespace="com.yohoufo.dal.product.SizeAddRecordMapper">
  4 + <resultMap id="BaseResultMap" type="com.yohoufo.dal.product.model.SizeAddRecord">
  5 + <id column="id" jdbcType="INTEGER" property="id" />
  6 + <result column="product_id" jdbcType="INTEGER" property="productId" />
  7 + <result column="goodsId" jdbcType="INTEGER" property="goodsId" />
  8 + <result column="size_id" jdbcType="INTEGER" property="sizeId" />
  9 + <result column="apply_id" jdbcType="INTEGER" property="applyId" />
  10 + <result column="create_time" jdbcType="INTEGER" property="createTime" />
  11 + <result column="audit_time" jdbcType="INTEGER" property="auditTime" />
  12 + <result column="audit_uid" jdbcType="INTEGER" property="auditUid" />
  13 + <result column="status" jdbcType="INTEGER" property="status" />
  14 + </resultMap>
  15 +
  16 + <insert id="insertBatch">
  17 + insert into size_add_record(
  18 + product_id,
  19 + goods_id,
  20 + size_id,
  21 + apply_uid,
  22 + create_time)values
  23 + <foreach collection="list" separator="," item="item">
  24 + (#{item.productId},#{item.goodsId},#{item.sizeId},#{item.applyUid},#{item.createTime})
  25 + </foreach>
  26 + </insert>
  27 +</mapper>
@@ -45,4 +45,16 @@ @@ -45,4 +45,16 @@
45 </foreach> 45 </foreach>
46 order by order_by 46 order by order_by
47 </select> 47 </select>
  48 +
  49 + <select id="selectAllSizeBySortIdList" resultMap="BaseResultMap">
  50 + select s.id, s.size_name,ss.order_by
  51 + from size s inner join sort_size ss on s.id = ss.size_id where ss.del = 0
  52 + <if test="sortIdList != null and sortIdList.size() >0 ">
  53 + and ss.sort_id in
  54 + <foreach item="item" index="index" collection="sortIdList" open="(" separator="," close=")">
  55 + #{item}
  56 + </foreach>
  57 + </if>
  58 + order by ss.order_by, ss.id
  59 + </select>
48 </mapper> 60 </mapper>
@@ -723,5 +723,26 @@ public class ProductController { @@ -723,5 +723,26 @@ public class ProductController {
723 ProductDetailResp resp = productService.queryProductInStockNewBriefById(productId); 723 ProductDetailResp resp = productService.queryProductInStockNewBriefById(productId);
724 return new ApiResponse.ApiResponseBuilder().data(resp).code(200).message("product data").build(); 724 return new ApiResponse.ApiResponseBuilder().data(resp).code(200).message("product data").build();
725 } 725 }
  726 +
  727 + @ApiOperation(name = "ufo.product.addSize", desc = "添加尺码")
  728 + @RequestMapping(params = "method=ufo.product.addSize")
  729 + public ApiResponse addSize(
  730 + @RequestParam(value = "product_id") Integer productId,
  731 + @RequestParam(value = "goods_id") Integer goodsId,
  732 + @RequestParam(value = "size_ids") String sizeIds,
  733 + @RequestParam(value = "uid") Integer uid) {
  734 +
  735 + if (null == productId || null == goodsId || StringUtils.isBlank(sizeIds) || null == uid) {
  736 + LOG.info("in method=ufo.product.addSize product_id or goods_id or size_ids or uid Is Null or empty");
  737 + return new ApiResponse(400, "product_id or goods_id or size_ids or uid Is Null or empty", null);
  738 + }
  739 + LOG.info("in method=ufo.product.addSize goodsId is {},size_ids={}", goodsId, sizeIds);
  740 + int result = productService.addSizeForGoods(productId, goodsId, sizeIds, uid);
  741 + if(result > 0) {
  742 + return new ApiResponse.ApiResponseBuilder().code(200).message("addSize success").build();
  743 + }else {
  744 + return new ApiResponse.ApiResponseBuilder().code(500).message("addSize fail!").build();
  745 + }
  746 + }
726 747
727 } 748 }
@@ -104,4 +104,6 @@ public interface ProductService { @@ -104,4 +104,6 @@ public interface ProductService {
104 SecondHandProductResp querySecondHandProductData(Integer skup); 104 SecondHandProductResp querySecondHandProductData(Integer skup);
105 105
106 ProductDetailResp queryProductInStockNewBriefById(Integer productId); 106 ProductDetailResp queryProductInStockNewBriefById(Integer productId);
  107 +
  108 + int addSizeForGoods(Integer productId, Integer goodsId, String sizeIds, Integer applyUid);
107 } 109 }
1 package com.yohoufo.product.service.impl; 1 package com.yohoufo.product.service.impl;
2 2
3 import java.math.BigDecimal; 3 import java.math.BigDecimal;
4 -import java.util.*; 4 +import java.util.ArrayList;
  5 +import java.util.Arrays;
  6 +import java.util.Collection;
  7 +import java.util.Collections;
  8 +import java.util.Comparator;
  9 +import java.util.HashMap;
  10 +import java.util.List;
  11 +import java.util.Map;
5 import java.util.Map.Entry; 12 import java.util.Map.Entry;
  13 +import java.util.Objects;
  14 +import java.util.UUID;
6 import java.util.function.BinaryOperator; 15 import java.util.function.BinaryOperator;
7 import java.util.function.Function; 16 import java.util.function.Function;
8 import java.util.stream.Collectors; 17 import java.util.stream.Collectors;
9 18
10 -import com.alibaba.fastjson.JSON;  
11 -import com.alibaba.fastjson.JSONArray;  
12 -import com.yoho.tools.common.beans.ApiResponse;  
13 -import com.yohobuy.ufo.model.GoodsBO;  
14 -import com.yohobuy.ufo.model.GoodsImageBO;  
15 -import com.yohobuy.ufo.model.GoodsSize;  
16 -import com.yohobuy.ufo.model.ProductInfo;  
17 -import com.yohobuy.ufo.model.request.StoragePriceBo;  
18 -import com.yohobuy.ufo.model.response.ProductDetailResp;  
19 -import com.yohobuy.ufo.model.response.StorageInfoResp;  
20 -import com.yohoufo.common.caller.UfoServiceCaller;  
21 -import com.yohoufo.common.helper.ImageUrlAssist;  
22 -import com.yohoufo.dal.product.*;  
23 -import com.yohoufo.dal.product.model.*;  
24 -import com.yohoufo.product.model.*;  
25 -import com.yohoufo.product.response.*;  
26 import org.apache.commons.lang.ArrayUtils; 19 import org.apache.commons.lang.ArrayUtils;
27 import org.apache.commons.lang3.StringUtils; 20 import org.apache.commons.lang3.StringUtils;
28 import org.apache.commons.lang3.tuple.Pair; 21 import org.apache.commons.lang3.tuple.Pair;
@@ -32,14 +25,74 @@ import org.springframework.beans.factory.annotation.Autowired; @@ -32,14 +25,74 @@ import org.springframework.beans.factory.annotation.Autowired;
32 import org.springframework.stereotype.Service; 25 import org.springframework.stereotype.Service;
33 import org.springframework.util.CollectionUtils; 26 import org.springframework.util.CollectionUtils;
34 27
  28 +import com.alibaba.fastjson.JSONArray;
35 import com.alibaba.fastjson.JSONObject; 29 import com.alibaba.fastjson.JSONObject;
36 import com.google.common.collect.Lists; 30 import com.google.common.collect.Lists;
37 import com.yoho.core.common.helpers.ImagesHelper; 31 import com.yoho.core.common.helpers.ImagesHelper;
  32 +import com.yoho.core.config.ConfigReader;
38 import com.yoho.core.dal.datasource.annotation.Database; 33 import com.yoho.core.dal.datasource.annotation.Database;
39 import com.yoho.error.exception.ServiceException; 34 import com.yoho.error.exception.ServiceException;
  35 +import com.yoho.tools.common.beans.ApiResponse;
  36 +import com.yohobuy.ufo.model.GoodsBO;
  37 +import com.yohobuy.ufo.model.GoodsImageBO;
  38 +import com.yohobuy.ufo.model.GoodsSize;
  39 +import com.yohobuy.ufo.model.ProductInfo;
  40 +import com.yohobuy.ufo.model.request.StoragePriceBo;
  41 +import com.yohobuy.ufo.model.response.ProductDetailResp;
  42 +import com.yohobuy.ufo.model.response.StorageDataResp;
  43 +import com.yohobuy.ufo.model.response.StorageInfoResp;
  44 +import com.yohoufo.common.caller.UfoServiceCaller;
  45 +import com.yohoufo.common.helper.ImageUrlAssist;
40 import com.yohoufo.common.utils.DateUtil; 46 import com.yohoufo.common.utils.DateUtil;
41 import com.yohoufo.common.utils.UfoStringUtils; 47 import com.yohoufo.common.utils.UfoStringUtils;
42 -import com.yohobuy.ufo.model.response.StorageDataResp; 48 +import com.yohoufo.dal.product.BrandMapper;
  49 +import com.yohoufo.dal.product.BrandSeriesMapper;
  50 +import com.yohoufo.dal.product.GoodsImagesMapper;
  51 +import com.yohoufo.dal.product.GoodsMapper;
  52 +import com.yohoufo.dal.product.PriceTrendDayMapper;
  53 +import com.yohoufo.dal.product.PriceTrendMonthMapper;
  54 +import com.yohoufo.dal.product.ProductLimitSaleMapper;
  55 +import com.yohoufo.dal.product.ProductMapper;
  56 +import com.yohoufo.dal.product.ProductSalesMapper;
  57 +import com.yohoufo.dal.product.ProductSortMapper;
  58 +import com.yohoufo.dal.product.SaleCategoryMapper;
  59 +import com.yohoufo.dal.product.SecondhandFlawMapper;
  60 +import com.yohoufo.dal.product.SecondhandImagesMapper;
  61 +import com.yohoufo.dal.product.SecondhandInfoMapper;
  62 +import com.yohoufo.dal.product.SizeAddRecordMapper;
  63 +import com.yohoufo.dal.product.SizeMapper;
  64 +import com.yohoufo.dal.product.StorageMapper;
  65 +import com.yohoufo.dal.product.StoragePriceMapper;
  66 +import com.yohoufo.dal.product.model.Brand;
  67 +import com.yohoufo.dal.product.model.BrandSeries;
  68 +import com.yohoufo.dal.product.model.Goods;
  69 +import com.yohoufo.dal.product.model.GoodsImages;
  70 +import com.yohoufo.dal.product.model.PriceTrendModel;
  71 +import com.yohoufo.dal.product.model.Product;
  72 +import com.yohoufo.dal.product.model.ProductLimitSale;
  73 +import com.yohoufo.dal.product.model.ProductSales;
  74 +import com.yohoufo.dal.product.model.ProductSort;
  75 +import com.yohoufo.dal.product.model.SaleCategory;
  76 +import com.yohoufo.dal.product.model.SecondhandFlaw;
  77 +import com.yohoufo.dal.product.model.SecondhandImages;
  78 +import com.yohoufo.dal.product.model.SecondhandInfo;
  79 +import com.yohoufo.dal.product.model.Size;
  80 +import com.yohoufo.dal.product.model.SizeAddRecord;
  81 +import com.yohoufo.dal.product.model.Storage;
  82 +import com.yohoufo.dal.product.model.StoragePrice;
  83 +import com.yohoufo.product.model.PriceTrendBO;
  84 +import com.yohoufo.product.model.ProductSeriesTemplate;
  85 +import com.yohoufo.product.model.ProductSortTemplate;
  86 +import com.yohoufo.product.model.SkupDetailForScreenInfo;
  87 +import com.yohoufo.product.model.SkupInfo;
  88 +import com.yohoufo.product.model.SkusBO;
  89 +import com.yohoufo.product.response.ProductSeriesTemplateResp;
  90 +import com.yohoufo.product.response.ProductSimpleResp;
  91 +import com.yohoufo.product.response.ProductSortTemplateResp;
  92 +import com.yohoufo.product.response.SaleCategoryBo;
  93 +import com.yohoufo.product.response.SecondHandProductResp;
  94 +import com.yohoufo.product.response.SkupDetailForScreenResp;
  95 +import com.yohoufo.product.response.StorageLeastPriceResp;
43 import com.yohoufo.product.service.ProductSearchService; 96 import com.yohoufo.product.service.ProductSearchService;
44 import com.yohoufo.product.service.ProductService; 97 import com.yohoufo.product.service.ProductService;
45 98
@@ -80,9 +133,6 @@ public class ProductServiceImpl implements ProductService { @@ -80,9 +133,6 @@ public class ProductServiceImpl implements ProductService {
80 private ProductSearchService productSearchService; 133 private ProductSearchService productSearchService;
81 134
82 @Autowired 135 @Autowired
83 - private PriceTrendSixtyDayMapper priceTrendSixtyDayMapper;  
84 -  
85 - @Autowired  
86 private PriceTrendMonthMapper priceTrendMonthMapper; 136 private PriceTrendMonthMapper priceTrendMonthMapper;
87 137
88 @Autowired 138 @Autowired
@@ -108,7 +158,16 @@ public class ProductServiceImpl implements ProductService { @@ -108,7 +158,16 @@ public class ProductServiceImpl implements ProductService {
108 158
109 @Autowired 159 @Autowired
110 private UfoServiceCaller ufoServiceCaller; 160 private UfoServiceCaller ufoServiceCaller;
111 - 161 +
  162 + @Autowired
  163 + private ProductSortMapper productSortMapper;
  164 +
  165 + @Autowired
  166 + private ConfigReader configReader;
  167 +
  168 + @Autowired
  169 + private SizeAddRecordMapper sizeAddRecordMapper;
  170 +
112 @Override 171 @Override
113 public ProductDetailResp queryProductDetailById(Integer productId) { 172 public ProductDetailResp queryProductDetailById(Integer productId) {
114 ProductDetailResp productDetailResp = new ProductDetailResp(); 173 ProductDetailResp productDetailResp = new ProductDetailResp();
@@ -151,6 +210,11 @@ public class ProductServiceImpl implements ProductService { @@ -151,6 +210,11 @@ public class ProductServiceImpl implements ProductService {
151 productInfo.setSecondHandLeastPrice(secondHandLeastPrice); 210 productInfo.setSecondHandLeastPrice(secondHandLeastPrice);
152 } 211 }
153 goodsSizes.sort(Comparator.comparing(GoodsSize::getOrderBy)); 212 goodsSizes.sort(Comparator.comparing(GoodsSize::getOrderBy));
  213 + List<JSONObject> otherAddSizeList = getOtherSizeList(product.getMaxSortId(), product.getMidSortId(), goodsBOList);
  214 + if(!CollectionUtils.isEmpty(otherAddSizeList)) {
  215 + goodsBO.setCanAddSize(true);
  216 + goodsBO.setOtherSizeList(otherAddSizeList);
  217 + }
154 } 218 }
155 } 219 }
156 productInfo.setGoodsList(goodsBOList); 220 productInfo.setGoodsList(goodsBOList);
@@ -159,6 +223,76 @@ public class ProductServiceImpl implements ProductService { @@ -159,6 +223,76 @@ public class ProductServiceImpl implements ProductService {
159 223
160 return productDetailResp; 224 return productDetailResp;
161 } 225 }
  226 +
  227 + private List<JSONObject> getOtherSizeList(Integer maxSortId, Integer midSortId, List<GoodsBO> goodsBOList) {
  228 + List<JSONObject> result = Lists.newArrayList();
  229 + String configMaxSortIds = configReader.getString("ufo.product.addSizeSortId", "");
  230 + if(StringUtils.isEmpty(configMaxSortIds)) {
  231 + return result;
  232 + }
  233 +
  234 + List<Integer> configSortList = Lists.newArrayList();
  235 + String[] configSortArr = configMaxSortIds.split(",");
  236 + for(int i=0; i<configSortArr.length; i++) {
  237 + configSortList.add(Integer.parseInt(configSortArr[i]));
  238 + }
  239 +
  240 + //如果没有配置这个品类,则不可以添加尺码
  241 + if(!configSortList.contains(maxSortId)) {
  242 + return result;
  243 + }
  244 +
  245 + List<Size> sizeList = getAllSizeBySortId(midSortId);
  246 + if(CollectionUtils.isEmpty(sizeList)) {
  247 + return result;
  248 + }
  249 +
  250 + List<Integer> sizeIdList = sizeList.stream().map(Size::getId).filter(Objects::nonNull).collect(Collectors.toList());
  251 + if(!CollectionUtils.isEmpty(goodsBOList)) {
  252 + List<GoodsSize> goodsSizes = goodsBOList.get(0).getSizeList();
  253 + if(!CollectionUtils.isEmpty(goodsSizes)) {
  254 + List<Integer> goodsSizeIdList = goodsSizes.stream().map(GoodsSize::getSizeId).filter(Objects::nonNull).collect(Collectors.toList());
  255 + sizeIdList.removeAll(goodsSizeIdList);
  256 + }
  257 + }
  258 +
  259 + if(CollectionUtils.isEmpty(sizeIdList)) {
  260 + return result;
  261 + }
  262 +
  263 + Map<Integer, Size> sizeMap = sizeList.stream().collect(Collectors.toMap(Size::getId, s->s));
  264 + List<Size> resultSizeList = Lists.newArrayList();
  265 +
  266 + //排序
  267 + for(Integer sizeId : sizeIdList) {
  268 + resultSizeList.add(sizeMap.get(sizeId));
  269 + }
  270 + resultSizeList.sort(Comparator.comparing(Size::getOrderBy));
  271 +
  272 + JSONObject jsonObject;
  273 + for(Size item : resultSizeList) {
  274 + jsonObject = new JSONObject();
  275 + jsonObject.put("id", item.getId());
  276 + jsonObject.put("text", item.getSizeName());
  277 + result.add(jsonObject);
  278 + }
  279 +
  280 + return result;
  281 + }
  282 +
  283 + private List<Size> getAllSizeBySortId(Integer sortId) {
  284 + ProductSort sort = productSortMapper.selectByPrimaryKey(sortId);
  285 + List<Size> sizes = Lists.newArrayList();
  286 + if (sort != null) {
  287 + List<Integer> idList = new ArrayList<>();
  288 + idList.add(sortId);
  289 + if (sort.getParentId() != null && sort.getParentId() > 0) {
  290 + idList.add(sort.getParentId());
  291 + }
  292 + sizes = sizeMapper.selectAllSizeBySortIdList(idList);
  293 + }
  294 + return sizes;
  295 + }
162 296
163 @Override 297 @Override
164 public StorageLeastPriceResp queryStorageLeastPrice(Integer storageId) { 298 public StorageLeastPriceResp queryStorageLeastPrice(Integer storageId) {
@@ -1475,6 +1609,45 @@ public class ProductServiceImpl implements ProductService { @@ -1475,6 +1609,45 @@ public class ProductServiceImpl implements ProductService {
1475 } 1609 }
1476 return productDetailResp; 1610 return productDetailResp;
1477 } 1611 }
  1612 +
  1613 + public int addSizeForGoods(Integer productId, Integer goodsId, String sizeIds, Integer applyUid) {
  1614 + Product product = productMapper.selectByPrimaryKey(productId);
  1615 + if(null == product) {
  1616 + throw new ServiceException(400, "productId不存在");
  1617 + }
  1618 +
  1619 + Goods goods = goodsMapper.selectByPrimaryKey(goodsId);
  1620 + if(null == goods || !goods.getProductId().equals(productId)) {
  1621 + throw new ServiceException(400, "goodsId不存在");
  1622 + }
  1623 +
  1624 + //校验sizetId
  1625 + String[] sizeIdArr = sizeIds.split(",");
  1626 + List<SizeAddRecord> recordList = Lists.newArrayList();
  1627 +
  1628 + //goodsId现对应的尺码
  1629 + List<Storage> storageList = storageMapper.selectByGoodsId(goodsId);
  1630 + List<Integer> existSizeIdList = storageList.stream().map(Storage::getSizeId).collect(Collectors.toList());
  1631 + List<Size> sizeList = sizeMapper.selectByIds(existSizeIdList);
  1632 + Map<Integer, String> sizeIdNameMap = sizeList.stream().collect(Collectors.toMap(Size::getId, Size::getSizeName));
  1633 + for(int i=0; i<sizeIdArr.length; i++) {
  1634 + Integer sizeId = Integer.parseInt(sizeIdArr[i]);
  1635 + if(existSizeIdList.contains(sizeId)) {
  1636 + throw new ServiceException(400, "尺码" + sizeIdNameMap.get(sizeId) + "已存在,不需要添加,请重新选择");
  1637 + }
  1638 +
  1639 + SizeAddRecord record = new SizeAddRecord();
  1640 + record.setProductId(productId);
  1641 + record.setGoodsId(goodsId);
  1642 + record.setSizeId(sizeId);
  1643 + record.setApplyUid(applyUid);
  1644 + record.setCreateTime(DateUtil.getCurrentTimeSecond());
  1645 + recordList.add(record);
  1646 + }
  1647 +
  1648 + //添加尺码审核记录
  1649 + return sizeAddRecordMapper.insertBatch(recordList);
  1650 + }
1478 1651
1479 private String getGoodsDeafultImage(Integer goodsId) { 1652 private String getGoodsDeafultImage(Integer goodsId) {
1480 List<GoodsImages> goodsImages = goodsImagesMapper.selectByGoodsId(goodsId); 1653 List<GoodsImages> goodsImages = goodsImagesMapper.selectByGoodsId(goodsId);
@@ -119,7 +119,8 @@ yoho.message.controller.url=http://message-controller.yohoops.org/yoho-message-c @@ -119,7 +119,8 @@ yoho.message.controller.url=http://message-controller.yohoops.org/yoho-message-c
119 yoho.reviewed.controller.url=http://172.16.6.54:8063/reviewed 119 yoho.reviewed.controller.url=http://172.16.6.54:8063/reviewed
120 120
121 #rabbit address for transaction compensate 121 #rabbit address for transaction compensate
122 -rabbit_host=192.168.104.199:30005 122 +#rabbit_host=192.168.104.199:30005
  123 +rabbit_host=192.168.102.211:5672
123 rabbit_user=yoho 124 rabbit_user=yoho
124 rabbit_password=yoho 125 rabbit_password=yoho
125 126
@@ -143,4 +144,6 @@ ip.port.uic.server = java-yoho-uic.test3.ingress.dev.yohocorp.com @@ -143,4 +144,6 @@ ip.port.uic.server = java-yoho-uic.test3.ingress.dev.yohocorp.com
143 144
144 ufo.nfc.syncBlockChain.url=http://192.168.102.49:3030/api/addItem 145 ufo.nfc.syncBlockChain.url=http://192.168.102.49:3030/api/addItem
145 146
146 -ufo.invite.productSortLimit=16,20,40  
  147 +ufo.invite.productSortLimit=16,20,40
  148 +
  149 +ufo.product.addSizeSortId=40
@@ -45,6 +45,7 @@ datasources: @@ -45,6 +45,7 @@ datasources:
45 - com.yohoufo.dal.product.SecondhandFlawMapper 45 - com.yohoufo.dal.product.SecondhandFlawMapper
46 - com.yohoufo.dal.product.SecondhandImagesMapper 46 - com.yohoufo.dal.product.SecondhandImagesMapper
47 - com.yohoufo.dal.product.SecondhandInfoMapper 47 - com.yohoufo.dal.product.SecondhandInfoMapper
  48 + - com.yohoufo.dal.product.SizeAddRecordMapper
48 49
49 50
50 ufo_order: 51 ufo_order:
@@ -114,4 +114,6 @@ offline.store.seller=${offline.store.seller} @@ -114,4 +114,6 @@ offline.store.seller=${offline.store.seller}
114 114
115 ip.port.uic.server = ${ip.port.uic.server} 115 ip.port.uic.server = ${ip.port.uic.server}
116 116
117 -ufo.nfc.syncBlockChain.url=${ufo.nfc.syncBlockChain.url}  
  117 +ufo.nfc.syncBlockChain.url=${ufo.nfc.syncBlockChain.url}
  118 +
  119 +ufo.product.addSizeSortId=${ufo.product.addSizeSortId}
@@ -45,6 +45,7 @@ datasources: @@ -45,6 +45,7 @@ datasources:
45 - com.yohoufo.dal.product.SecondhandFlawMapper 45 - com.yohoufo.dal.product.SecondhandFlawMapper
46 - com.yohoufo.dal.product.SecondhandImagesMapper 46 - com.yohoufo.dal.product.SecondhandImagesMapper
47 - com.yohoufo.dal.product.SecondhandInfoMapper 47 - com.yohoufo.dal.product.SecondhandInfoMapper
  48 + - com.yohoufo.dal.product.SizeAddRecordMapper
48 49
49 ufo_order: 50 ufo_order:
50 servers: 51 servers: