feat: 新增碎片更新和会话查询的Service实现

- StudyReportFragmentsService 接口新增 updateFragments 和 getFragmentsBySession 方法
- ServiceImpl 实现碎片更新(校验存在性后更新)和按会话编号查询碎片列表
This commit is contained in:
2026-05-30 15:50:34 +08:00
parent e1cd5d5b82
commit 487b38e8b0
2 changed files with 29 additions and 0 deletions
@@ -1,10 +1,13 @@
package com.guo.learningprogresstracker.service;
import com.guo.learningprogresstracker.dto.request.CreateFragmentsRequest;
import com.guo.learningprogresstracker.dto.request.UpdateFragmentsRequest;
import com.guo.learningprogresstracker.entity.StudyReportFragmentsEntity;
import com.baomidou.mybatisplus.extension.service.IService;
import com.guo.learningprogresstracker.exception.NotFindEntitiesException;
import java.util.List;
/**
* @author guo
* @description 针对表【study_report_fragments(记录学习过程中的学习内容报告残片)】的数据库操作Service
@@ -13,4 +16,8 @@ import com.guo.learningprogresstracker.exception.NotFindEntitiesException;
public interface StudyReportFragmentsService extends IService<StudyReportFragmentsEntity> {
void createFragments(CreateFragmentsRequest request) throws NotFindEntitiesException;
void updateFragments(Integer id, UpdateFragmentsRequest request) throws NotFindEntitiesException;
List<StudyReportFragmentsEntity> getFragmentsBySession(String sessionNum);
}