修改配置

This commit is contained in:
huangyujie 2026-03-25 11:17:49 +08:00
parent 11799310ca
commit 3976c9f6ad
2 changed files with 4 additions and 4 deletions

View File

@ -126,7 +126,7 @@ public class ExternalPddPublishService {
if (props.isAutoFetchCatRule() && !catFetched) { if (props.isAutoFetchCatRule() && !catFetched) {
try { try {
JSONObject body = new JSONObject(); JSONObject body = new JSONObject();
body.put("cat_id", String.valueOf(catId)); body.put("cat_id", catId);
String raw = pddPopClient.invoke(gateway, cred.getAppKey(), cred.getAppSecret(), cred.getAccessToken(), String raw = pddPopClient.invoke(gateway, cred.getAppKey(), cred.getAppSecret(), cred.getAccessToken(),
"pdd.goods.cat.rule.get", JSON.toJSONString(body)); "pdd.goods.cat.rule.get", JSON.toJSONString(body));
catRuleSnippet = PddOpenApiSupport.snippet(raw, 2000); catRuleSnippet = PddOpenApiSupport.snippet(raw, 2000);

View File

@ -76,8 +76,8 @@ public class PddCatRuleSpecAutoResolver {
throw new IllegalArgumentException("cat_id 必须为正数,当前=" + catId); throw new IllegalArgumentException("cat_id 必须为正数,当前=" + catId);
} }
JSONObject p = new JSONObject(); JSONObject p = new JSONObject();
// POP 文档示例一致param_json cat_id 使用字符串避免网关报cat_id 不能为空 // POP 文档 cat_id 类型为 LONG部分网关对字符串 cat_id 解析失败会报请求参数不能为空cat_id
p.put("cat_id", String.valueOf(catId)); p.put("cat_id", catId);
return popClient.invoke( return popClient.invoke(
gatewayUrl, gatewayUrl,
cred.getAppKey(), cred.getAppKey(),
@ -106,7 +106,7 @@ public class PddCatRuleSpecAutoResolver {
throw new IllegalStateException("无法解析 SKU 规格名outSkuId=" + row.getOuterErpSkuId()); throw new IllegalStateException("无法解析 SKU 规格名outSkuId=" + row.getOuterErpSkuId());
} }
JSONObject p = new JSONObject(); JSONObject p = new JSONObject();
p.put("cat_id", String.valueOf(catId)); p.put("cat_id", catId);
p.put("parent_spec_id", parentSpecId); p.put("parent_spec_id", parentSpecId);
p.put("spec_name", specName.trim()); p.put("spec_name", specName.trim());