ct пре 14 часа
родитељ
комит
a99fb59933
31 измењених фајлова са 1927 додато и 6 уклоњено
  1. 48 0
      fs-service/src/main/java/com/fs/course/domain/FsCollection.java
  2. 30 0
      fs-service/src/main/java/com/fs/course/domain/FsUserCollectionFavorite.java
  3. 34 0
      fs-service/src/main/java/com/fs/course/domain/FsVideoCollection.java
  4. 39 0
      fs-service/src/main/java/com/fs/course/dto/VideoCollectionDTO.java
  5. 69 0
      fs-service/src/main/java/com/fs/course/mapper/FsCollectionMapper.java
  6. 72 0
      fs-service/src/main/java/com/fs/course/mapper/FsUserCollectionFavoriteMapper.java
  7. 87 0
      fs-service/src/main/java/com/fs/course/mapper/FsVideoCollectionMapper.java
  8. 10 0
      fs-service/src/main/java/com/fs/course/param/FsBlackAndReportParam.java
  9. 61 0
      fs-service/src/main/java/com/fs/course/param/FsBlackTalentParam.java
  10. 59 0
      fs-service/src/main/java/com/fs/course/param/FsBlackVideoParam.java
  11. 38 0
      fs-service/src/main/java/com/fs/course/param/FsCollectionParam.java
  12. 11 0
      fs-service/src/main/java/com/fs/course/param/FsUserCollectionFavoriteListUParam.java
  13. 32 0
      fs-service/src/main/java/com/fs/course/param/FsVideoCollectionParam.java
  14. 70 0
      fs-service/src/main/java/com/fs/course/service/IFsUserCollectionFavoriteService.java
  15. 2 0
      fs-service/src/main/java/com/fs/course/service/IFsUserVideoService.java
  16. 84 0
      fs-service/src/main/java/com/fs/course/service/IFsVideoCollectionService.java
  17. 146 0
      fs-service/src/main/java/com/fs/course/service/impl/FsUserCollectionFavoriteServiceImpl.java
  18. 223 0
      fs-service/src/main/java/com/fs/course/service/impl/FsVideoCollectionServiceImpl.java
  19. 12 0
      fs-service/src/main/java/com/fs/course/vo/FsUserVideoListUVO.java
  20. 36 0
      fs-service/src/main/java/com/fs/his/domain/FsThirdDeviceData.java
  21. 61 0
      fs-service/src/main/java/com/fs/his/mapper/FsThirdDeviceDataMapper.java
  22. 61 0
      fs-service/src/main/java/com/fs/his/service/IFsThirdDeviceDataService.java
  23. 93 0
      fs-service/src/main/java/com/fs/his/service/impl/FsThirdDeviceDataServiceImpl.java
  24. 92 0
      fs-service/src/main/resources/mapper/course/FsCollectionMapper.xml
  25. 69 0
      fs-service/src/main/resources/mapper/course/FsUserCollectionFavoriteMapper.xml
  26. 128 0
      fs-service/src/main/resources/mapper/course/FsVideoCollectionMapper.xml
  27. 70 0
      fs-service/src/main/resources/mapper/his/FsThirdDeviceDataMapper.xml
  28. 1 1
      fs-user-app/src/main/java/com/fs/app/controller/AppLoginController.java
  29. 122 0
      fs-user-app/src/main/java/com/fs/app/controller/FsBlackTalentController.java
  30. 56 0
      fs-user-app/src/main/java/com/fs/app/controller/FsThirdDeviceDataController.java
  31. 11 5
      fs-user-app/src/main/java/com/fs/app/controller/TalentController.java

+ 48 - 0
fs-service/src/main/java/com/fs/course/domain/FsCollection.java

@@ -0,0 +1,48 @@
+package com.fs.course.domain;
+
+import com.fs.common.annotation.Excel;
+import com.fs.common.core.domain.BaseEntity;
+import lombok.Data;
+import lombok.EqualsAndHashCode;
+
+/**
+ * 短视频合集对象 fs_collection
+ *
+ * @author fs
+ * @date 2025-07-24
+ */
+@Data
+@EqualsAndHashCode(callSuper = true)
+public class FsCollection extends BaseEntity{
+
+    /** 合集ID */
+    private Long collectionId;
+
+    private Long userId;
+    /** 合集标题 */
+    @Excel(name = "合集标题")
+    private String title;
+
+    /** 合集描述 */
+    @Excel(name = "合集描述")
+    private String description;
+
+    /** 合集封面图 */
+    @Excel(name = "合集封面图")
+    private String coverUrl;
+
+    /** 达人ID */
+    @Excel(name = "达人ID")
+    private Long talentId;
+
+    /** 状态:1正常 0下架 */
+    @Excel(name = "状态:1正常 0下架")
+    private Long status;
+
+    /** 合集标签 */
+    @Excel(name = "合集标签")
+    private String tags;
+
+    private String isFavorite;
+
+}

+ 30 - 0
fs-service/src/main/java/com/fs/course/domain/FsUserCollectionFavorite.java

@@ -0,0 +1,30 @@
+package com.fs.course.domain;
+
+import com.fs.common.annotation.Excel;
+import com.fs.common.core.domain.BaseEntity;
+import lombok.Data;
+import lombok.EqualsAndHashCode;
+
+/**
+ * 合集收藏对象 fs_user_collection_favorite
+ *
+ * @author fs
+ * @date 2025-10-11
+ */
+@Data
+@EqualsAndHashCode(callSuper = true)
+public class FsUserCollectionFavorite extends BaseEntity{
+
+    /** 收藏id */
+    private Long favoriteId;
+
+    /** 用户id */
+    @Excel(name = "用户id")
+    private Long userId;
+
+    /** 合集id */
+    @Excel(name = "合集id")
+    private Long collectionId;
+
+
+}

+ 34 - 0
fs-service/src/main/java/com/fs/course/domain/FsVideoCollection.java

@@ -0,0 +1,34 @@
+package com.fs.course.domain;
+
+import com.fs.common.annotation.Excel;
+import com.fs.common.core.domain.BaseEntity;
+import lombok.Data;
+import lombok.EqualsAndHashCode;
+
+/**
+ * 合集与视频关联对象 fs_video_collection
+ *
+ * @author fs
+ * @date 2025-07-24
+ */
+@Data
+@EqualsAndHashCode(callSuper = true)
+public class FsVideoCollection extends BaseEntity{
+
+    /** 主键ID */
+    private Long id;
+
+    /** 合集ID */
+    @Excel(name = "合集ID")
+    private Long collectionId;
+
+    /** 视频ID */
+    @Excel(name = "视频ID")
+    private Long videoId;
+
+    /** 视频在合集中的排序 */
+    @Excel(name = "视频在合集中的排序")
+    private Long sort;
+
+
+}

+ 39 - 0
fs-service/src/main/java/com/fs/course/dto/VideoCollectionDTO.java

@@ -0,0 +1,39 @@
+package com.fs.course.dto;
+
+import com.fs.common.annotation.Excel;
+import lombok.Data;
+
+@Data
+public class VideoCollectionDTO {
+    /** 合集ID */
+    private Long collectionId;
+
+    private Long userId;
+    /** 合集标题 */
+    @Excel(name = "合集标题")
+    private String title;
+
+    /** 合集描述 */
+    @Excel(name = "合集描述")
+    private String description;
+
+    /** 合集封面图 */
+    @Excel(name = "合集封面图")
+    private String coverUrl;
+
+    /** 达人ID */
+    @Excel(name = "达人ID")
+    private Long talentId;
+
+    /** 状态:1正常 0下架 */
+    @Excel(name = "状态:1正常 0下架")
+    private Long status;
+
+    /** 合集标签 */
+    @Excel(name = "合集标签")
+    private String tags;
+
+    private int count;
+
+    private Boolean isFavorite;
+}

+ 69 - 0
fs-service/src/main/java/com/fs/course/mapper/FsCollectionMapper.java

@@ -0,0 +1,69 @@
+package com.fs.course.mapper;
+
+import com.baomidou.mybatisplus.core.mapper.BaseMapper;
+import com.fs.course.domain.FsCollection;
+import com.fs.course.param.FsCollectionParam;
+import com.fs.course.param.FsUserCollectionFavoriteListUParam;
+import org.apache.ibatis.annotations.Param;
+import org.apache.ibatis.annotations.Select;
+
+import java.util.List;
+
+/**
+ * 短视频合集Mapper接口
+ *
+ * @author fs
+ * @date 2025-07-24
+ */
+public interface FsCollectionMapper extends BaseMapper<FsCollection>{
+    /**
+     * 查询短视频合集
+     *
+     * @param collectionId 短视频合集主键
+     * @return 短视频合集
+     */
+    FsCollection selectFsCollectionByCollectionId(String collectionId);
+
+    /**
+     * 查询短视频合集列表
+     *
+     * @param param 短视频合集
+     * @return 短视频合集集合
+     */
+    List<FsCollection> selectFsCollectionList(FsCollectionParam param);
+
+    /**
+     * 新增短视频合集
+     *
+     * @param fsCollection 短视频合集
+     * @return 结果
+     */
+    int insertFsCollection(FsCollection fsCollection);
+
+    /**
+     * 修改短视频合集
+     *
+     * @param fsCollection 短视频合集
+     * @return 结果
+     */
+    int updateFsCollection(FsCollection fsCollection);
+
+    /**
+     * 删除短视频合集
+     *
+     * @param collectionId 短视频合集主键
+     * @return 结果
+     */
+    int deleteFsCollectionByCollectionId(String collectionId);
+
+    /**
+     * 批量删除短视频合集
+     *
+     * @param collectionIds 需要删除的数据主键集合
+     * @return 结果
+     */
+    int deleteFsCollectionByCollectionIds(String[] collectionIds);
+
+    @Select("SELECT fc.* FROM fs_user_collection_favorite ff LEFT JOIN fs_collection fc ON ff.collection_id = fc.collection_id where ff.user_id = #{maps.userId}")
+    List<FsCollection> selectFsUserFavoriteCollectionList(@Param("maps") FsUserCollectionFavoriteListUParam param);
+}

