|
|
@ -844,8 +844,8 @@ public class MoveService {
|
|
|
|
|
|
|
|
|
|
|
|
public JSONArray buildSpecPrice(JSONObject productDetailBase,
|
|
|
|
public JSONArray buildSpecPrice(JSONObject productDetailBase,
|
|
|
|
MoveShopSettingBO condition,
|
|
|
|
MoveShopSettingBO condition,
|
|
|
|
StrObjMap colorSpecArrCalc,
|
|
|
|
List<String> colorSpecArrCalc,
|
|
|
|
StrObjMap sizeSpecArrCalc,
|
|
|
|
List<String> sizeSpecArrCalc,
|
|
|
|
MoveProductPublishQueueBO queueMsg,
|
|
|
|
MoveProductPublishQueueBO queueMsg,
|
|
|
|
StrObjMap skuPresellChildSkuDetail, Boolean filterBanWord, List<String> foundBanWordList) {
|
|
|
|
StrObjMap skuPresellChildSkuDetail, Boolean filterBanWord, List<String> foundBanWordList) {
|
|
|
|
JSONObject skuList = productDetailBase.getJSONObject("skuList");
|
|
|
|
JSONObject skuList = productDetailBase.getJSONObject("skuList");
|
|
|
@ -910,21 +910,21 @@ public class MoveService {
|
|
|
|
// return $this->appendSkuPresellChildSkuDetail($skuPresellChildSkuDetail, $specPrices, $deliveryDelayDay);
|
|
|
|
// return $this->appendSkuPresellChildSkuDetail($skuPresellChildSkuDetail, $specPrices, $deliveryDelayDay);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
private StrObjMap getSaleAttrName(String skuKey, StrObjMap colorSpecArrCalc, StrObjMap sizeSpecArrCalc, Boolean filterBanWord, List<String> foundBanWordList) {
|
|
|
|
private StrObjMap getSaleAttrName(String skuKey, List<String> colorSpecArrCalc, List<String> sizeSpecArrCalc, Boolean filterBanWord, List<String> foundBanWordList) {
|
|
|
|
String[] arr = skuKey.split(MoveConst.skuKeyInterval);
|
|
|
|
String[] arr = skuKey.split(MoveConst.skuKeyInterval);
|
|
|
|
String colorName = arr.length >= 1 ? arr[0] : "";
|
|
|
|
String colorName = arr.length >= 1 ? arr[0] : "";
|
|
|
|
String sizeName = arr.length >= 2 ? arr[1] : "";
|
|
|
|
String sizeName = arr.length >= 2 ? arr[1] : "";
|
|
|
|
String newColorName = replaceIllegalChars(colorName, filterBanWord, foundBanWordList);
|
|
|
|
String newColorName = replaceIllegalChars(colorName, filterBanWord, foundBanWordList);
|
|
|
|
String newSizeName = replaceIllegalChars(sizeName, filterBanWord, foundBanWordList);
|
|
|
|
String newSizeName = replaceIllegalChars(sizeName, filterBanWord, foundBanWordList);
|
|
|
|
Boolean needSkip = false;
|
|
|
|
Boolean needSkip = false;
|
|
|
|
if (colorName.length() > 0 && ObjectUtil.isNotEmpty(colorSpecArrCalc) && (newColorName.length() == 0 || !colorSpecArrCalc.containsKey(newColorName))) {
|
|
|
|
if (colorName.length() > 0 && ObjectUtil.isNotEmpty(colorSpecArrCalc) && (newColorName.length() == 0 || !colorSpecArrCalc.contains(newColorName))) {
|
|
|
|
needSkip = true;
|
|
|
|
needSkip = true;
|
|
|
|
} else if (sizeName.length() > 0 && ObjectUtil.isNotEmpty(sizeSpecArrCalc) && (newSizeName.length() == 0 || !sizeSpecArrCalc.containsKey(newSizeName))) {
|
|
|
|
} else if (sizeName.length() > 0 && ObjectUtil.isNotEmpty(sizeSpecArrCalc) && (newSizeName.length() == 0 || !sizeSpecArrCalc.contains(newSizeName))) {
|
|
|
|
log.info(String.format("getSaleAttrName skip sizeName[%s] sizeSpecArrCalc[%s]", sizeName, sizeSpecArrCalc.toString()));
|
|
|
|
log.info(String.format("getSaleAttrName skip sizeName[%s] sizeSpecArrCalc[%s]", sizeName, sizeSpecArrCalc.toString()));
|
|
|
|
needSkip = true;
|
|
|
|
needSkip = true;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
StrObjMap diffMap = (StrObjMap) (colorSpecArrCalc.clone());
|
|
|
|
List<String> diffMap = new ArrayList<>(colorSpecArrCalc);
|
|
|
|
diffMap.remove("默认");
|
|
|
|
diffMap.remove("默认");
|
|
|
|
if (ObjectUtil.isEmpty(diffMap) && ObjectUtil.isEmpty(sizeSpecArrCalc) && StrUtil.isEmpty(newColorName) && StrUtil.isEmpty(newSizeName)) {
|
|
|
|
if (ObjectUtil.isEmpty(diffMap) && ObjectUtil.isEmpty(sizeSpecArrCalc) && StrUtil.isEmpty(newColorName) && StrUtil.isEmpty(newSizeName)) {
|
|
|
|
newColorName = "默认";
|
|
|
|
newColorName = "默认";
|
|
|
|