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.DetailPengkajianAwal;

@Repository("DetailHeadPengkajianAwalDao")
public interface DetailPengkajianAwalDao extends PagingAndSortingRepository<DetailPengkajianAwal, String>{

	@Query("select model from DetailPengkajianAwal model "
			+ "left join model.pengkajianAwal a "
			+ "left join model.pengkajianAwalTransaksi b "
			+ "where a.id=:id and b.noRec=:noRec")
	DetailPengkajianAwal getDetailPengkajianAwal(
			@Param("id") Integer id, @Param("noRec") String noRec);
	
}
