...
|
...
|
@@ -46,12 +46,6 @@ public class QiniuLiveRecordService { |
|
|
@Autowired
|
|
|
OrderConfigConstant orderConfigConstant;
|
|
|
|
|
|
|
|
|
|
|
|
private static boolean filterVideoValid(String videoName, Integer status) {
|
|
|
return StringUtils.isNotBlank(videoName) || 1 == status;
|
|
|
}
|
|
|
|
|
|
public void updateStatusByPersistId(String persistId, Integer code) {
|
|
|
if (Integer.valueOf(0).equals(code)) {
|
|
|
qiniuLiveRecordMapper.updateStatusByPersistId(persistId, 1); // 更新直播记录状态为已转码成功
|
...
|
...
|
@@ -101,7 +95,7 @@ public class QiniuLiveRecordService { |
|
|
LOG.info("method getAppraiseVideoUrl in qiniuLiveRecordMapper.selectByOrderCodesEx orderCodes is {}", orderCodes);
|
|
|
|
|
|
return qiniuLiveRecordMapper.selectByOrderCodesEx(orderCodes).stream()
|
|
|
.filter(item -> filterVideoValid(item.getVideoUrl(), item.getStatus()))
|
|
|
.filter(item -> QiniuLiveUrlUtil.filterVideoValid(item.getVideoUrl(), item.getStatus()))
|
|
|
.collect(Collectors.toMap(QiniuLiveRecord::getOrderCode, e -> QiniuLiveUrlUtil.makeLiveVideoUrl(e.getVideoUrl(), e.getVedioFileUrl()),
|
|
|
(o, n) -> o));
|
|
|
}
|
...
|
...
|
@@ -139,7 +133,7 @@ public class QiniuLiveRecordService { |
|
|
} else {
|
|
|
LOG.info("mthod queryOrderVideos in qiniuLiveRecordMapper.selectByProductIdEx productId is {}", productId);
|
|
|
qiNiuLiveRecords = qiniuLiveRecordMapper.selectByProductIdEx(productId).stream()
|
|
|
.filter(item -> filterVideoValid(item.getVideoUrl(), item.getStatus())).collect(Collectors.toList());
|
|
|
.filter(item -> QiniuLiveUrlUtil.filterVideoValid(item.getVideoUrl(), item.getStatus())).collect(Collectors.toList());
|
|
|
}
|
|
|
|
|
|
List<Long> orderCodeList = qiNiuLiveRecords.stream().map(QiniuLiveRecord::getOrderCode).collect(Collectors.toList());
|
...
|
...
|
|