package com.gyee.wisdom.dao.sql.Windturbine.repsoitory;

import com.gyee.wisdom.dao.sql.Windturbine.entity.WindturbineEntity;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.data.jpa.repository.JpaSpecificationExecutor;
import org.springframework.stereotype.Repository;

import java.util.List;


@Repository
public interface WindturbineRepository extends JpaRepository<WindturbineEntity, String>, JpaSpecificationExecutor {

  /*  ModelEntity findFirstByUserName(String userName);*/
  List<WindturbineEntity> findByWindPowerStationId(String stationId);

  List<WindturbineEntity> findByLineId(String lineId);

  List<WindturbineEntity> findByProjectId(String projectId);

  List<WindturbineEntity> findByModelId(String modelId);
  List<WindturbineEntity> findByModelIdIn(String[] modelIds);

  List<WindturbineEntity> findByWindPowerStationIdAndModelId(String stationId, String modelId);

}
