package bj.pranie.dao;

import bj.pranie.entity.User;
import org.springframework.data.repository.CrudRepository;
import org.springframework.transaction.annotation.Transactional;

/**
 * Created by noon on 10.08.16.
 */
@Transactional
public interface UserDao extends CrudRepository<User, Long> {
    User findByEmail(String email);

    User findByUsername(String username);


}

@@ -17,16 +17,46 @@
 e.dao;%0A%0A
+import bj.pranie.entity.Room;%0A
 import b
@@ -77,16 +77,16 @@
 y.User;%0A
-
 import o
@@ -202,16 +202,40 @@
 ional;%0A%0A
+import java.util.List;%0A%0A
 /**%0A * C
@@ -423,11 +423,48 @@
 name);%0A%0A
+    List%3CUser%3E findByRoom(Room room);
 %0A%7D%0A

Add method to find user by room to UserDao.