source: src/main/java/com/example/skychasemk/repository/NotificationRepository.java

Last change on this file was 8a947b9, checked in by ste08 <sjovanoska@…>, 3 months ago

Notifications + triggers!

  • Property mode set to 100644
File size: 565 bytes
Line 
1package com.example.skychasemk.repository;
2
3import com.example.skychasemk.model.Notification;
4import com.example.skychasemk.model.Wishlist;
5import org.springframework.data.jpa.repository.JpaRepository;
6import org.springframework.data.jpa.repository.Query;
7import org.springframework.data.repository.query.Param;
8
9import java.util.List;
10
11
12public interface NotificationRepository extends JpaRepository<Notification, Integer> {
13 @Query("SELECT n FROM Notification n WHERE n.userId = :userId")
14 List<Notification> findByUserId(@Param("userId") Integer userId);
15}
Note: See TracBrowser for help on using the repository browser.