+ 72 - 0
fs-service/src/main/java/com/fs/course/mapper/FsUserCollectionFavoriteMapper.java

@@ -0,0 +1,72 @@
+package com.fs.course.mapper;
+
+import com.baomidou.mybatisplus.core.mapper.BaseMapper;
+import com.fs.course.domain.FsUserCollectionFavorite;
+import org.apache.ibatis.annotations.Delete;
+import org.apache.ibatis.annotations.Param;
+import org.apache.ibatis.annotations.Select;
+
+import java.util.List;
+
+/**
+ * 合集收藏Mapper接口
+ *
+ * @author fs
+ * @date 2025-10-11
+ */
+public interface FsUserCollectionFavoriteMapper extends BaseMapper<FsUserCollectionFavorite>{
+    /**
+     * 查询合集收藏
+     *
+     * @param favoriteId 合集收藏主键
+     * @return 合集收藏
+     */
+    FsUserCollectionFavorite selectFsUserCollectionFavoriteByFavoriteId(Long favoriteId);
+
+    /**
+     * 查询合集收藏列表
+     *
+     * @param fsUserCollectionFavorite 合集收藏
+     * @return 合集收藏集合
+     */
+    List<FsUserCollectionFavorite> selectFsUserCollectionFavoriteList(FsUserCollectionFavorite fsUserCollectionFavorite);
+
+    /**
+     * 新增合集收藏
+     *
+     * @param fsUserCollectionFavorite 合集收藏
+     * @return 结果
+     */
+    int insertFsUserCollectionFavorite(FsUserCollectionFavorite fsUserCollectionFavorite);
+
+    /**
+     * 修改合集收藏
+     *
+     * @param fsUserCollectionFavorite 合集收藏
+     * @return 结果
+     */
+    int updateFsUserCollectionFavorite(FsUserCollectionFavorite fsUserCollectionFavorite);
+
+    /**
+     * 删除合集收藏
+     *
+     * @param favoriteId 合集收藏主键
+     * @return 结果
+     */
+    int deleteFsUserCollectionFavoriteByFavoriteId(Long favoriteId);
+
+    /**
+     * 批量删除合集收藏
+     *
+     * @param favoriteIds 需要删除的数据主键集合
+     * @return 结果
+     */
+    int deleteFsUserCollectionFavoriteByFavoriteIds(Long[] favoriteIds);
+
+    @Select("select ifnull(count(1),0) from fs_user_collection_favorite  where collection_id =#{collectionId} and user_id=#{userId}")
+    int checkFavorite(@Param("collectionId") Long collectionId, @Param("userId") long userId);
+
+    @Delete("delete from fs_user_collection_favorite  where collection_id =#{collectionId} and user_id=#{userId} ")
+    int deleteFavorite(@Param("collectionId") Long collectionId,@Param("userId")long userId);
+
+}

+ 87 - 0
fs-service/src/main/java/com/fs/course/mapper/FsVideoCollectionMapper.java

@@ -0,0 +1,87 @@
+package com.fs.course.mapper;
+
+import com.baomidou.mybatisplus.core.mapper.BaseMapper;
+import com.fs.course.domain.FsVideoCollection;
+import com.fs.course.dto.VideoCollectionDTO;
+import com.fs.course.param.FsVideoCollectionParam;
+import com.fs.course.vo.FsUserVideoListUVO;
+import org.apache.ibatis.annotations.Param;
+
+import java.util.List;
+
+/**
+ * 合集与视频关联Mapper接口
+ *
+ * @author fs
+ * @date 2025-07-24
+ */
+public interface FsVideoCollectionMapper extends BaseMapper<FsVideoCollection>{
+    /**
+     * 查询合集与视频关联
+     *
+     * @param id 合集与视频关联主键
+     * @return 合集与视频关联
+     */
+    FsVideoCollection selectFsVideoCollectionById(String id);
+
+    /**
+     * 查询合集与视频关联列表
+     *
+     * @param param 合集与视频关联
+     * @return 合集与视频关联集合
+     */
+    List<FsUserVideoListUVO> selectFsVideoCollectionList(FsVideoCollectionParam param);
+
+    /**
+     * 新增合集与视频关联
+     *
+     * @param fsVideoCollectionParam 合集与视频关联
+     * @return 结果
+     */
+    int insertFsVideoCollection(FsVideoCollectionParam fsVideoCollectionParam);
+
+    /**
+     * 修改合集与视频关联
+     *
+     * @param fsVideoCollection 合集与视频关联
+     * @return 结果
+     */
+    int updateFsVideoCollection(FsVideoCollection fsVideoCollection);
+
+    /**
+     * 删除合集与视频关联
+     *
+     * @param id 合集与视频关联主键
+     * @return 结果
+     */
+    int deleteFsVideoCollectionById(String id);
+
+    /**
+     * 批量删除合集与视频关联
+     *
+     * @param ids 需要删除的数据主键集合
+     * @return 结果
+     */
+    int deleteFsVideoCollectionByIds(String[] ids);
+
+    int selectByIdAndSort(@Param("collectionId") Long collectionId,@Param("sort")Long sort);
+
+    int removeVideo(Long id);
+
+    int batchInsertFsVideoCollection(List<FsVideoCollectionParam> paramList);
+
+    int removeVideos(@Param("ids") List<Long> ids);
+
+    int batchUpdateSort(@Param("list") List<FsVideoCollectionParam> sortList);
+
+
+    List<String> selectVideoIdsByCollectionId(Long collectionId);
+
+    int selectCountByVideoId(Long videoId);
+
+    VideoCollectionDTO selectCollectionByVideoId(Long videoId);
+
+    int deleteFsVideoCollectionByCollectionId(Long collectionId);
+
+    int selectCountByCollectionId(Long collectionId);
+}

+ 10 - 0
fs-service/src/main/java/com/fs/course/param/FsBlackAndReportParam.java

@@ -0,0 +1,10 @@
+package com.fs.course.param;
+
+import lombok.Data;
+
+@Data
+public class FsBlackAndReportParam {
+    private Long userId;
+    private String type;
+    private String style;
+}

+ 61 - 0
fs-service/src/main/java/com/fs/course/param/FsBlackTalentParam.java

@@ -0,0 +1,61 @@
+package com.fs.course.param;
+
+import com.fasterxml.jackson.annotation.JsonFormat;
+import com.fs.common.annotation.Excel;
+import lombok.Data;
+
+import java.util.Date;
+
+@Data
+public class FsBlackTalentParam {
+    @Excel(name = "用户id")
+    private Long userId;
+
+    /** 达人id */
+    @Excel(name = "达人id")
+    private Long talentId;
+    /** 举报说明(拉黑为空) */
+    @Excel(name = "举报说明", readConverterExp = "拉=黑为空")
+    private String reportDesc;
+
+    /** 是否审核-1:驳回,0:待审核,1:通过(拉黑不需要审核) */
+    @Excel(name = "是否审核-1:驳回,0:待审核,1:通过", readConverterExp = "拉=黑不需要审核")
+    private String isAudit;
+
+    /** 审核时间 */
+    @JsonFormat(pattern = "yyyy-MM-dd")
+    @Excel(name = "审核时间", width = 30, dateFormat = "yyyy-MM-dd")
+    private Date auditTime;
+
+    /** 审核人 */
+    @Excel(name = "审核人")
+    private Long auditUser;
+
+    /** 审核说明 */
+    @Excel(name = "审核说明")
+    private String auditDesc;
+
+    /** 类型1:拉黑,2:举报 */
+    @Excel(name = "类型1:拉黑,2:举报")
+    private String type;
+
+    /** 创建时间 */
+    @JsonFormat(pattern = "yyyy-MM-dd")
+    @Excel(name = "创建时间", width = 30, dateFormat = "yyyy-MM-dd")
+    private Date creatTime;
+
+    @Excel(name = "联系方式")
+    private String phone;
+
+    /** 图片地址 */
+    @Excel(name = "图片地址")
+    private String urls;
+
+    @Excel(name = "投诉模板id")
+    private Long templateId;
+
+    //交易截图
+    private String tradeImage;
+
+
+}

+ 59 - 0
fs-service/src/main/java/com/fs/course/param/FsBlackVideoParam.java

@@ -0,0 +1,59 @@
+package com.fs.course.param;
+
+import com.fasterxml.jackson.annotation.JsonFormat;
+import com.fs.common.annotation.Excel;
+import lombok.Data;
+
+import java.util.Date;
+@Data
+public class FsBlackVideoParam {
+    /** 用户id */
+    @Excel(name = "用户id")
+    private Long userId;
+
+
+    /** 类型1:拉黑,2:举报 */
+    @Excel(name = "类型1:拉黑,2:举报")
+    private String type;
+
+    /** 举报说明(拉黑为空) */
+    @Excel(name = "举报说明", readConverterExp = "拉=黑为空")
+    private String reportDesc;
+
+    /** 是否审核-1:驳回,0:待审核,1:通过(拉黑不需要审核) */
+    @Excel(name = "是否审核-1:驳回,0:待审核,1:通过", readConverterExp = "拉=黑不需要审核")
+    private String isAudit;
+
+    /** 审核时间 */
+    @JsonFormat(pattern = "yyyy-MM-dd")
+    @Excel(name = "审核时间", width = 30, dateFormat = "yyyy-MM-dd")
+    private Date auditTime;
+
+    /** 审核人 */
+    @Excel(name = "审核人")
+    private Long auditUser;
+
+    /** 审核说明 */
+    @Excel(name = "审核说明")
+    private String auditDesc;
+
+    /** 创建时间 */
+    @JsonFormat(pattern = "yyyy-MM-dd")
+    @Excel(name = "创建时间", width = 30, dateFormat = "yyyy-MM-dd")
+    private Date creatTime;
+
+    /** 短视频id */
+    @Excel(name = "短视频id")
+    private Long videoId;
+
+    @Excel(name = "联系方式")
+    private String phone;
+
+    /** 图片地址 */
+    @Excel(name = "图片地址")
+    private String urls;
+
+    @Excel(name = "投诉模板id")
+    private Long templateId;
+
+}

