|
@@ -3,7 +3,6 @@ package com.chuanxia.mcp.service.impl;
|
|
import cn.hutool.core.collection.CollectionUtil;
|
|
import cn.hutool.core.collection.CollectionUtil;
|
|
import com.alibaba.fastjson.JSON;
|
|
import com.alibaba.fastjson.JSON;
|
|
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
|
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
|
-import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper;
|
|
|
|
import com.baomidou.mybatisplus.core.metadata.IPage;
|
|
import com.baomidou.mybatisplus.core.metadata.IPage;
|
|
import com.baomidou.mybatisplus.core.toolkit.Wrappers;
|
|
import com.baomidou.mybatisplus.core.toolkit.Wrappers;
|
|
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
|
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
|
@@ -210,7 +209,7 @@ public class CdnDoaminServiceImpl extends ServiceImpl<CdnDomainMapper, CdnDomain
|
|
m3u8 = videoM3u8s.get(0);
|
|
m3u8 = videoM3u8s.get(0);
|
|
}
|
|
}
|
|
if (!StringUtils.isBlank(type)) {
|
|
if (!StringUtils.isBlank(type)) {
|
|
- String downLoadFileUrl = address + "/api/cdnDomain/downLoadM3u8File?cdn=" + cdnDomain.getDomain() + "&id=" + m3u8.getId()+"&type=.m3u8";
|
|
|
|
|
|
+ String downLoadFileUrl = address + "/api/cdnDomain/downLoadM3u8File?cdn=" + cdnDomain.getDomain() + "&id=" + m3u8.getId() + "&type=.m3u8";
|
|
throw new ResultException(888, downLoadFileUrl);
|
|
throw new ResultException(888, downLoadFileUrl);
|
|
}
|
|
}
|
|
String tsListStr = m3u8.getTsListStr();
|
|
String tsListStr = m3u8.getTsListStr();
|
|
@@ -218,13 +217,15 @@ public class CdnDoaminServiceImpl extends ServiceImpl<CdnDomainMapper, CdnDomain
|
|
|
|
|
|
if (!StringUtils.isBlank(tsListStr)) {
|
|
if (!StringUtils.isBlank(tsListStr)) {
|
|
if (StringUtils.isBlank(tsName)) {
|
|
if (StringUtils.isBlank(tsName)) {
|
|
|
|
+ //没有文件名,说明是不规则数组,这里直接设置tsList
|
|
List<VideoTs> tsList = JSON.parseArray(tsListStr, VideoTs.class);
|
|
List<VideoTs> tsList = JSON.parseArray(tsListStr, VideoTs.class);
|
|
- //说明是有序的视频,则不需要返回tsList
|
|
|
|
m3u8.setTS_LIST(tsList);
|
|
m3u8.setTS_LIST(tsList);
|
|
}
|
|
}
|
|
String prefixPath = m3u8.getPREFIX_PATH();
|
|
String prefixPath = m3u8.getPREFIX_PATH();
|
|
if (StringUtils.isNotBlank(prefixPath)) {
|
|
if (StringUtils.isNotBlank(prefixPath)) {
|
|
m3u8.setPREFIX_PATH(cdnDomain.getDomain() + m3u8.getPREFIX_PATH());
|
|
m3u8.setPREFIX_PATH(cdnDomain.getDomain() + m3u8.getPREFIX_PATH());
|
|
|
|
+ } else {
|
|
|
|
+ m3u8.setPREFIX_PATH("");
|
|
}
|
|
}
|
|
m3u8.setTsListStr("");
|
|
m3u8.setTsListStr("");
|
|
} else {
|
|
} else {
|