|
@@ -324,6 +324,11 @@ public class ByteDanceAdvertiserDataServiceImpl implements IByteDanceAdvertiserD
|
|
//操作状态
|
|
//操作状态
|
|
String optStatus = detail.getString("opt_status");
|
|
String optStatus = detail.getString("opt_status");
|
|
if ("AD_STATUS_ENABLE".equals(optStatus) && !"AD_STATUS_DISABLE".equals(status)) { // 操作状态为‘启用’,广告计划投放状态 非‘暂停’
|
|
if ("AD_STATUS_ENABLE".equals(optStatus) && !"AD_STATUS_DISABLE".equals(status)) { // 操作状态为‘启用’,广告计划投放状态 非‘暂停’
|
|
|
|
+ Map<String, String> textMap = new HashMap<>();
|
|
|
|
+ List<JSONObject> lists = creativeMapper.getBytedanceOcpxTypeList();
|
|
|
|
+ for (JSONObject da : lists) {
|
|
|
|
+ textMap.put(da.getString("ocpxActionType"), da.getString("ocpxActionName"));
|
|
|
|
+ }
|
|
String msgType = "";
|
|
String msgType = "";
|
|
String msgBid = "";
|
|
String msgBid = "";
|
|
|
|
|
|
@@ -338,12 +343,13 @@ public class ByteDanceAdvertiserDataServiceImpl implements IByteDanceAdvertiserD
|
|
//通过转化目标没有查询到转化出价,判断为转化目标不一致,触发关停
|
|
//通过转化目标没有查询到转化出价,判断为转化目标不一致,触发关停
|
|
if (Check.isNull(ocpxBid)) {
|
|
if (Check.isNull(ocpxBid)) {
|
|
typeFalg = false;
|
|
typeFalg = false;
|
|
- msgType = "转化:" + ocpxActionType;
|
|
|
|
|
|
+ String msg = Check.isNull(textMap.get(ocpxActionType)) ? ocpxActionType : textMap.get(ocpxActionType);
|
|
|
|
+ msgType = "计划转化:" + msg;
|
|
} else {
|
|
} else {
|
|
//未查询到转化出价,说明出价不一致,触发出价关停。
|
|
//未查询到转化出价,说明出价不一致,触发出价关停。
|
|
if (Check.isNull(cpaBid)) {
|
|
if (Check.isNull(cpaBid)) {
|
|
bidFalg = false;
|
|
bidFalg = false;
|
|
- msgBid = "出价为空";
|
|
|
|
|
|
+ msgBid = "计划出价为空";
|
|
} else {
|
|
} else {
|
|
BigDecimal cpa = new BigDecimal(cpaBid);
|
|
BigDecimal cpa = new BigDecimal(cpaBid);
|
|
BigDecimal ocpx = new BigDecimal(ocpxBid);
|
|
BigDecimal ocpx = new BigDecimal(ocpxBid);
|
|
@@ -362,19 +368,20 @@ public class ByteDanceAdvertiserDataServiceImpl implements IByteDanceAdvertiserD
|
|
if (Check.isNull(deepBid)) {
|
|
if (Check.isNull(deepBid)) {
|
|
//通过key未获取值,说明不包含该目标,进行关停
|
|
//通过key未获取值,说明不包含该目标,进行关停
|
|
typeFalg = false;
|
|
typeFalg = false;
|
|
- msgType = "(深度)转化:" + deepConversionType;
|
|
|
|
|
|
+ String msg = Check.isNull(textMap.get(deepConversionType)) ? deepConversionType : textMap.get(deepConversionType);
|
|
|
|
+ msgType = "计划(深度)转化:" + msg;
|
|
} else {
|
|
} else {
|
|
//未查询到转化出价,说明出价不一致,触发出价关停。
|
|
//未查询到转化出价,说明出价不一致,触发出价关停。
|
|
if (Check.isNull(deepConversionBid)) {
|
|
if (Check.isNull(deepConversionBid)) {
|
|
bidFalg = false;
|
|
bidFalg = false;
|
|
- msgBid = "(深度)出价为空";
|
|
|
|
|
|
+ msgBid = "计划(深度)出价为空";
|
|
} else {
|
|
} else {
|
|
BigDecimal cpa = new BigDecimal(deepConversionBid);
|
|
BigDecimal cpa = new BigDecimal(deepConversionBid);
|
|
BigDecimal ocpx = new BigDecimal(deepBid);
|
|
BigDecimal ocpx = new BigDecimal(deepBid);
|
|
if (cpa.compareTo(ocpx) == 1) {
|
|
if (cpa.compareTo(ocpx) == 1) {
|
|
//计划转化出价cpa 大于 项目设置最大转化出价,则关停
|
|
//计划转化出价cpa 大于 项目设置最大转化出价,则关停
|
|
bidFalg = false;
|
|
bidFalg = false;
|
|
- msgBid = "(深度)计划出价:" + cpaBid;
|
|
|
|
|
|
+ msgBid = "计划(深度)出价:" + deepConversionBid;
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
@@ -418,7 +425,8 @@ public class ByteDanceAdvertiserDataServiceImpl implements IByteDanceAdvertiserD
|
|
.append("下的账户:").append(advertiserId + ",").append("<br/>")
|
|
.append("下的账户:").append(advertiserId + ",").append("<br/>")
|
|
.append("广告计划id:").append(unitId).append("<br/>")
|
|
.append("广告计划id:").append(unitId).append("<br/>")
|
|
.append("广告计划名称:").append(unit_name).append("<br/>")
|
|
.append("广告计划名称:").append(unit_name).append("<br/>")
|
|
- .append("出价方式设置错误。").append(msgType).append("<br/>")
|
|
|
|
|
|
+ .append("出价方式设置错误。").append("<br/>")
|
|
|
|
+ .append(msgType).append("<br/>")
|
|
.append("系统已执行暂停此计划,请您及时查看!");
|
|
.append("系统已执行暂停此计划,请您及时查看!");
|
|
return text.toString();
|
|
return text.toString();
|
|
}
|
|
}
|
|
@@ -431,7 +439,8 @@ public class ByteDanceAdvertiserDataServiceImpl implements IByteDanceAdvertiserD
|
|
.append("下的账户:").append(accountId + ",").append("<br/>")
|
|
.append("下的账户:").append(accountId + ",").append("<br/>")
|
|
.append("广告计划id为:").append(planId).append("<br/>")
|
|
.append("广告计划id为:").append(planId).append("<br/>")
|
|
.append("广告计划名称为:").append(planName).append("<br/>")
|
|
.append("广告计划名称为:").append(planName).append("<br/>")
|
|
- .append("出价设置过高。").append(msgBid).append("<br/>")
|
|
|
|
|
|
+ .append("出价设置过高。").append("<br/>")
|
|
|
|
+ .append(msgBid).append("<br/>")
|
|
.append("系统已执行暂停此计划,请您及时查看!");
|
|
.append("系统已执行暂停此计划,请您及时查看!");
|
|
return text.toString();
|
|
return text.toString();
|
|
}
|
|
}
|