+ 38 - 0
fs-service/src/main/java/com/fs/course/param/FsCollectionParam.java

@@ -0,0 +1,38 @@
+package com.fs.course.param;
+
+import com.fs.common.annotation.Excel;
+import com.fs.his.param.BaseParam;
+import lombok.Data;
+
+import java.io.Serializable;
+
+@Data
+public class FsCollectionParam extends BaseParam implements Serializable {
+    /** 合集ID */
+    private Long collectionId;
+
+    private Long userId;
+    /** 合集标题 */
+    @Excel(name = "合集标题")
+    private String title;
+
+    /** 合集描述 */
+    @Excel(name = "合集描述")
+    private String description;
+
+    /** 合集封面图 */
+    @Excel(name = "合集封面图")
+    private String coverUrl;
+
+    /** 达人ID */
+    @Excel(name = "达人ID")
+    private Long talentId;
+
+    /** 状态:1正常 0下架 */
+    @Excel(name = "状态:1正常 0下架")
+    private Long status;
+
+    /** 合集标签 */
+    @Excel(name = "合集标签")
+    private String tags;
+}

+ 11 - 0
fs-service/src/main/java/com/fs/course/param/FsUserCollectionFavoriteListUParam.java

@@ -0,0 +1,11 @@
+package com.fs.course.param;
+
+import com.fs.his.param.BaseParam;
+import lombok.Data;
+
+import java.io.Serializable;
+
+@Data
+public class FsUserCollectionFavoriteListUParam extends BaseParam implements Serializable {
+    private Long userId;
+}

+ 32 - 0
fs-service/src/main/java/com/fs/course/param/FsVideoCollectionParam.java

@@ -0,0 +1,32 @@
+package com.fs.course.param;
+
+import com.fs.common.annotation.Excel;
+import com.fs.his.param.BaseParam;
+import lombok.Data;
+
+import java.io.Serializable;
+import java.util.Date;
+
+@Data
+public class FsVideoCollectionParam extends BaseParam implements Serializable {
+    private Long id;
+
+    /** 合集ID */
+    @Excel(name = "合集ID")
+    private Long collectionId;
+
+    /** 视频ID */
+    @Excel(name = "视频ID")
+    private Long videoId;
+
+    /** 视频在合集中的排序 */
+    @Excel(name = "视频在合集中的排序")
+    private Long sort;
+
+    private Long talentId;
+
+    private Date createTime;
+
+    Long userId;
+
+}

+ 70 - 0
fs-service/src/main/java/com/fs/course/service/IFsUserCollectionFavoriteService.java

@@ -0,0 +1,70 @@
+package com.fs.course.service;
+
+import com.baomidou.mybatisplus.extension.service.IService;
+import com.fs.common.core.domain.R;
+import com.fs.course.domain.FsUserCollectionFavorite;
+
+import java.util.List;
+
+/**
+ * 合集收藏Service接口
+ *
+ * @author fs
+ * @date 2025-10-11
+ */
+public interface IFsUserCollectionFavoriteService extends IService<FsUserCollectionFavorite>{
+    /**
+     * 查询合集收藏
+     *
+     * @param favoriteId 合集收藏主键
+     * @return 合集收藏
+     */
+    FsUserCollectionFavorite selectFsUserCollectionFavoriteByFavoriteId(Long favoriteId);
+
+    /**
+     * 查询合集收藏列表
+     *
+     * @param fsUserCollectionFavorite 合集收藏
+     * @return 合集收藏集合
+     */
+    List<FsUserCollectionFavorite> selectFsUserCollectionFavoriteList(FsUserCollectionFavorite fsUserCollectionFavorite);
+
+    /**
+     * 新增合集收藏
+     *
+     * @param fsUserCollectionFavorite 合集收藏
+     * @return 结果
+     */
+    int insertFsUserCollectionFavorite(FsUserCollectionFavorite fsUserCollectionFavorite);
+
+    /**
+     * 修改合集收藏
+     *
+     * @param fsUserCollectionFavorite 合集收藏
+     * @return 结果
+     */
+    int updateFsUserCollectionFavorite(FsUserCollectionFavorite fsUserCollectionFavorite);
+
+    /**
+     * 批量删除合集收藏
+     *
+     * @param favoriteIds 需要删除的合集收藏主键集合
+     * @return 结果
+     */
+    int deleteFsUserCollectionFavoriteByFavoriteIds(Long[] favoriteIds);
+
+    /**
+     * 删除合集收藏信息
+     *
+     * @param favoriteId 合集收藏主键
+     * @return 结果
+     */
+    int deleteFsUserCollectionFavoriteByFavoriteId(Long favoriteId);
+
+    R checkFavorite(Long collectionId, long userId);
+
+    void deleteFavorite(Long collectionId, long userId);
+
+    void favoriteCollection(Long collectionId, long userId);
+
+}

+ 2 - 0
fs-service/src/main/java/com/fs/course/service/IFsUserVideoService.java

@@ -110,4 +110,6 @@ public interface IFsUserVideoService {
 
 
     String uploadVideo(MultipartFile file, String uploadId);
+
+    List<FsUserVideoListUVO> selectLikesAndFavorites(Long userId, List<FsUserVideoListUVO> list);
 }

+ 84 - 0
fs-service/src/main/java/com/fs/course/service/IFsVideoCollectionService.java

@@ -0,0 +1,84 @@
+package com.fs.course.service;
+
+import com.baomidou.mybatisplus.extension.service.IService;
+import com.fs.common.core.domain.AjaxResult;
+import com.fs.course.domain.FsVideoCollection;
+import com.fs.course.dto.VideoCollectionDTO;
+import com.fs.course.param.FsVideoCollectionParam;
+import com.fs.course.vo.FsUserVideoListUVO;
+
+import java.util.List;
+
+/**
+ * 合集与视频关联Service接口
+ *
+ * @author fs
+ * @date 2025-07-24
+ */
+public interface IFsVideoCollectionService extends IService<FsVideoCollection>{
+    /**
+     * 查询合集与视频关联
+     *
+     * @param id 合集与视频关联主键
+     * @return 合集与视频关联
+     */
+    FsVideoCollection selectFsVideoCollectionById(String id);
+
+    /**
+     * 查询合集与视频关联列表
+     *
+     * @param param 合集与视频关联
+     * @return 合集与视频关联集合
+     */
+    List<FsUserVideoListUVO> selectFsVideoCollectionList(FsVideoCollectionParam param);
+
+    /**
+     * 新增合集与视频关联
+     *
+     * @param fsVideoCollectionParam 合集与视频关联
+     * @return 结果
+     */
+    AjaxResult insertFsVideoCollection(FsVideoCollectionParam fsVideoCollectionParam);
+
+    /**
+     * 修改合集与视频关联
+     *
+     * @param fsVideoCollection 合集与视频关联
+     * @return 结果
+     */
+    int updateFsVideoCollection(FsVideoCollection fsVideoCollection);
+
+    int deleteFsVideoCollectionByCollectionId(Long collectionId);
+
+    /**
+     * 批量删除合集与视频关联
+     *
+     * @param ids 需要删除的合集与视频关联主键集合
+     * @return 结果
+     */
+    int deleteFsVideoCollectionByIds(String[] ids);
+
+    /**
+     * 删除合集与视频关联信息
+     *
+     * @param id 合集与视频关联主键
+     * @return 结果
+     */
+    int deleteFsVideoCollectionById(String id);
+
+    int removeVideo(FsVideoCollection fsVideoCollection);
+
+    int updateVideo(FsVideoCollection fsVideoCollection);
+
+    AjaxResult batchInsertFsVideoCollection(List<FsVideoCollectionParam> paramList);
+
+    int removeVideos(List<Long> ids);
+
+    int updateSort(List<FsVideoCollectionParam> sortList);
+
+    List<String> selectVideoIdsByCollectionId(Long collectionId);
+
+    int selectVideoCountByVideId(Long videoId);
+
+    VideoCollectionDTO selectCollectionByVideoId(Long videoId,Long userId);
+}

+ 146 - 0
fs-service/src/main/java/com/fs/course/service/impl/FsUserCollectionFavoriteServiceImpl.java

