package com.jasamedika.medifirst2000.dao;

import org.springframework.data.jpa.repository.Query;
import org.springframework.data.repository.PagingAndSortingRepository;
import org.springframework.data.repository.query.Param;
import org.springframework.stereotype.Repository;

import com.jasamedika.medifirst2000.entities.StrukRetur;

/**
 * Repository class for Ruangan
 * 
 * @author Askur
 */
@Repository("StrukReturDao")
public interface StrukReturDao extends PagingAndSortingRepository<StrukRetur, String> {

	@Query("select count(p.id) from StrukRetur p where month(p.tglRetur)=:monthNow and year(p.tglRetur)=:yearNow ")
	Integer getCountByMonthAndYear(@Param("monthNow") Integer monthNow, @Param("yearNow") Integer yearNow);
	
}
