2021-07-13 10:18:08 +08:00
|
|
|
package com.xkrs.dao;
|
|
|
|
|
|
|
|
import com.xkrs.model.entity.FirePointEntity;
|
|
|
|
import org.springframework.data.jpa.repository.JpaRepository;
|
2021-07-16 08:52:20 +08:00
|
|
|
import org.springframework.data.jpa.repository.JpaSpecificationExecutor;
|
2021-07-15 15:22:23 +08:00
|
|
|
import org.springframework.data.jpa.repository.Query;
|
2021-07-13 10:18:08 +08:00
|
|
|
import org.springframework.stereotype.Component;
|
|
|
|
|
2021-07-15 15:22:23 +08:00
|
|
|
import java.util.List;
|
|
|
|
|
2021-07-13 10:18:08 +08:00
|
|
|
/**
|
|
|
|
* @author XinYi Song
|
|
|
|
*/
|
|
|
|
@Component
|
2021-07-16 08:52:20 +08:00
|
|
|
public interface FirePointDao extends JpaRepository<FirePointEntity,Long>, JpaSpecificationExecutor<FirePointEntity> {
|
2021-07-15 15:22:23 +08:00
|
|
|
|
|
|
|
/**
|
|
|
|
* 查询今天的火点信息
|
|
|
|
* @param addTime
|
|
|
|
* @return
|
|
|
|
*/
|
|
|
|
@Query(value = "select * from fire_point where add_time like CONCAT('%',:addTime,'%')",nativeQuery = true)
|
|
|
|
List<FirePointEntity> selectTodayFirePoint(String addTime);
|
2021-07-16 08:52:20 +08:00
|
|
|
|
|
|
|
/**
|
|
|
|
* 根据火点编码查询火点信息
|
|
|
|
* @param fireCode
|
|
|
|
* @return
|
|
|
|
*/
|
|
|
|
FirePointEntity findByFireCode(String fireCode);
|
2021-07-13 10:18:08 +08:00
|
|
|
}
|