@@ -0,0 +1,146 @@
+package com.fs.course.service.impl;
+
+import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
+import com.fs.common.core.domain.R;
+import com.fs.common.utils.DateUtils;
+import com.fs.course.domain.FsUserCollectionFavorite;
+import com.fs.course.mapper.FsUserCollectionFavoriteMapper;
+import com.fs.course.service.IFsUserCollectionFavoriteService;
+import lombok.Synchronized;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.data.redis.core.RedisTemplate;
+import org.springframework.stereotype.Service;
+import org.springframework.transaction.annotation.Transactional;
+
+import java.util.List;
+import java.util.concurrent.TimeUnit;
+
+/**
+ * 合集收藏Service业务层处理
+ *
+ * @author fs
+ * @date 2025-10-11
+ */
+@Service
+public class FsUserCollectionFavoriteServiceImpl extends ServiceImpl<FsUserCollectionFavoriteMapper, FsUserCollectionFavorite> implements IFsUserCollectionFavoriteService {
+
+    @Autowired
+    private FsUserCollectionFavoriteMapper userCollectionFavoriteMapper;
+    @Autowired(required=false)
+    private RedisTemplate<String, Boolean> redisTemplate;
+
+    private static final String FAVORITE_KEY_PREFIX = "favorite:collection:";
+    private static final String NO_FAVORITE_KEY_PREFIX = "nofavorite:collection:";
+    /**
+     * 查询合集收藏
+     *
+     * @param favoriteId 合集收藏主键
+     * @return 合集收藏
+     */
+    @Override
+    public FsUserCollectionFavorite selectFsUserCollectionFavoriteByFavoriteId(Long favoriteId)
+    {
+        return baseMapper.selectFsUserCollectionFavoriteByFavoriteId(favoriteId);
+    }
+
+    /**
+     * 查询合集收藏列表
+     *
+     * @param fsUserCollectionFavorite 合集收藏
+     * @return 合集收藏
+     */
+    @Override
+    public List<FsUserCollectionFavorite> selectFsUserCollectionFavoriteList(FsUserCollectionFavorite fsUserCollectionFavorite)
+    {
+        return baseMapper.selectFsUserCollectionFavoriteList(fsUserCollectionFavorite);
+    }
+
+    /**
+     * 新增合集收藏
+     *
+     * @param fsUserCollectionFavorite 合集收藏
+     * @return 结果
+     */
+    @Override
+    public int insertFsUserCollectionFavorite(FsUserCollectionFavorite fsUserCollectionFavorite)
+    {
+        fsUserCollectionFavorite.setCreateTime(DateUtils.getNowDate());
+        return baseMapper.insertFsUserCollectionFavorite(fsUserCollectionFavorite);
+    }
+
+    /**
+     * 修改合集收藏
+     *
+     * @param fsUserCollectionFavorite 合集收藏
+     * @return 结果
+     */
+    @Override
+    public int updateFsUserCollectionFavorite(FsUserCollectionFavorite fsUserCollectionFavorite)
+    {
+        fsUserCollectionFavorite.setUpdateTime(DateUtils.getNowDate());
+        return baseMapper.updateFsUserCollectionFavorite(fsUserCollectionFavorite);
+    }
+
+    /**
+     * 批量删除合集收藏
+     *
+     * @param favoriteIds 需要删除的合集收藏主键
+     * @return 结果
+     */
+    @Override
+    public int deleteFsUserCollectionFavoriteByFavoriteIds(Long[] favoriteIds)
+    {
+        return baseMapper.deleteFsUserCollectionFavoriteByFavoriteIds(favoriteIds);
+    }
+
+    /**
+     * 删除合集收藏信息
+     *
+     * @param favoriteId 合集收藏主键
+     * @return 结果
+     */
+    @Override
+    public int deleteFsUserCollectionFavoriteByFavoriteId(Long favoriteId)
+    {
+        return baseMapper.deleteFsUserCollectionFavoriteByFavoriteId(favoriteId);
+    }
+
+    @Override
+    public R checkFavorite(Long collectionId, long userId) {
+        String key = FAVORITE_KEY_PREFIX + collectionId + ":user:" + userId;
+        Boolean hasFavorite = redisTemplate.opsForValue().get(key);
+        if (hasFavorite != null && hasFavorite) {
+            return R.ok().put("isFavorite",1);
+        }else {
+            return userCollectionFavoriteMapper.checkFavorite(collectionId, userId) > 0 ? R.ok().put("isFavorite", 1) : R.error().put("isFavorite", 0);
+        }
+    }
+
+    @Override
+    @Transactional
+    @Synchronized
+    public void favoriteCollection(Long collectionId, long userId) {
+        String unlikeKey = NO_FAVORITE_KEY_PREFIX + collectionId + ":user:" + userId;
+        redisTemplate.delete(unlikeKey);
+        String key = FAVORITE_KEY_PREFIX + collectionId + ":user:" + userId;
+        redisTemplate.opsForValue().set(key, true, 1, TimeUnit.DAYS);
+        FsUserCollectionFavorite fsUserCollectionFavorite = new FsUserCollectionFavorite();
+        fsUserCollectionFavorite.setCollectionId(collectionId);
+        fsUserCollectionFavorite.setUserId(userId);
+        fsUserCollectionFavorite.setCreateTime(DateUtils.getNowDate());
+        userCollectionFavoriteMapper.insertFsUserCollectionFavorite(fsUserCollectionFavorite);
+    }
+
+    @Override
+    @Transactional
+    @Synchronized
+    public void deleteFavorite(Long collectionId, long userId) {
+        String key = FAVORITE_KEY_PREFIX + collectionId + ":user:" + userId;
+        redisTemplate.delete(key);
+
+        // 将取消点赞记录写入Redis
+        String unlikeKey = NO_FAVORITE_KEY_PREFIX + collectionId + ":user:" + userId;
+        redisTemplate.opsForValue().set(unlikeKey, true, 1, TimeUnit.DAYS);
+        userCollectionFavoriteMapper.deleteFavorite(collectionId, userId);
+    }
+}

+ 223 - 0
fs-service/src/main/java/com/fs/course/service/impl/FsVideoCollectionServiceImpl.java

@@ -0,0 +1,223 @@
+package com.fs.course.service.impl;
+
+import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
+import com.fs.common.core.domain.AjaxResult;
+import com.fs.common.utils.DateUtils;
+import com.fs.course.domain.FsCollection;
+import com.fs.course.domain.FsVideoCollection;
+import com.fs.course.dto.VideoCollectionDTO;
+import com.fs.course.mapper.FsCollectionMapper;
+import com.fs.course.mapper.FsUserCollectionFavoriteMapper;
+import com.fs.course.mapper.FsVideoCollectionMapper;
+import com.fs.course.param.FsVideoCollectionParam;
+import com.fs.course.service.IFsUserCollectionFavoriteService;
+import com.fs.course.service.IFsUserVideoService;
+import com.fs.course.service.IFsVideoCollectionService;
+import com.fs.course.vo.FsUserVideoListUVO;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+import org.springframework.transaction.annotation.Transactional;
+
+import java.util.List;
+
+/**
+ * 合集与视频关联Service业务层处理
+ *
+ * @author fs
+ * @date 2025-07-24
+ */
+@Service
+public class FsVideoCollectionServiceImpl extends ServiceImpl<FsVideoCollectionMapper, FsVideoCollection> implements IFsVideoCollectionService {
+    @Autowired
+    private FsVideoCollectionMapper fsVideoCollectionMapper;
+    @Autowired
+    private FsCollectionMapper fsCollectionMapper;
+    @Autowired
+    private IFsUserVideoService userVideoService;
+    @Autowired
+    private IFsUserCollectionFavoriteService fsUserCollectionFavoriteService;
+
+    @Autowired
+    private FsUserCollectionFavoriteMapper userCollectionFavoriteMapper;
+    /**
+     * 查询合集与视频关联
+     *
+     * @param id 合集与视频关联主键
+     * @return 合集与视频关联
+     */
+    @Override
+    public FsVideoCollection selectFsVideoCollectionById(String id)
+    {
+        return baseMapper.selectFsVideoCollectionById(id);
+    }
+
+    /**
+     * 查询合集与视频关联列表
+     *
+     * @param
+     * @return 合集与视频关联
+     */
+    @Override
+    public List<FsUserVideoListUVO> selectFsVideoCollectionList(FsVideoCollectionParam param)
+    {
+        List<FsUserVideoListUVO> fsUserVideoListUVOS = baseMapper.selectFsVideoCollectionList(param);
+        if (param != null && param.getUserId() != null) {
+            Long userId = param.getUserId();
+            fsUserVideoListUVOS = userVideoService.selectLikesAndFavorites(userId, fsUserVideoListUVOS);
+        }
+        return fsUserVideoListUVOS;
+    }
+
+    /**
+     * 新增合集与视频关联
+     *
+     * @param
+     * @return 结果
+     */
+    @Override
+    public AjaxResult insertFsVideoCollection(FsVideoCollectionParam fsVideoCollectionParam)
+    {
+        int i = fsVideoCollectionMapper.selectByIdAndSort(fsVideoCollectionParam.getCollectionId(), fsVideoCollectionParam.getSort());
+        if (i>0){
+            return AjaxResult.error("已存在第"+fsVideoCollectionParam.getSort()+"集,请重新排序");
+        }
+        FsCollection fsCollection = fsCollectionMapper.selectFsCollectionByCollectionId(fsVideoCollectionParam.getCollectionId().toString());
+        if (fsCollection==null){
+            return AjaxResult.error("合集不存在");
+        }
+        if (fsCollection.getTalentId()!=fsVideoCollectionParam.getTalentId()){
+            return AjaxResult.error("非法操作");
+        }
+        fsVideoCollectionParam.setCreateTime(DateUtils.getNowDate());
+        baseMapper.insertFsVideoCollection(fsVideoCollectionParam);
+        return AjaxResult.success();
+
+    }
+
+    /**
+     * 修改合集与视频关联
+     *
+     * @param fsVideoCollection 合集与视频关联
+     * @return 结果
+     */
+    @Override
+    public int updateFsVideoCollection(FsVideoCollection fsVideoCollection)
+    {
+        return baseMapper.updateFsVideoCollection(fsVideoCollection);
+    }
+
+    @Override
+    public int deleteFsVideoCollectionByCollectionId(Long collectionId) {
+        return fsVideoCollectionMapper.deleteFsVideoCollectionByCollectionId(collectionId);
+    }
+
+    /**
+     * 批量删除合集与视频关联
+     *
+     * @param ids 需要删除的合集与视频关联主键
+     * @return 结果
+     */
+    @Override
+    public int deleteFsVideoCollectionByIds(String[] ids)
+    {
+        return baseMapper.deleteFsVideoCollectionByIds(ids);
+    }
+
+    /**
+     * 删除合集与视频关联信息
+     *
+     * @param id 合集与视频关联主键
+     * @return 结果
+     */
+    @Override
+    public int deleteFsVideoCollectionById(String id)
+    {
+        return baseMapper.deleteFsVideoCollectionById(id);
+    }
+
+    @Override
+    public int removeVideo(FsVideoCollection fsVideoCollection) {
+        return baseMapper.removeVideo(fsVideoCollection.getId());
+    }
+
+    @Override
+    public int updateVideo(FsVideoCollection fsVideoCollection) {
+        return baseMapper.updateFsVideoCollection(fsVideoCollection);
+    }
+
+    @Override
+    @Transactional(rollbackFor = Exception.class)
+    public AjaxResult batchInsertFsVideoCollection(List<FsVideoCollectionParam> paramList) {
+        if (paramList == null || paramList.isEmpty()) {
+            return AjaxResult.error("参数不能为空");
+        }
+
+        Long collectionId = paramList.get(0).getCollectionId();
+        FsCollection fsCollection = fsCollectionMapper.selectFsCollectionByCollectionId(collectionId.toString());
+        if (fsCollection == null) {
+            return AjaxResult.error("合集不存在");
+        }
+
+        for (FsVideoCollectionParam param : paramList) {
+            // 检查是否属于同一个 talent
+            if (!fsCollection.getTalentId().equals(param.getTalentId())) {
+                return AjaxResult.error("非法操作");
+            }
+
+            // 检查 sort 是否重复
+//            int count = fsVideoCollectionMapper.selectByIdAndSort(param.getCollectionId(), param.getSort());
+//            if (count > 0) {
+//                return AjaxResult.error("已存在第" + param.getSort() + "集,请重新排序");
+//            }
+        }
+
+        // 批量插入
+        fsVideoCollectionMapper.batchInsertFsVideoCollection(paramList);
+        return AjaxResult.success();
+    }
+
+
+    @Override
+    public int removeVideos(List<Long> ids) {
+        if (ids == null || ids.isEmpty()) {
+            return 0;
+        }
+        return baseMapper.removeVideos(ids);
+    }
+
+    @Override
+    public int updateSort(List<FsVideoCollectionParam> sortList) {
+        if (sortList == null || sortList.isEmpty()) {
+            return 0;
+        }
+        return baseMapper.batchUpdateSort(sortList);
+    }
+
+    @Override
+    public List<String> selectVideoIdsByCollectionId(Long collectionId) {
+        return fsVideoCollectionMapper.selectVideoIdsByCollectionId(collectionId);
+
+    }
+
+    @Override
+    public int selectVideoCountByVideId(Long videoId) {
+        return fsVideoCollectionMapper.selectCountByVideoId(videoId);
+    }
+
+    @Override
+    public VideoCollectionDTO selectCollectionByVideoId(Long videoId,Long userId) {
+        VideoCollectionDTO videoCollectionDTO = fsVideoCollectionMapper.selectCollectionByVideoId(videoId);
+        if (videoCollectionDTO != null){
+            int i = fsVideoCollectionMapper.selectCountByCollectionId(videoCollectionDTO.getCollectionId());
+            videoCollectionDTO.setCount(i);
+            int favoriteCount = userCollectionFavoriteMapper.checkFavorite(videoCollectionDTO.getCollectionId(), userId);
+            if (favoriteCount>0){
+                videoCollectionDTO.setIsFavorite(true);
+            }else {
+                videoCollectionDTO.setIsFavorite(false);
+            }
+        }
+        return videoCollectionDTO;
+    }
+
+}

