update 教学班查询评价内容得问题

develop
hhb@hotmail.com 2 months ago
parent eb9fc54440
commit 07165e5e61

@ -34,8 +34,8 @@ public interface AppraiseRecordRepository extends CosmosRepository<AppraiseRecor
@Query("select c.id, c.praiseCount, c.score from Student as c where c.targetId = @targetId and c.academicYearId = @academicYearId and c.code = @code") @Query("select c.id, c.praiseCount, c.score from Student as c where c.targetId = @targetId and c.academicYearId = @academicYearId and c.code = @code")
List<AppraiseRecord> findScoreAndPraise(String targetId,String academicYearId,String code); List<AppraiseRecord> findScoreAndPraise(String targetId,String academicYearId,String code);
@Query("select * from Student as c where c.targetId in (@targetId) and c.classId =@classId and c.academicYearId = @academicYearId and c.code = @code") @Query("select * from Student as c where c.targetId in (@targetId) and c.classId in(@classId) and c.academicYearId = @academicYearId and c.code = @code")
List<AppraiseRecord> findAllRecord(List<String> targetId,String classId,String academicYearId,String code); List<AppraiseRecord> findAllRecord(List<String> targetId,List<String> classId,String academicYearId,String code);
/** /**
* *

@ -525,7 +525,7 @@ public class EvaluationServiceImpl implements EvaluationService {
// 批量查询评价记录 // 批量查询评价记录
List<AppraiseRecord> appraiseRecords = appraiseRecordRepository.findAllRecord( List<AppraiseRecord> appraiseRecords = appraiseRecordRepository.findAllRecord(
studentIds, classIds.get(0), academicYearId, String.format(PK.PK_APPRAISE_RECORD, schoolId) studentIds, classIds, academicYearId, String.format(PK.PK_APPRAISE_RECORD, schoolId)
); );
if (CollectionUtils.isEmpty(appraiseRecords)) { if (CollectionUtils.isEmpty(appraiseRecords)) {
throw new ServiceException(ErrorCode.OPERATION_ERROR.getCode(), "未找到对应的评价记录"); throw new ServiceException(ErrorCode.OPERATION_ERROR.getCode(), "未找到对应的评价记录");

Loading…
Cancel
Save