|
|
@@ -119,11 +119,15 @@ public class TencentClient {
|
|
|
UserAction action = buildUserAction(bid, payment, actionType, eventTimeMs);
|
|
|
|
|
|
long actionSetId = getUserActionSetId(platform);
|
|
|
- // account_id: 从监测链接传入
|
|
|
+ // account_id: 优先顶层字段,兜底从 mediaParams 读取(兼容旧数据)
|
|
|
long finalAccountId = 0;
|
|
|
- if (bid.getAccountId() != null && !bid.getAccountId().isBlank()) {
|
|
|
+ String accountIdStr = bid.getAccountId();
|
|
|
+ if (accountIdStr == null || accountIdStr.isBlank()) {
|
|
|
+ accountIdStr = bid.getMediaParams() != null ? bid.getMediaParams().get("account_id") : null;
|
|
|
+ }
|
|
|
+ if (accountIdStr != null && !accountIdStr.isBlank()) {
|
|
|
try {
|
|
|
- finalAccountId = Long.parseLong(bid.getAccountId());
|
|
|
+ finalAccountId = Long.parseLong(accountIdStr);
|
|
|
} catch (NumberFormatException ignored) {}
|
|
|
}
|
|
|
if (finalAccountId == 0) {
|