Browse Source

评价助手上架逻辑调整

pjzs_starttask_update
shanji 1 year ago
parent
commit
6ba068832d
  1. 7
      BBWY.Server.Business/PlatformSDK/JDBusiness.cs

7
BBWY.Server.Business/PlatformSDK/JDBusiness.cs

@ -1058,7 +1058,6 @@ namespace BBWY.Server.Business
}
else if (res.Json["jingdong_category_read_findSaleAttrTemplates_responce"]["categoryAttrTemplates"]["templateType"].ToString() == "2")
{
isStruts = true;
var tempDataJarray = JArray.Parse(res.Json["jingdong_category_read_findSaleAttrTemplates_responce"]["categoryAttrTemplates"]["templateData"].ToString());
var tempDataJToken = tempDataJarray.FirstOrDefault(j => j.Value<string>("valueRules").Contains("颜色") ||
j.Value<string>("valueRules").Contains("款式") ||
@ -1066,9 +1065,12 @@ namespace BBWY.Server.Business
if (tempDataJToken == null)
{
RollBackWhenStartPromotionError(request.AppKey, request.AppSecret, request.AppToken, giftSkuIdList, request.MainProductSpu, request.FullTitle, brandName, haveGiftTemplateSku);
throw new BusinessException("缺少结构化属性-颜色");
throw new BusinessException("缺少必要的结构化属性");
}
attrId = tempDataJToken.Value<string>("attrId");
if (tempDataJToken.Value<string>("type") == "1")
{
isStruts = true;
var tempDataValuesJToken = JObject.Parse(tempDataJToken["valueRules"].ToString());
var tempDataValues_Level1_JToken = tempDataValuesJToken["items"][0];
if (tempDataValuesJToken["items"].Count() == 3 &&
@ -1162,6 +1164,7 @@ namespace BBWY.Server.Business
throw new BusinessException($"不支持的properties.id.type {tempDataValues_Level1_JToken["properties"]["id"]["type"]} 或取其分支情况");
}
}
}
#endregion
#region 组装上架/改名/设置细节图参数

Loading…
Cancel
Save