package com.bytesw.bytebot.repository;

import com.bytesw.bytebot.model.CalendarException;
import com.bytesw.bytebot.model.CalendarExceptionFull;
import com.bytesw.bytebot.model.enums.CalendarExceptionType;
import org.springframework.data.jpa.repository.JpaSpecificationExecutor;
import org.springframework.data.jpa.repository.Query;
import org.springframework.data.repository.CrudRepository;
import org.springframework.data.repository.query.Param;

import java.math.BigInteger;
import java.time.LocalDate;
import java.time.OffsetDateTime;
import java.util.List;
import java.util.Optional;

public interface CalendarExceptionFullRepository extends CrudRepository<CalendarExceptionFull, BigInteger>, JpaSpecificationExecutor<CalendarExceptionFull> {

    @Query("select s from CalendarExceptionFull s where s.calendarID = :calendarId")
    Optional<List<CalendarExceptionFull>> findByCalendarId(@Param("calendarId") String calendarId);

}
