You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
12 lines
482 B
12 lines
482 B
package org.ros.chatto.repository;
|
|
|
|
import org.ros.chatto.model.UserSession;
|
|
import org.springframework.data.jpa.repository.JpaRepository;
|
|
import org.springframework.data.jpa.repository.Query;
|
|
import org.springframework.stereotype.Repository;
|
|
|
|
@Repository
|
|
public interface UserSessionRepository extends JpaRepository<UserSession, Long> {
|
|
@Query("select us from UserSession us join fetch us.user where us.user.userName = ?1 ")
|
|
public UserSession findByUserName(String userName);
|
|
}
|