menu controller et repo
This commit is contained in:
parent
f164000cc8
commit
90498a2cd1
3 changed files with 107 additions and 2 deletions
|
|
@ -1,4 +1,17 @@
|
|||
package fr.organizee.repository;
|
||||
|
||||
public interface MenuRepository {
|
||||
import fr.organizee.model.Contact;
|
||||
import fr.organizee.model.Menu;
|
||||
import org.springframework.data.jpa.repository.JpaRepository;
|
||||
import org.springframework.data.jpa.repository.Query;
|
||||
import org.springframework.data.repository.query.Param;
|
||||
import org.springframework.stereotype.Repository;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
@Repository
|
||||
public interface MenuRepository extends JpaRepository <Menu, Integer> {
|
||||
|
||||
@Query(value = "select * from menu where team_id = :team_id", nativeQuery = true)
|
||||
List<Menu> FindMenusByTeam(@Param("team_id") int team_id);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue