/
dmuruz
/
Course_Service
Обзор
Документация
Войти
/
dmuruz
/
Course_Service
Код
Запросы
0
Задачи
Вики
Пакеты
0
Релизы
0
CI/CD
Аналитика
Безопасность
dev
src/main/java/org/example/dao/UserLessonRepository.java
17 строк
590 B
Danil Muruz
MVP
24 апр 2025, 09:39
24 апр 2025, 09:39
16b1c45
Код
Авторство
О чём код?
package org.example.dao; import org.example.model.UserLesson; import org.springframework.data.jpa.repository.JpaRepository; import org.springframework.stereotype.Repository; import java.util.List; import java.util.Optional; @Repository public interface UserLessonRepository extends JpaRepository<UserLesson, Long> { List<UserLesson> findByUserIdAndLesson_CourseId(Long userId, Long courseId); UserLesson findFirstByUserIdAndLesson_CourseIdAndStatusNot(Long userId, Long courseId, String status); Optional<UserLesson> findByUserIdAndLesson_Id(Long userId, Long lessonId); }