package com.huimv.admin.device.dao.repo;

import com.huimv.admin.device.dao.entity.SysCameraAreaEntity;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.data.jpa.repository.JpaSpecificationExecutor;
import org.springframework.data.jpa.repository.Query;

import java.util.List;

public interface SysCameraAreaEntityRepo extends JpaRepository<SysCameraAreaEntity, Integer>, JpaSpecificationExecutor<SysCameraAreaEntity> {

    //
    @Query(nativeQuery = true,value = "SELECT * FROM sys_camera_area WHERE farm_id=?1")
    SysCameraAreaEntity getCameraIP(Integer farmId);
}