|
@@ -372,10 +372,16 @@ public class AiBytedanceAdvertiserStrategyController {
|
|
|
|
|
|
@ApiOperation(value="获取行动号召", notes="获取行动号召")
|
|
@ApiOperation(value="获取行动号召", notes="获取行动号召")
|
|
@GetMapping(value = "/getAdActionText")
|
|
@GetMapping(value = "/getAdActionText")
|
|
- public Result getAdActionText(@RequestParam("accountId") String accountId,
|
|
|
|
- @RequestParam("landingType") String landingType,
|
|
|
|
|
|
+ public Result getAdActionText(@RequestParam(value = "accountId",required = false) String accountId,
|
|
|
|
+ @RequestParam(value = "landingType",required = false) String landingType,
|
|
@RequestParam(value = "advancedCreativeType",required = false) String advancedCreativeType) {
|
|
@RequestParam(value = "advancedCreativeType",required = false) String advancedCreativeType) {
|
|
try {
|
|
try {
|
|
|
|
+ if (Check.isNull(accountId)){
|
|
|
|
+ return Result.errorMsg("请选择账户。");
|
|
|
|
+ }
|
|
|
|
+ if (Check.isNull(landingType)){
|
|
|
|
+ return Result.errorMsg("投放内容不能为空");
|
|
|
|
+ }
|
|
return aiBytedanceAdvertiserStrategyService.getAdActionText(accountId,landingType,advancedCreativeType);
|
|
return aiBytedanceAdvertiserStrategyService.getAdActionText(accountId,landingType,advancedCreativeType);
|
|
}catch (Exception e){
|
|
}catch (Exception e){
|
|
log.error("获取行动号召异常",e);
|
|
log.error("获取行动号召异常",e);
|
|
@@ -383,15 +389,21 @@ public class AiBytedanceAdvertiserStrategyController {
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|
|
|
|
- @ApiOperation(value="获取行动号召", notes="获取行动号召")
|
|
|
|
|
|
+ @ApiOperation(value="获取定向包", notes="获取定向包")
|
|
@GetMapping(value = "/getAdAudiencePackage")
|
|
@GetMapping(value = "/getAdAudiencePackage")
|
|
- public Result getAdAudiencePackage(@RequestParam("accountId") String accountId,
|
|
|
|
- @RequestParam(value = "landingType") String landingType,
|
|
|
|
- @RequestParam(value = "deliveryRange",required = false) String deliveryRange) {
|
|
|
|
|
|
+ public Result getAdAudiencePackage(@RequestParam(value = "accountId",required = false) String accountId,
|
|
|
|
+ @RequestParam(value = "landingType",required = false) String landingType,
|
|
|
|
+ @RequestParam(value = "deliveryRange",required = false) String deliveryRange) {
|
|
try {
|
|
try {
|
|
|
|
+ if (Check.isNull(accountId)){
|
|
|
|
+ return Result.errorMsg("请选择账户。");
|
|
|
|
+ }
|
|
|
|
+ if (Check.isNull(landingType)){
|
|
|
|
+ return Result.errorMsg("投放内容不能为空");
|
|
|
|
+ }
|
|
return aiBytedanceAdvertiserStrategyService.getAdAudiencePackage(accountId,landingType,deliveryRange);
|
|
return aiBytedanceAdvertiserStrategyService.getAdAudiencePackage(accountId,landingType,deliveryRange);
|
|
}catch (Exception e){
|
|
}catch (Exception e){
|
|
- log.error("获取行动号召异常",e);
|
|
|
|
|
|
+ log.error("获取定向包异常",e);
|
|
return Result.error("请求失败,请联系开发人员!");
|
|
return Result.error("请求失败,请联系开发人员!");
|
|
}
|
|
}
|
|
}
|
|
}
|