package com.uas.platform.b2b.dao;

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 com.uas.platform.b2b.model.SigninLog;

@Repository
public interface SigninLogDao extends JpaRepository<SigninLog, Long> {

	@Query("from SigninLog s where s.id=(select max(l.id) from SigninLog l where l.userUU = :userUU)")
	public SigninLog findLast(@Param("userUU") long userUU);
	
}
