|
@@ -183,13 +183,15 @@ public class MatchVideoServiceImpl implements MatchVideoService {
|
|
|
}
|
|
|
String ghId = matchVideo.getGhId();
|
|
|
String response = matchVideo.getResponse();
|
|
|
- List<Long> videoIds = JSONArray.parseArray(response, Long.class);
|
|
|
- if (CollectionUtils.isNotEmpty(videoIds)) {
|
|
|
+ JSONArray jsonArray = JSONArray.parseArray(response);
|
|
|
+
|
|
|
+ if (CollectionUtils.isNotEmpty(jsonArray)) {
|
|
|
List<GetOffVideoArticle> addList = new ArrayList<>();
|
|
|
- for (Long videoId : videoIds) {
|
|
|
+ for (int i = 0; i < jsonArray.size(); i++) {
|
|
|
+ JSONObject jsonObject = jsonArray.getJSONObject(i);
|
|
|
GetOffVideoArticle getOffVideoArticle = new GetOffVideoArticle();
|
|
|
getOffVideoArticle.setTraceId(getOffVideosParam.getTraceId());
|
|
|
- getOffVideoArticle.setVideoId(videoId);
|
|
|
+ getOffVideoArticle.setVideoId(jsonObject.getLong("videoId"));
|
|
|
getOffVideoArticle.setVideoStatus(1);
|
|
|
getOffVideoArticle.setPublishTime(System.currentTimeMillis() / 1000);
|
|
|
addList.add(getOffVideoArticle);
|