package it.micegroup.gestioneferie.configurazionepf.repository;

import org.springframework.stereotype.Repository;

import java.util.Optional;
import java.util.Collection;

import org.springframework.data.jpa.repository.Query;
import org.springframework.data.jpa.repository.config.EnableJpaRepositories;
import it.micegroup.gestioneferie.configurazionepf.entity.DregolePianiFeriePk;
import it.micegroup.gestioneferie.libs.repository.BaseRepository;

@Repository
@EnableJpaRepositories
public interface DregolePianiFeriePkRepository extends BaseRepository<DregolePianiFeriePk, Long> {

	Optional<DregolePianiFeriePk> findBySequIdRegolePianiFeriePk(Long id);

	@Query("DELETE FROM DregolePianiFeriePk WHERE sequIdRegolePianiFeriePk IN ?1")
	void deleteByIdIn(Collection<Long> ids);
}
