package com.example.Vezba.repository;

import com.example.Vezba.model.Lajk;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.data.jpa.repository.Query;

import java.util.List;

public interface LajkRepository extends JpaRepository<Lajk,Integer> {
    @Query("SELECT l FROM Lajk l WHERE l.idOglasa=?1 AND l.idKorisnika=?2")
    List<Lajk> findByIdOglasaByIdKorisnika(Integer idOglasa, Integer idKorisnika);
}
