StudentLoanManagement
ItemRepository.java
Go to the documentation of this file.
1package com.student_loan.repository;
2
3import java.util.List;
4
5import org.springframework.data.jpa.repository.JpaRepository;
6import org.springframework.stereotype.Repository;
7import com.student_loan.model.Item;
8
9@Repository
10public interface ItemRepository extends JpaRepository<Item, Long> {
11 Item findByName(String name);
12 List<Item> findByOwner(Long ownerId);
13
14 List<Item> findByStatus(Item.ItemStatus status);
15}
List< Item > findByOwner(Long ownerId)
List< Item > findByStatus(Item.ItemStatus status)