Browse Source

修改素材上新逻辑bug

syh 4 năm trước cách đây
mục cha
commit
1430f65e61

+ 2 - 2
module-kuaishou/src/main/java/cn/com/ctop/kuaishou/modules/ai/service/impl/AiKuaishouNewCreateCampaignServiceImpl.java

@@ -116,11 +116,11 @@ public class AiKuaishouNewCreateCampaignServiceImpl implements IAiKuaishouNewCre
 
         //3、在“上新”计划中新增广告组,一个素材搭配5张封面,组成一个广告组
         String timestamp = DateUtils.formatDate(new Date(),"yyyyMMddHHmmss");
-        String unitName = "户14-上下滑&信息流" + "-素材上新-"+ "剪辑-低价-低价包邮-活动-年龄18岁以上-单出价-"+ timestamp;
+        String unitNamePrefix = "户14-上下滑&信息流" + "-素材上新-"+ "剪辑-低价-低价包邮-活动-年龄18岁以上-单出价-"+ timestamp;
         int unitCnt = 0;
         for(KuaiShouVideoGet videoItem: newVideos){
             unitCnt ++;
-            unitName = unitName + "-" + unitCnt;
+            String unitName = unitNamePrefix + "-" + unitCnt;
             JSONObject unitParams = createUnitParams(token, newCampaignId, targetTemplate, unitName);
             Map<String, Object> unitCreateResult = kuaishouInterfaceService.adUnitCreate(token.getAccessToken(), token.getAccountId(), unitParams,1);
             Integer unitCode = (Integer) unitCreateResult.get("code");