package io.gmss.fiscad.repositories.metadata;

import io.gmss.fiscad.entities.metadata.MobileDataUniteLogement;
import io.gmss.fiscad.entities.metadata.MobileDataUpload;
import org.springframework.data.jpa.repository.JpaRepository;

import java.util.List;
import java.util.Optional;

public interface MobileDataUploadRepository extends JpaRepository<MobileDataUpload, Long> {
    //Optional<MobileDataUpload> findByUploadPayLoad_TerminalIdAndUploadPayLoad_ExternalKey(Long terminalId,Long externalKey);
    List<MobileDataUpload> findAllByTraiterIsFalseAndTerminalId(Long TerminalId);
    Optional<MobileDataUpload> findFirstByTerminalIdAndEnqueteExternalKey(Long terminalId, Long ExternalKey);

}
