|
@@ -4,7 +4,11 @@ import java.util.List;
|
|
|
|
|
|
import org.springframework.data.jpa.repository.JpaRepository;
|
|
|
import org.springframework.data.jpa.repository.JpaSpecificationExecutor;
|
|
|
+import org.springframework.data.jpa.repository.Modifying;
|
|
|
+import org.springframework.data.jpa.repository.Query;
|
|
|
+import org.springframework.data.repository.query.Param;
|
|
|
import org.springframework.data.repository.query.QueryByExampleExecutor;
|
|
|
+import org.springframework.transaction.annotation.Transactional;
|
|
|
|
|
|
import cn.com.qmth.examcloud.core.examwork.dao.entity.ExamSpecialSettingsEntity;
|
|
|
|
|
@@ -18,4 +22,9 @@ public interface ExamSpecialSettingsRepo
|
|
|
|
|
|
List<ExamSpecialSettingsEntity> findAllByExamIdAndCourseIdIsNullAndOrgIdIsNotNull(Long examId);
|
|
|
|
|
|
+
|
|
|
+ @Transactional
|
|
|
+ @Modifying
|
|
|
+ @Query("update ExamSpecialSettingsEntity set examEnable = :examEnable where examId = :examId")
|
|
|
+ void updateExamEnableByExamId(@Param("examId") long examId, @Param("examEnable") Boolean examEnable);
|
|
|
}
|