|
@@ -1,5 +1,6 @@
|
|
|
package com.fs.app.controller;
|
|
|
|
|
|
+import cn.hutool.json.JSONUtil;
|
|
|
import com.fs.app.annotation.Login;
|
|
|
import com.fs.app.config.ImageStorageConfig;
|
|
|
import com.fs.common.core.domain.R;
|
|
@@ -7,6 +8,7 @@ import com.fs.common.core.domain.ResponseResult;
|
|
|
import com.fs.common.utils.StringUtils;
|
|
|
import com.fs.company.domain.CompanyUser;
|
|
|
import com.fs.company.service.ICompanyUserService;
|
|
|
+import com.fs.course.config.CourseConfig;
|
|
|
import com.fs.course.domain.FsUserCoursePeriod;
|
|
|
import com.fs.course.param.FsCourseLinkCreateParam;
|
|
|
import com.fs.course.param.FsWatchCourseTimeParam;
|
|
@@ -17,11 +19,13 @@ import com.fs.course.service.IFsCourseLinkService;
|
|
|
import com.fs.course.service.IFsUserCoursePeriodService;
|
|
|
import com.fs.course.service.IFsUserCourseService;
|
|
|
import com.fs.course.service.IFsUserCourseVideoService;
|
|
|
+import com.fs.course.service.impl.FsUserCourseServiceImpl;
|
|
|
import com.fs.course.vo.FsUserCourseParticipationRecordVO;
|
|
|
import com.fs.course.vo.newfs.FsUserCourseListVO;
|
|
|
import com.fs.course.vo.newfs.FsUserCourseVideoDetailsVO;
|
|
|
import com.fs.course.vo.newfs.FsUserCourseVideoPageListVO;
|
|
|
import com.fs.course.vo.newfs.FsUserVideoListVO;
|
|
|
+import com.fs.system.service.ISysConfigService;
|
|
|
import com.github.pagehelper.PageHelper;
|
|
|
import com.github.pagehelper.PageInfo;
|
|
|
import io.swagger.annotations.Api;
|
|
@@ -51,6 +55,8 @@ public class FsUserCourseVideoController extends AppBaseController {
|
|
|
|
|
|
@Autowired
|
|
|
private IFsUserCourseService fsUserCourseService;
|
|
|
+ @Autowired
|
|
|
+ private ISysConfigService configService;
|
|
|
|
|
|
@Autowired
|
|
|
private IFsCourseLinkService courseLinkService;
|
|
@@ -158,8 +164,13 @@ public class FsUserCourseVideoController extends AppBaseController {
|
|
|
|
|
|
R courseSortLink = fsUserCourseService.createCourseSortLink(fsCourseLinkCreateParam);
|
|
|
String link = courseSortLink.get("link").toString();
|
|
|
- R r = courseLinkService.getRealLink(link);
|
|
|
- String realLink = r.get("realLink").toString();
|
|
|
+// R r = courseLinkService.getRealLink(link);
|
|
|
+// String realLink = r.get("realLink").toString();
|
|
|
+ String json = configService.selectConfigByKey("course.config");
|
|
|
+ CourseConfig config = JSONUtil.toBean(json, CourseConfig.class);
|
|
|
+ String realLink = config.getRealLinkDomainName() + FsUserCourseServiceImpl.shortLink + link;
|
|
|
+
|
|
|
+ log.info("二维码生成地址:{}", realLink);
|
|
|
try {
|
|
|
String path = imageConfig.getServerPath();
|
|
|
log.info("获取的logo图片路径,fileUrl:{}", path);
|