From 7ea9f1ccefb49a5821d136ac2276a329a2c77738 Mon Sep 17 00:00:00 2001 From: Pekka Helenius Date: Mon, 12 Oct 2020 21:34:19 +0300 Subject: [PATCH] BookHash: add findByBookId method Signed-off-by: Pekka Helenius --- .../com/fjordtek/bookstore/model/book/BookHashRepository.java | 2 ++ 1 file changed, 2 insertions(+) diff --git a/bookstore/src/main/java/com/fjordtek/bookstore/model/book/BookHashRepository.java b/bookstore/src/main/java/com/fjordtek/bookstore/model/book/BookHashRepository.java index 097f0c6..1d5eb72 100644 --- a/bookstore/src/main/java/com/fjordtek/bookstore/model/book/BookHashRepository.java +++ b/bookstore/src/main/java/com/fjordtek/bookstore/model/book/BookHashRepository.java @@ -26,6 +26,8 @@ public interface BookHashRepository extends CrudRepository { BookHash findByHashId(String bookHashId); + BookHash findByBookId(@Param("bookid") Long bookId); + /* * We need to override native delete method. * This is a native query, do not unnecessarily validate it.