+ 12 - 0
fs-service/src/main/java/com/fs/course/vo/FsUserVideoListUVO.java

@@ -1,6 +1,7 @@
 package com.fs.course.vo;
 
 import com.fasterxml.jackson.annotation.JsonFormat;
+import com.fs.course.dto.VideoCollectionDTO;
 import lombok.Data;
 
 import java.util.Date;
@@ -9,6 +10,9 @@ import java.util.List;
 @Data
 public class FsUserVideoListUVO {
     private String id; // _id
+    private Long userId;//视频发布者对应的用户id
+    private Long talentId;//视频发布的达人id
+    private String isFollow;//当前用户是否关注发布视频的达人
     private String username;//2.视频拥有者名称
     private String headImg;//3.发布者头像
     private String cover;//视频封面
@@ -37,5 +41,13 @@ public class FsUserVideoListUVO {
     private String productJson;
     private Integer uploadType;
     private Long shares;
+    private Integer isAudit;
+    private Integer status;
+    private String failReason;
     private String addNum; //随机添加数
+    private Boolean isInCollection;
+    //合集信息
+    private VideoCollectionDTO videoCollectionDTO;
+
+    private String thumbnail;
 }

+ 36 - 0
fs-service/src/main/java/com/fs/his/domain/FsThirdDeviceData.java

@@ -0,0 +1,36 @@
+package com.fs.his.domain;
+
+import com.baomidou.mybatisplus.annotation.TableId;
+import com.fs.common.annotation.Excel;
+import lombok.Data;
+import com.fs.common.core.domain.BaseEntity;
+import lombok.EqualsAndHashCode;
+
+/**
+ * 三方设备健康数据对象 fs_third_device_data
+ *
+ * @author fs
+ * @date 2026-03-19
+ */
+@Data
+@EqualsAndHashCode(callSuper = true)
+public class FsThirdDeviceData extends BaseEntity{
+
+    /** 记录id */
+    @TableId
+    private Long id;
+
+    /** 用户id */
+    @Excel(name = "用户id")
+    private Long userId;
+
+    /** 记录类型 0:血压 1:血糖 */
+    @Excel(name = "记录类型 0:血压 1:血糖")
+    private Integer recordType;
+
+    /** 记录数值 */
+    @Excel(name = "记录数值")
+    private String recordValue;
+
+
+}

+ 61 - 0
fs-service/src/main/java/com/fs/his/mapper/FsThirdDeviceDataMapper.java

@@ -0,0 +1,61 @@
+package com.fs.his.mapper;
+
+import java.util.List;
+import com.baomidou.mybatisplus.core.mapper.BaseMapper;
+import com.fs.his.domain.FsThirdDeviceData;
+
+/**
+ * 三方设备健康数据Mapper接口
+ * 
+ * @author fs
+ * @date 2026-03-19
+ */
+public interface FsThirdDeviceDataMapper extends BaseMapper<FsThirdDeviceData>{
+    /**
+     * 查询三方设备健康数据
+     * 
+     * @param id 三方设备健康数据主键
+     * @return 三方设备健康数据
+     */
+    FsThirdDeviceData selectFsThirdDeviceDataById(Long id);
+
+    /**
+     * 查询三方设备健康数据列表
+     * 
+     * @param fsThirdDeviceData 三方设备健康数据
+     * @return 三方设备健康数据集合
+     */
+    List<FsThirdDeviceData> selectFsThirdDeviceDataList(FsThirdDeviceData fsThirdDeviceData);
+
+    /**
+     * 新增三方设备健康数据
+     * 
+     * @param fsThirdDeviceData 三方设备健康数据
+     * @return 结果
+     */
+    int insertFsThirdDeviceData(FsThirdDeviceData fsThirdDeviceData);
+
+    /**
+     * 修改三方设备健康数据
+     * 
+     * @param fsThirdDeviceData 三方设备健康数据
+     * @return 结果
+     */
+    int updateFsThirdDeviceData(FsThirdDeviceData fsThirdDeviceData);
+
+    /**
+     * 删除三方设备健康数据
+     * 
+     * @param id 三方设备健康数据主键
+     * @return 结果
+     */
+    int deleteFsThirdDeviceDataById(Long id);
+
+    /**
+     * 批量删除三方设备健康数据
+     * 
+     * @param ids 需要删除的数据主键集合
+     * @return 结果
+     */
+    int deleteFsThirdDeviceDataByIds(Long[] ids);
+}

+ 61 - 0
fs-service/src/main/java/com/fs/his/service/IFsThirdDeviceDataService.java

@@ -0,0 +1,61 @@
+package com.fs.his.service;
+
+import java.util.List;
+import com.baomidou.mybatisplus.extension.service.IService;
+import com.fs.his.domain.FsThirdDeviceData;
+
+/**
+ * 三方设备健康数据Service接口
+ * 
+ * @author fs
+ * @date 2026-03-19
+ */
+public interface IFsThirdDeviceDataService extends IService<FsThirdDeviceData>{
+    /**
+     * 查询三方设备健康数据
+     * 
+     * @param id 三方设备健康数据主键
+     * @return 三方设备健康数据
+     */
+    FsThirdDeviceData selectFsThirdDeviceDataById(Long id);
+
+    /**
+     * 查询三方设备健康数据列表
+     * 
+     * @param fsThirdDeviceData 三方设备健康数据
+     * @return 三方设备健康数据集合
+     */
+    List<FsThirdDeviceData> selectFsThirdDeviceDataList(FsThirdDeviceData fsThirdDeviceData);
+
+    /**
+     * 新增三方设备健康数据
+     * 
+     * @param fsThirdDeviceData 三方设备健康数据
+     * @return 结果
+     */
+    int insertFsThirdDeviceData(FsThirdDeviceData fsThirdDeviceData);
+
+    /**
+     * 修改三方设备健康数据
+     * 
+     * @param fsThirdDeviceData 三方设备健康数据
+     * @return 结果
+     */
+    int updateFsThirdDeviceData(FsThirdDeviceData fsThirdDeviceData);
+
+    /**
+     * 批量删除三方设备健康数据
+     * 
+     * @param ids 需要删除的三方设备健康数据主键集合
+     * @return 结果
+     */
+    int deleteFsThirdDeviceDataByIds(Long[] ids);
+
+    /**
+     * 删除三方设备健康数据信息
+     * 
+     * @param id 三方设备健康数据主键
+     * @return 结果
+     */
+    int deleteFsThirdDeviceDataById(Long id);
+}

+ 93 - 0
fs-service/src/main/java/com/fs/his/service/impl/FsThirdDeviceDataServiceImpl.java

@@ -0,0 +1,93 @@
+package com.fs.his.service.impl;
+
+import java.util.List;
+import com.fs.common.utils.DateUtils;
+import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+import com.fs.his.mapper.FsThirdDeviceDataMapper;
+import com.fs.his.domain.FsThirdDeviceData;
+import com.fs.his.service.IFsThirdDeviceDataService;
+
+/**
+ * 三方设备健康数据Service业务层处理
+ * 
+ * @author fs
+ * @date 2026-03-19
+ */
+@Service
+public class FsThirdDeviceDataServiceImpl extends ServiceImpl<FsThirdDeviceDataMapper, FsThirdDeviceData> implements IFsThirdDeviceDataService {
+
+    /**
+     * 查询三方设备健康数据
+     * 
+     * @param id 三方设备健康数据主键
+     * @return 三方设备健康数据
+     */
+    @Override
+    public FsThirdDeviceData selectFsThirdDeviceDataById(Long id)
+    {
+        return baseMapper.selectFsThirdDeviceDataById(id);
+    }
+
+    /**
+     * 查询三方设备健康数据列表
+     * 
+     * @param fsThirdDeviceData 三方设备健康数据
+     * @return 三方设备健康数据
+     */
+    @Override
+    public List<FsThirdDeviceData> selectFsThirdDeviceDataList(FsThirdDeviceData fsThirdDeviceData)
+    {
+        return baseMapper.selectFsThirdDeviceDataList(fsThirdDeviceData);
+    }
+
+    /**
+     * 新增三方设备健康数据
+     * 
+     * @param fsThirdDeviceData 三方设备健康数据
+     * @return 结果
+     */
+    @Override
+    public int insertFsThirdDeviceData(FsThirdDeviceData fsThirdDeviceData)
+    {
+        fsThirdDeviceData.setCreateTime(DateUtils.getNowDate());
+        return baseMapper.insertFsThirdDeviceData(fsThirdDeviceData);
+    }
+
+    /**
+     * 修改三方设备健康数据
+     * 
+     * @param fsThirdDeviceData 三方设备健康数据
+     * @return 结果
+     */
+    @Override
+    public int updateFsThirdDeviceData(FsThirdDeviceData fsThirdDeviceData)
+    {
+        return baseMapper.updateFsThirdDeviceData(fsThirdDeviceData);
+    }
+
+    /**
+     * 批量删除三方设备健康数据
+     * 
+     * @param ids 需要删除的三方设备健康数据主键
+     * @return 结果
+     */
+    @Override
+    public int deleteFsThirdDeviceDataByIds(Long[] ids)
+    {
+        return baseMapper.deleteFsThirdDeviceDataByIds(ids);
+    }
+
+    /**
+     * 删除三方设备健康数据信息
+     * 
+     * @param id 三方设备健康数据主键
+     * @return 结果
+     */
+    @Override
+    public int deleteFsThirdDeviceDataById(Long id)
+    {
+        return baseMapper.deleteFsThirdDeviceDataById(id);
+    }
+}

+ 92 - 0
fs-service/src/main/resources/mapper/course/FsCollectionMapper.xml

@@ -0,0 +1,92 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!DOCTYPE mapper
+PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
+"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
+<mapper namespace="com.fs.course.mapper.FsCollectionMapper">
+
+    <resultMap type="FsCollection" id="FsCollectionResult">
+        <result property="collectionId"    column="collection_id"    />
+        <result property="title"    column="title"    />
+        <result property="description"    column="description"    />
+        <result property="coverUrl"    column="cover_url"    />
+        <result property="talentId"    column="talent_id"    />
+        <result property="status"    column="status"    />
+        <result property="createTime"    column="create_time"    />
+        <result property="updateTime"    column="update_time"    />
+        <result property="tags"    column="tags"    />
+        <result property="userId"    column="user_id"    />
+    </resultMap>
+
+    <sql id="selectFsCollectionVo">
+        select collection_id, title, description, cover_url, talent_id, status, create_time, update_time, tags, user_id from fs_collection
+    </sql>
+
+    <select id="selectFsCollectionList" parameterType="com.fs.course.param.FsCollectionParam" resultMap="FsCollectionResult">
+        <include refid="selectFsCollectionVo"/>
+        <where>
+            <if test="title != null  and title != ''"> and title = #{title}</if>
+            <if test="description != null  and description != ''"> and description = #{description}</if>
+            <if test="coverUrl != null  and coverUrl != ''"> and cover_url = #{coverUrl}</if>
+            <if test="talentId != null "> and talent_id = #{talentId}</if>
+            <if test="status != null "> and status = #{status}</if>
+            <if test="tags != null  and tags != ''"> and tags = #{tags}</if>
+            <if test="userId != null  and userId != ''"> and user_id = #{userId}</if>
+        </where>
+    </select>
+
+    <select id="selectFsCollectionByCollectionId" parameterType="String" resultMap="FsCollectionResult">
+        <include refid="selectFsCollectionVo"/>
+        where collection_id = #{collectionId}
+    </select>
+
+    <insert id="insertFsCollection" parameterType="FsCollection" useGeneratedKeys="true" keyProperty="collectionId">
+        insert into fs_collection
+        <trim prefix="(" suffix=")" suffixOverrides=",">
+            <if test="title != null and title != ''">title,</if>
+            <if test="description != null">description,</if>
+            <if test="coverUrl != null">cover_url,</if>
+            <if test="talentId != null">talent_id,</if>
+            <if test="status != null">status,</if>
+            <if test="createTime != null">create_time,</if>
+            <if test="updateTime != null">update_time,</if>
+            <if test="tags != null">tags,</if>
+            <if test="userId != null">user_id,</if>
+         </trim>
+        <trim prefix="values (" suffix=")" suffixOverrides=",">
+            <if test="title != null and title != ''">#{title},</if>
+            <if test="description != null">#{description},</if>
+            <if test="coverUrl != null">#{coverUrl},</if>
+            <if test="talentId != null">#{talentId},</if>
+            <if test="status != null">#{status},</if>
+            <if test="createTime != null">#{createTime},</if>
+            <if test="updateTime != null">#{updateTime},</if>
+            <if test="tags != null">#{tags},</if>
+            <if test="userId != null">#{userId},</if>
+         </trim>
+    </insert>
+
+    <update id="updateFsCollection" parameterType="FsCollection">
+        update fs_collection
+        <trim prefix="SET" suffixOverrides=",">
+            <if test="title != null and title != ''">title = #{title},</if>
+            <if test="description != null">description = #{description},</if>
+            <if test="coverUrl != null">cover_url = #{coverUrl},</if>
+            <if test="talentId != null">talent_id = #{talentId},</if>
+            <if test="status != null">status = #{status},</if>
+            <if test="createTime != null">create_time = #{createTime},</if>
+            <if test="updateTime != null">update_time = #{updateTime},</if>
+            <if test="tags != null">tags = #{tags},</if>
+            <if test="userId != null">user_id = #{userId},</if>
+        </trim>
+        where collection_id = #{collectionId}
+    </update>
+    <delete id="deleteFsCollectionByCollectionIds" parameterType="String">
+        delete from fs_collection where collection_id in
+        <foreach item="collectionId" collection="array" open="(" separator="," close=")">
+            #{collectionId}
+        </foreach>
+    </delete>
+    <delete id="deleteFsCollectionByCollectionId" parameterType="String">
+        delete from fs_collection where collection_id = #{collectionId}
+    </delete>
+</mapper>

+ 69 - 0
fs-service/src/main/resources/mapper/course/FsUserCollectionFavoriteMapper.xml

@@ -0,0 +1,69 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!DOCTYPE mapper
+PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
+"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
+<mapper namespace="com.fs.course.mapper.FsUserCollectionFavoriteMapper">
+    
+    <resultMap type="FsUserCollectionFavorite" id="FsUserCollectionFavoriteResult">
+        <result property="favoriteId"    column="favorite_id"    />
+        <result property="userId"    column="user_id"    />
+        <result property="collectionId"    column="collection_id"    />
+        <result property="createTime"    column="create_time"    />
+        <result property="updateTime"    column="update_time"    />
+    </resultMap>
+
+    <sql id="selectFsUserCollectionFavoriteVo">
+        select favorite_id, user_id, collection_id, create_time, update_time from fs_user_collection_favorite
+    </sql>
+
+    <select id="selectFsUserCollectionFavoriteList" parameterType="FsUserCollectionFavorite" resultMap="FsUserCollectionFavoriteResult">
+        <include refid="selectFsUserCollectionFavoriteVo"/>
+        <where>  
+            <if test="userId != null "> and user_id = #{userId}</if>
+            <if test="collectionId != null "> and collection_id = #{collectionId}</if>
+        </where>
+    </select>
+    
+    <select id="selectFsUserCollectionFavoriteByFavoriteId" parameterType="Long" resultMap="FsUserCollectionFavoriteResult">
+        <include refid="selectFsUserCollectionFavoriteVo"/>
+        where favorite_id = #{favoriteId}
+    </select>
+        
+    <insert id="insertFsUserCollectionFavorite" parameterType="FsUserCollectionFavorite" useGeneratedKeys="true" keyProperty="favoriteId">
+        insert into fs_user_collection_favorite
+        <trim prefix="(" suffix=")" suffixOverrides=",">
+            <if test="userId != null">user_id,</if>
+            <if test="collectionId != null">collection_id,</if>
+            <if test="createTime != null">create_time,</if>
+            <if test="updateTime != null">update_time,</if>
+         </trim>
+        <trim prefix="values (" suffix=")" suffixOverrides=",">
+            <if test="userId != null">#{userId},</if>
+            <if test="collectionId != null">#{collectionId},</if>
+            <if test="createTime != null">#{createTime},</if>
+            <if test="updateTime != null">#{updateTime},</if>
+         </trim>
+    </insert>
+
+    <update id="updateFsUserCollectionFavorite" parameterType="FsUserCollectionFavorite">
+        update fs_user_collection_favorite
+        <trim prefix="SET" suffixOverrides=",">
+            <if test="userId != null">user_id = #{userId},</if>
+            <if test="collectionId != null">collection_id = #{collectionId},</if>
+            <if test="createTime != null">create_time = #{createTime},</if>
+            <if test="updateTime != null">update_time = #{updateTime},</if>
+        </trim>
+        where favorite_id = #{favoriteId}
+    </update>
+
+    <delete id="deleteFsUserCollectionFavoriteByFavoriteId" parameterType="Long">
+        delete from fs_user_collection_favorite where favorite_id = #{favoriteId}
+    </delete>
+
+    <delete id="deleteFsUserCollectionFavoriteByFavoriteIds" parameterType="String">
+        delete from fs_user_collection_favorite where favorite_id in 
+        <foreach item="favoriteId" collection="array" open="(" separator="," close=")">
+            #{favoriteId}
+        </foreach>
+    </delete>
+</mapper>

+ 128 - 0
fs-service/src/main/resources/mapper/course/FsVideoCollectionMapper.xml

@@ -0,0 +1,128 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!DOCTYPE mapper
+PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
+"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
+<mapper namespace="com.fs.course.mapper.FsVideoCollectionMapper">
+
+    <resultMap type="FsVideoCollection" id="FsVideoCollectionResult">
+        <result property="id"    column="id"    />
+        <result property="collectionId"    column="collection_id"    />
+        <result property="videoId"    column="video_id"    />
+        <result property="sort"    column="sort"    />
+        <result property="createTime"    column="create_time"    />
+    </resultMap>
+
+    <sql id="selectFsVideoCollectionVo">
+        select id, collection_id, video_id, sort, create_time from fs_video_collection
+    </sql>
+
+    <select id="selectFsVideoCollectionList" parameterType="com.fs.course.param.FsVideoCollectionParam" resultType="com.fs.course.vo.FsUserVideoListUVO">
+        select fvc.collection_id,fvc.sort,fvc.create_time,fvc.video_id as id,
+               fuv.*,fuv.likes as likeNum,fuv.comments as smsNum,fuv.thumbnail as thumbnail
+        from fs_video_collection fvc left join fs_user_video fuv on fvc.video_id = fuv.video_id
+        <where>
+            <if test="collectionId != null  and collectionId != ''"> and fvc.collection_id = #{collectionId}</if>
+            <if test="videoId != null  and videoId != ''"> and fvc.video_id = #{videoId}</if>
+            <if test="sort != null "> and fvc.sort = #{sort}</if>
+        </where>
+        order by fvc.sort
+    </select>
+
+    <select id="selectFsVideoCollectionById" parameterType="String" resultMap="FsVideoCollectionResult">
+        <include refid="selectFsVideoCollectionVo"/>
+        where id = #{id}
+    </select>
+    <select id="selectByIdAndSort" resultType="java.lang.Integer">
+        select count(id) from fs_video_collection where collection_id = #{collectionId} and sort = #{sort}
+    </select>
+    <select id="selectVideoIdsByCollectionId" resultType="java.lang.String">
+        select video_id from fs_video_collection where collection_id = #{collectionId}
+    </select>
+    <select id="selectCountByVideoId" resultType="java.lang.Integer">
+        select count(id) from fs_video_collection where video_id = #{videoId}
+    </select>
+    <select id="selectCollectionByVideoId" resultType="com.fs.course.dto.VideoCollectionDTO">
+        SELECT fc.* FROM `fs_video_collection` fcv
+            LEFT JOIN fs_collection fc ON fcv.collection_id = fc.collection_id
+             where fcv.video_id = #{videoId}
+    </select>
+    <select id="selectCountByCollectionId" resultType="java.lang.Integer">
+        select count(id) from fs_video_collection where collection_id = #{collectionId}
+    </select>
+
+    <insert id="insertFsVideoCollection" parameterType="FsVideoCollection" useGeneratedKeys="true" keyProperty="id">
+        insert into fs_video_collection
+        <trim prefix="(" suffix=")" suffixOverrides=",">
+            <if test="collectionId != null and collectionId != ''">collection_id,</if>
+            <if test="videoId != null and videoId != ''">video_id,</if>
+            <if test="sort != null">sort,</if>
+            <if test="createTime != null">create_time,</if>
+         </trim>
+        <trim prefix="values (" suffix=")" suffixOverrides=",">
+            <if test="collectionId != null and collectionId != ''">#{collectionId},</if>
+            <if test="videoId != null and videoId != ''">#{videoId},</if>
+            <if test="sort != null">#{sort},</if>
+            <if test="createTime != null">#{createTime},</if>
+         </trim>
+    </insert>
+
+    <insert id="batchInsertFsVideoCollection" parameterType="java.util.List">
+        insert into fs_video_collection (collection_id, video_id, sort, create_time)
+        values
+        <foreach collection="list" item="item" separator=",">
+            (#{item.collectionId}, #{item.videoId}, #{item.sort}, #{item.createTime})
+        </foreach>
+    </insert>
+    <update id="updateFsVideoCollection" parameterType="FsVideoCollection">
+        update fs_video_collection
+        <trim prefix="SET" suffixOverrides=",">
+            <if test="collectionId != null and collectionId != ''">collection_id = #{collectionId},</if>
+            <if test="videoId != null and videoId != ''">video_id = #{videoId},</if>
+            <if test="sort != null">sort = #{sort},</if>
+            <if test="createTime != null">create_time = #{createTime},</if>
+        </trim>
+        where id = #{id}
+    </update>
+
+    <delete id="deleteFsVideoCollectionById" parameterType="String">
+        delete from fs_video_collection where id = #{id}
+    </delete>
+
+    <delete id="deleteFsVideoCollectionByIds" parameterType="String">
+        delete from fs_video_collection where id in
+        <foreach item="id" collection="array" open="(" separator="," close=")">
+            #{id}
+        </foreach>
+    </delete>
+    <delete id="removeVideo">
+        delete from fs_video_collection where id = #{id}
+    </delete>
+
+    <delete id="removeVideos">
+        delete from fs_video_collection
+        where video_id in
+        <foreach collection="ids" item="id" open="(" separator="," close=")">
+            #{id}
+        </foreach>
+    </delete>
+    <delete id="deleteFsVideoCollectionByCollectionId">
+        delete from fs_video_collection
+        where collection_id = #{collectionId}
+
+    </delete>
+    <update id="batchUpdateSort">
+        update fs_video_collection
+        set sort =
+        case id
+        <foreach collection="list" item="item">
+            when #{item.id} then #{item.sort}
+        </foreach>
+        end
+        where id in
+        <foreach collection="list" item="item" open="(" separator="," close=")">
+            #{item.id}
+        </foreach>
+    </update>
+
+
+</mapper>

+ 70 - 0
fs-service/src/main/resources/mapper/his/FsThirdDeviceDataMapper.xml

@@ -0,0 +1,70 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!DOCTYPE mapper
+PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
+"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
+<mapper namespace="com.fs.his.mapper.FsThirdDeviceDataMapper">
+    
+    <resultMap type="FsThirdDeviceData" id="FsThirdDeviceDataResult">
+        <result property="id"    column="id"    />
+        <result property="userId"    column="user_id"    />
+        <result property="recordType"    column="record_type"    />
+        <result property="recordValue"    column="record_value"    />
+        <result property="createTime"    column="create_time"    />
+    </resultMap>
+
+    <sql id="selectFsThirdDeviceDataVo">
+        select id, user_id, record_type, record_value, create_time from fs_third_device_data
+    </sql>
+
+    <select id="selectFsThirdDeviceDataList" parameterType="FsThirdDeviceData" resultMap="FsThirdDeviceDataResult">
+        <include refid="selectFsThirdDeviceDataVo"/>
+        <where>  
+            <if test="userId != null "> and user_id = #{userId}</if>
+            <if test="recordType != null "> and record_type = #{recordType}</if>
+            <if test="recordValue != null  and recordValue != ''"> and record_value = #{recordValue}</if>
+        </where>
+    </select>
+    
+    <select id="selectFsThirdDeviceDataById" parameterType="Long" resultMap="FsThirdDeviceDataResult">
+        <include refid="selectFsThirdDeviceDataVo"/>
+        where id = #{id}
+    </select>
+        
+    <insert id="insertFsThirdDeviceData" parameterType="FsThirdDeviceData" useGeneratedKeys="true" keyProperty="id">
+        insert into fs_third_device_data
+        <trim prefix="(" suffix=")" suffixOverrides=",">
+            <if test="userId != null">user_id,</if>
+            <if test="recordType != null">record_type,</if>
+            <if test="recordValue != null and recordValue != ''">record_value,</if>
+            <if test="createTime != null">create_time,</if>
+         </trim>
+        <trim prefix="values (" suffix=")" suffixOverrides=",">
+            <if test="userId != null">#{userId},</if>
+            <if test="recordType != null">#{recordType},</if>
+            <if test="recordValue != null and recordValue != ''">#{recordValue},</if>
+            <if test="createTime != null">#{createTime},</if>
+         </trim>
+    </insert>
+
+    <update id="updateFsThirdDeviceData" parameterType="FsThirdDeviceData">
+        update fs_third_device_data
+        <trim prefix="SET" suffixOverrides=",">
+            <if test="userId != null">user_id = #{userId},</if>
+            <if test="recordType != null">record_type = #{recordType},</if>
+            <if test="recordValue != null and recordValue != ''">record_value = #{recordValue},</if>
+            <if test="createTime != null">create_time = #{createTime},</if>
+        </trim>
+        where id = #{id}
+    </update>
+
+    <delete id="deleteFsThirdDeviceDataById" parameterType="Long">
+        delete from fs_third_device_data where id = #{id}
+    </delete>
+
+    <delete id="deleteFsThirdDeviceDataByIds" parameterType="String">
+        delete from fs_third_device_data where id in 
+        <foreach item="id" collection="array" open="(" separator="," close=")">
+            #{id}
+        </foreach>
+    </delete>
+</mapper>

+ 1 - 1
fs-user-app/src/main/java/com/fs/app/controller/AppLoginController.java

@@ -393,7 +393,7 @@ public class AppLoginController extends AppBaseController{
 
         userMap.setLoginDevice(param.getLoginDevice());
         userMap.setSource(param.getSource());
-        if (userMap.getNickName().equals("匿名用户**")) {
+        if ("匿名用户**".equals(userMap.getNickName())) {
             userMap.setNickName("苹果用户" + param.getPhone().substring(param.getPhone().length() - 4));
         }
         userMap.setAppleKey(param.getAppleKey());

+ 122 - 0
fs-user-app/src/main/java/com/fs/app/controller/FsBlackTalentController.java

@@ -0,0 +1,122 @@
+package com.fs.app.controller;
+
+import com.fs.common.core.domain.R;
+import com.fs.common.core.page.TableDataInfo;
+import com.fs.common.utils.StringUtils;
+import com.fs.course.domain.FsBlackTalent;
+import com.fs.course.param.FsBlackAndReportParam;
+import com.fs.course.param.FsBlackTalentParam;
+import com.fs.course.param.FsBlackVideoParam;
+import com.fs.course.service.IFsBlackTalentService;
+import io.swagger.annotations.Api;
+import io.swagger.annotations.ApiOperation;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.web.bind.annotation.*;
+
+import java.util.Date;
+import java.util.Map;
+
+@Api("达人或短视频被拉黑举报接口")
+@RestController
+@RequestMapping("/app/blackTalent")
+public class FsBlackTalentController extends AppBaseController{
+    @Autowired
+    private IFsBlackTalentService blackTalentService;
+    @ApiOperation("拉黑达人")
+    @PostMapping("/addBlackTalent")
+    public R addBlackTalent(@RequestBody FsBlackTalentParam blackTalentParam) {
+        String userId = getUserId();
+        FsBlackTalent fsBlackTalent = new FsBlackTalent();
+        fsBlackTalent.setUserId(Long.parseLong(userId));
+        fsBlackTalent.setCreatTime(new Date());
+        fsBlackTalent.setTalentId(blackTalentParam.getTalentId());
+        fsBlackTalent.setType(blackTalentParam.getType());
+        fsBlackTalent.setStyle("1");
+        if (blackTalentService.addBlack(fsBlackTalent)>0){
+            return R.ok();
+        }
+        return R.error();
+    }
+
+    @ApiOperation("拉黑视频")
+    @PostMapping("/addBlackVideo")
+    public R addBlackTalent(@RequestBody FsBlackVideoParam blackVideoParam) {
+        String userId = getUserId();
+        FsBlackTalent fsBlackTalent = new FsBlackTalent();
+        fsBlackTalent.setUserId(Long.parseLong(userId));
+        fsBlackTalent.setCreatTime(new Date());
+        fsBlackTalent.setVideoId(blackVideoParam.getVideoId());
+        fsBlackTalent.setType(blackVideoParam.getType());
+        fsBlackTalent.setStyle("2");
+        if (blackTalentService.addBlack(fsBlackTalent)>0){
+            return R.ok();
+        }
+        return R.error();
+    }
+
+    @ApiOperation("举报达人")
+    @PostMapping("/addReportTalent")
+    public R addReportTalent(@RequestBody FsBlackTalentParam blackTalentParam) {
+        String userId = getUserId();
+        FsBlackTalent fsBlackTalent = new FsBlackTalent();
+        fsBlackTalent.setUserId(Long.parseLong(userId));
+        fsBlackTalent.setCreatTime(new Date());
+        fsBlackTalent.setTalentId(blackTalentParam.getTalentId());
+        fsBlackTalent.setType(blackTalentParam.getType());
+        fsBlackTalent.setReportDesc(blackTalentParam.getReportDesc());
+        fsBlackTalent.setPhone(blackTalentParam.getPhone());
+        fsBlackTalent.setUrls(blackTalentParam.getUrls());
+        fsBlackTalent.setTemplateId(blackTalentParam.getTemplateId());
+        fsBlackTalent.setTradeImage(blackTalentParam.getTradeImage());
+        fsBlackTalent.setStyle("1");
+        fsBlackTalent.setIsAudit("0");
+
+        if (blackTalentService.addBlack(fsBlackTalent)>0){
+            return R.ok();
+        }
+        return R.error();
+    }
+
+    @ApiOperation("举报视频")
+    @PostMapping("/addReportVideo")
+    public R addReportVideo(@RequestBody FsBlackVideoParam blackVideoParam) {
+        String userId = getUserId();
+        FsBlackTalent fsBlackTalent = new FsBlackTalent();
+        fsBlackTalent.setUserId(Long.parseLong(userId));
+        fsBlackTalent.setCreatTime(new Date());
+        fsBlackTalent.setVideoId(blackVideoParam.getVideoId());
+        fsBlackTalent.setType(blackVideoParam.getType());
+        fsBlackTalent.setReportDesc(blackVideoParam.getReportDesc());
+        fsBlackTalent.setPhone(blackVideoParam.getPhone());
+        fsBlackTalent.setUrls(blackVideoParam.getUrls());
+        fsBlackTalent.setTemplateId(blackVideoParam.getTemplateId());
+        fsBlackTalent.setStyle("2");
+        fsBlackTalent.setIsAudit("0");
+
+        if (blackTalentService.addBlack(fsBlackTalent)>0){
+            return R.ok();
+        }
+        return R.error();
+    }
+    @ApiOperation("取消拉黑")
+    @PostMapping("/cancelBlack")
+    public R cancelBlack(@RequestBody Map<String,String> map){
+        String userId = getUserId();
+        String videoId = map.get("videoId");
+        String talentId = map.get("talentId");
+        if (StringUtils.isNotEmpty(videoId)){
+            blackTalentService.deleteFsBlackVideo(userId,videoId);
+            return R.ok();
+        }
+        if (StringUtils.isNotEmpty(talentId)){
+            blackTalentService.deleteFsBlackTalent(userId,talentId);
+            return R.ok();
+        }
+        return R.error("参数错误");
+    }
+    @ApiOperation("获取拉黑获取报的达人及视频")
+    @GetMapping("/getBlack")
+    public TableDataInfo getBlack(FsBlackAndReportParam blackAndReportParam){
+        return null;
+    }
+}

+ 56 - 0
fs-user-app/src/main/java/com/fs/app/controller/FsThirdDeviceDataController.java

@@ -0,0 +1,56 @@
+package com.fs.app.controller;
+
+import com.fs.app.annotation.Login;
+import com.fs.common.core.domain.R;
+import com.fs.his.domain.FsThirdDeviceData;
+import com.fs.his.service.IFsThirdDeviceDataService;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.web.bind.annotation.*;
+
+import java.util.List;
+
+@RestController
+@RequestMapping("/app/thirdDeviceData")
+public class FsThirdDeviceDataController extends  AppBaseController {
+    @Autowired
+    private IFsThirdDeviceDataService fsThirdDeviceDataService;
+
+    /**
+     * 新增三方设备健康数据
+     */
+    @Login
+    @PostMapping("/add")
+    public R add(@RequestBody FsThirdDeviceData fsThirdDeviceData)
+    {
+        String userId = getUserId();
+        fsThirdDeviceData.setUserId(Long.valueOf(userId));
+        fsThirdDeviceDataService.insertFsThirdDeviceData(fsThirdDeviceData);
+        return R.ok();
+    }
+
+    /**
+     * 删除三方设备健康数据
+     */
+    @Login
+    @DeleteMapping("/{ids}")
+    public R remove(@PathVariable Long[] ids)
+    {
+        fsThirdDeviceDataService.deleteFsThirdDeviceDataByIds(ids);
+        return R.ok();
+    }
+
+    /**
+     * 查询三方设备健康数据列表
+     */
+    @Login
+    @GetMapping("/list")
+    public R list(FsThirdDeviceData fsThirdDeviceData)
+    {
+        String userId = getUserId();
+        fsThirdDeviceData.setUserId(Long.valueOf(userId));
+        startPage();
+        List<FsThirdDeviceData> list = fsThirdDeviceDataService.selectFsThirdDeviceDataList(fsThirdDeviceData);
+        return R.ok().put("data", list);
+    }
+
+}

+ 11 - 5
fs-user-app/src/main/java/com/fs/app/controller/TalentController.java

@@ -14,10 +14,7 @@ import com.fs.course.param.FsUserTalentFansParam;
 import com.fs.course.param.FsUserTalentFollowParam;
 import com.fs.course.param.FsUserVideoAddParam;
 import com.fs.course.param.FsUserVideoListUParam;
-import com.fs.course.service.IFsUserTalentFollowService;
-import com.fs.course.service.IFsUserTalentService;
-import com.fs.course.service.IFsUserVideoService;
-import com.fs.course.service.IFsUserVideoTagsService;
+import com.fs.course.service.*;
 import com.fs.course.vo.FsUserVideoListUVO;
 import com.fs.course.vo.FsUserVideoTagsPVO;
 import com.fs.his.domain.FsUser;
@@ -62,6 +59,8 @@ public class TalentController extends  AppBaseController{
     private IFsUserVideoService fsUserVideoService;
     @Autowired
     private IFsUserVideoTagsService fsUserVideoTagsService;
+    @Autowired
+    private IFsVideoCollectionService fsVideoCollectionService;
 
     private static final String VIDEO_UPLOAD_DIR = "C:\\fs\\uploadPath\\talent\\video";  // 上传目录
     private static final String FRAME_OUTPUT_DIR = "C:\\fs\\uploadPath\\talent\\frame";  // 输出帧的目录
@@ -253,7 +252,14 @@ public class TalentController extends  AppBaseController{
         PageHelper.startPage(param.getPageNum(), param.getPageSize());
         boolean oneSelf = userId == param.getUserId();
         List<FsUserVideoListUVO> list = fsUserVideoService.selectFsUserVideoListUVOByUser(fsUserTalent.getTalentId(),oneSelf,userId);
-
+        for (FsUserVideoListUVO fsUserVideoListUVO : list) {
+            int i = fsVideoCollectionService.selectVideoCountByVideId(Long.parseLong(fsUserVideoListUVO.getId()));
+            if (i>0){
+                fsUserVideoListUVO.setIsInCollection(true);
+            }else {
+                fsUserVideoListUVO.setIsInCollection(false);
+            }
+        }
         PageInfo<FsUserVideoListUVO> listPageInfo=new PageInfo<>(list);
         return R.ok().put("data",listPageInfo);
     }