From 69c10fed80f4546d77876a1d21d0b8ad03f0e197 Mon Sep 17 00:00:00 2001 From: liuchengqian Date: Tue, 10 Jan 2023 14:02:20 +0800 Subject: [PATCH] =?UTF-8?q?=E5=88=A0=E9=99=A4=E6=97=A0=E7=94=A8=E6=95=B0?= =?UTF-8?q?=E6=8D=AE=E8=A1=A8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../com/xkrs/dao/ShanDongFirePointDao.java | 33 -- .../model/entity/ShanDongFirePointEntity.java | 292 ------------------ 2 files changed, 325 deletions(-) delete mode 100644 src/main/java/com/xkrs/dao/ShanDongFirePointDao.java delete mode 100644 src/main/java/com/xkrs/model/entity/ShanDongFirePointEntity.java diff --git a/src/main/java/com/xkrs/dao/ShanDongFirePointDao.java b/src/main/java/com/xkrs/dao/ShanDongFirePointDao.java deleted file mode 100644 index 0811740..0000000 --- a/src/main/java/com/xkrs/dao/ShanDongFirePointDao.java +++ /dev/null @@ -1,33 +0,0 @@ -package com.xkrs.dao; - -import com.xkrs.model.entity.ShanDongFirePointEntity; -import org.springframework.data.jpa.repository.JpaRepository; -import org.springframework.data.jpa.repository.JpaSpecificationExecutor; -import org.springframework.data.jpa.repository.Modifying; -import org.springframework.data.jpa.repository.Query; -import org.springframework.stereotype.Component; - -import java.util.List; - -@Component -public interface ShanDongFirePointDao extends JpaRepository, JpaSpecificationExecutor { - - /** - * 根据火点编码查询火点信息 - * - * @param fireCode - * @return - */ - ShanDongFirePointEntity findByFireCode(String fireCode); - - @Query(value = "SELECT * FROM fire_point_shandong WHERE longitude = ?1 AND latitude = ?2 AND street_code = ?3 AND satellite_time = ?4 AND satellite_type = ?5 AND land_type = ?6", nativeQuery = true) - List findDuplicatedData(double longitude, double latitude, String streetCode, String satelliteTime, String satelliteType, String landType); - - /** - * 在山东临时火点表中根据火点编码修改审核状态 - */ - @Modifying(clearAutomatically = true) - @Query(value = "UPDATE fire_point_shandong SET verify_state = ?2 WHERE fire_code = ?1", nativeQuery = true) - void updateVerifyStateByFireCode(String fireCode, String verifyState); - -} diff --git a/src/main/java/com/xkrs/model/entity/ShanDongFirePointEntity.java b/src/main/java/com/xkrs/model/entity/ShanDongFirePointEntity.java deleted file mode 100644 index 97ab427..0000000 --- a/src/main/java/com/xkrs/model/entity/ShanDongFirePointEntity.java +++ /dev/null @@ -1,292 +0,0 @@ -package com.xkrs.model.entity; - -import javax.persistence.*; -import java.io.Serializable; - -/** - * @author XinYi Song - */ -@Entity -@Table(name = "fire_point_shandong") -public class ShanDongFirePointEntity implements Serializable { - - /** - * 指定主键,建立自增序列,主键值取自序列 - */ - @Id - @GeneratedValue(strategy = GenerationType.SEQUENCE, generator = "fire_point_shandong_seq_gen") - @SequenceGenerator(name = "fire_point_shandong_seq_gen", sequenceName = "fire_point_shandong_id_seq", allocationSize = 1) - private Integer id; - - /** - * 火点编码 - */ - @Column(length = 32, unique = true, columnDefinition = "varchar(32)") - private String fireCode; - - /** - * 经度 - */ - private double longitude; - - /** - * 纬度 - */ - private double latitude; - - /** - * 省市区的编码 - */ - @Column(length = 32, columnDefinition = "varchar(32)") - private String countyCode; - - /** - * 省市区的名称 - */ - @Column(columnDefinition = "varchar(64)") - private String countyName; - - /** - * 卫星监测的时间 - */ - private String satelliteTime; - - /** - * 卫星的类型 - */ - @Column(columnDefinition = "varchar(64)") - private String satelliteType; - - /** - * 植被类型 - */ - @Column(columnDefinition = "varchar(64)") - private String landType; - - /** - * 添加的时间 - */ - private String addTime; - - /** - * 置信度 - */ - @Column(length = 32, columnDefinition = "varchar(32)") - private String confidence; - - /** - * 详细地址 - */ - private String firePointAddress; - - /** - * 火点状态 0 发现 1预警 2核查 -1,3结案 - */ - @Column(length = 32, columnDefinition = "varchar(32)") - private String fireType; - - /** - * 当前火点的图片 - */ - private String fireImage; - - /** - * 卫星影像图片 - */ - private String satelliteImage; - - /** - * 火点前的图片 - */ - private String beforeFireImage; - - /** - * 火点后的图片 - */ - private String afterFireImage; - - /** - * 街道编码 - */ - @Column(length = 65, columnDefinition = "varchar(65)") - private String streetCode; - - @Column(length = 65, columnDefinition = "varchar(85)") - private String streetName; - - /** - * 0:未审核 - * 1:审核通过 - * 2:审核不通过 - */ - @Column(length = 65, columnDefinition = "varchar(85)") - private String verifyState; - - public ShanDongFirePointEntity() { - } - - public Integer getId() { - return id; - } - - public void setId(Integer id) { - this.id = id; - } - - public String getFireCode() { - return fireCode; - } - - public void setFireCode(String fireCode) { - this.fireCode = fireCode; - } - - public double getLongitude() { - return longitude; - } - - public void setLongitude(double longitude) { - this.longitude = longitude; - } - - public double getLatitude() { - return latitude; - } - - public void setLatitude(double latitude) { - this.latitude = latitude; - } - - public String getCountyCode() { - return countyCode; - } - - public void setCountyCode(String countyCode) { - this.countyCode = countyCode; - } - - public String getCountyName() { - return countyName; - } - - public void setCountyName(String countyName) { - this.countyName = countyName; - } - - public String getSatelliteTime() { - return satelliteTime; - } - - public void setSatelliteTime(String satelliteTime) { - this.satelliteTime = satelliteTime; - } - - public String getSatelliteType() { - return satelliteType; - } - - public void setSatelliteType(String satelliteType) { - this.satelliteType = satelliteType; - } - - public String getLandType() { - return landType; - } - - public void setLandType(String landType) { - this.landType = landType; - } - - public String getAddTime() { - return addTime; - } - - public void setAddTime(String addTime) { - this.addTime = addTime; - } - - public String getConfidence() { - return confidence; - } - - public void setConfidence(String confidence) { - this.confidence = confidence; - } - - public String getFirePointAddress() { - return firePointAddress; - } - - public void setFirePointAddress(String firePointAddress) { - this.firePointAddress = firePointAddress; - } - - public String getFireType() { - return fireType; - } - - public void setFireType(String fireType) { - this.fireType = fireType; - } - - public String getFireImage() { - return fireImage; - } - - public void setFireImage(String fireImage) { - this.fireImage = fireImage; - } - - public String getSatelliteImage() { - return satelliteImage; - } - - public void setSatelliteImage(String satelliteImage) { - this.satelliteImage = satelliteImage; - } - - public String getBeforeFireImage() { - return beforeFireImage; - } - - public void setBeforeFireImage(String beforeFireImage) { - this.beforeFireImage = beforeFireImage; - } - - public String getAfterFireImage() { - return afterFireImage; - } - - public void setAfterFireImage(String afterFireImage) { - this.afterFireImage = afterFireImage; - } - - public String getStreetCode() { - return streetCode; - } - - public void setStreetCode(String streetCode) { - this.streetCode = streetCode; - } - - public String getStreetName() { - return streetName; - } - - public void setStreetName(String streetName) { - this.streetName = streetName; - } - - public String getVerifyState() { - return verifyState; - } - - public void setVerifyState(String verifyState) { - this.verifyState = verifyState; - } - - @Override - public String toString() { - return "ShanDongFirePointEntity{" + "id=" + id + ", fireCode='" + fireCode + '\'' + ", longitude=" + longitude + ", latitude=" + latitude + ", countyCode='" + countyCode + '\'' + ", countyName='" + countyName + '\'' + ", satelliteTime='" + satelliteTime + '\'' + ", satelliteType='" + satelliteType + '\'' + ", landType='" + landType + '\'' + ", addTime='" + addTime + '\'' + ", confidence='" + confidence + '\'' + ", firePointAddress='" + firePointAddress + '\'' + ", fireType='" + fireType + '\'' + ", fireImage='" + fireImage + '\'' + ", satelliteImage='" + satelliteImage + '\'' + ", beforeFireImage='" + beforeFireImage + '\'' + ", afterFireImage='" + afterFireImage + '\'' + ", streetCode='" + streetCode + '\'' + ", streetName='" + streetName + '\'' + ", verifyState='" + verifyState + '\'' + '}'; - } -}