|
@@ -202,20 +202,24 @@ public class ByteDanceVideoInfoController {
|
|
|
if (!isValidToken) {
|
|
|
return new CallbackResponse(new BaseResponse(400, "invalid token"), 0);
|
|
|
}
|
|
|
- System.out.println("----------------------byte格式:"+AuthTokenUtil.readAsBytes(cacher));;
|
|
|
- String s = new String(AuthTokenUtil.readAsBytes(cacher));
|
|
|
- System.out.println("-------------内容" + s);
|
|
|
JSONObject result = (JSONObject) JSONObject.parse(new String(AuthTokenUtil.readAsBytes(cacher)));
|
|
|
- log.info("结果:" + result);
|
|
|
- /* if (!Check.isNull(result)) {
|
|
|
- JSONObject content = result.getJSONObject("data").getJSONObject("content");
|
|
|
- if (!Check.isNull(content)) {
|
|
|
- Long agentId = content.getLong("agent_id");
|
|
|
- JSONArray illegalMaterialIds = content.getJSONArray("illegal_material_ids");//违规素材集合
|
|
|
- Long promotionId = content.getLong("promotion_id");//计划id
|
|
|
- byteDanceVideoInfoService.getIllegalVideosPushInfo(agentId, illegalMaterialIds, promotionId);
|
|
|
+ log.info("转译结果:" + result);
|
|
|
+ if (!Check.isNull(result)) {
|
|
|
+ JSONObject data = result.getJSONObject("data");
|
|
|
+ if (!Check.isNull(data)) {
|
|
|
+ JSONObject content = data.getJSONObject("content");
|
|
|
+ if (!Check.isNull(content)) {
|
|
|
+ Long agentId = content.getLong("agent_id");
|
|
|
+ JSONArray illegalMaterialIds = content.getJSONArray("illegal_material_ids");//违规素材集合
|
|
|
+ Long promotionId = content.getLong("promotion_id");//计划id
|
|
|
+ byteDanceVideoInfoService.getIllegalVideosPushInfo(agentId, illegalMaterialIds, promotionId);
|
|
|
+ } else {
|
|
|
+ log.error("content数据为空");
|
|
|
+ }
|
|
|
+ } else {
|
|
|
+ log.error("data数据为空");
|
|
|
}
|
|
|
- }*/
|
|
|
+ }
|
|
|
} catch (IOException e) {
|
|
|
e.printStackTrace();
|
|
|
}
|