crops智慧农业
This commit is contained in:
@ -0,0 +1,123 @@
|
||||
package com.ruoyi.crops.domain;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import com.ruoyi.common.core.domain.BaseEntity;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.util.Date;
|
||||
|
||||
/**
|
||||
* 作物种植结构;
|
||||
* @author : http://www.chiner.pro
|
||||
* @date : 2023-4-24
|
||||
*/
|
||||
|
||||
public class CropStructure{
|
||||
/** id */
|
||||
|
||||
private Integer id ;
|
||||
/** 区域 */
|
||||
private String zone ;
|
||||
/** 时间 */
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
private Date imageDate ;
|
||||
/** 小麦面积 */
|
||||
private Double wheatArea ;
|
||||
/** 玉米面积 */
|
||||
private Double cornArea ;
|
||||
/** 花生面积 */
|
||||
private Double peanutArea ;
|
||||
/** 大豆面积 */
|
||||
private Double soybeanArea ;
|
||||
/** 其他面积 */
|
||||
private Double otherArea ;
|
||||
/** 总面积 */
|
||||
private Double toalArea ;
|
||||
|
||||
public Integer getId() {
|
||||
return id;
|
||||
}
|
||||
|
||||
public void setId(Integer id) {
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
public String getZone() {
|
||||
return zone;
|
||||
}
|
||||
|
||||
public void setZone(String zone) {
|
||||
this.zone = zone;
|
||||
}
|
||||
|
||||
public Date getImageDate() {
|
||||
return imageDate;
|
||||
}
|
||||
|
||||
public void setImageDate(Date imageDate) {
|
||||
this.imageDate = imageDate;
|
||||
}
|
||||
|
||||
public Double getWheatArea() {
|
||||
return wheatArea;
|
||||
}
|
||||
|
||||
public void setWheatArea(Double wheatArea) {
|
||||
this.wheatArea = wheatArea;
|
||||
}
|
||||
|
||||
public Double getCornArea() {
|
||||
return cornArea;
|
||||
}
|
||||
|
||||
public void setCornArea(Double cornArea) {
|
||||
this.cornArea = cornArea;
|
||||
}
|
||||
|
||||
public Double getPeanutArea() {
|
||||
return peanutArea;
|
||||
}
|
||||
|
||||
public void setPeanutArea(Double peanutArea) {
|
||||
this.peanutArea = peanutArea;
|
||||
}
|
||||
|
||||
public Double getSoybeanArea() {
|
||||
return soybeanArea;
|
||||
}
|
||||
|
||||
public void setSoybeanArea(Double soybeanArea) {
|
||||
this.soybeanArea = soybeanArea;
|
||||
}
|
||||
|
||||
public Double getOtherArea() {
|
||||
return otherArea;
|
||||
}
|
||||
|
||||
public void setOtherArea(Double otherArea) {
|
||||
this.otherArea = otherArea;
|
||||
}
|
||||
|
||||
public Double getToalArea() {
|
||||
return toalArea;
|
||||
}
|
||||
|
||||
public void setToalArea(Double toalArea) {
|
||||
this.toalArea = toalArea;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "CropStructure{" +
|
||||
"id=" + id +
|
||||
", zone='" + zone + '\'' +
|
||||
", imageDate=" + imageDate +
|
||||
", wheatArea=" + wheatArea +
|
||||
", cornArea=" + cornArea +
|
||||
", peanutArea=" + peanutArea +
|
||||
", soybeanArea=" + soybeanArea +
|
||||
", otherArea=" + otherArea +
|
||||
", toalArea=" + toalArea +
|
||||
'}';
|
||||
}
|
||||
}
|
@ -0,0 +1,319 @@
|
||||
package com.ruoyi.crops.domain;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
import java.util.Date;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import org.apache.commons.lang3.builder.ToStringBuilder;
|
||||
import org.apache.commons.lang3.builder.ToStringStyle;
|
||||
import com.ruoyi.common.annotation.Excel;
|
||||
import com.ruoyi.common.core.domain.BaseEntity;
|
||||
|
||||
/**
|
||||
* 作物综合数据对象 crops_comprehensive_data
|
||||
*
|
||||
* @author my
|
||||
* @date 2023-04-20
|
||||
*/
|
||||
public class CropsComprehensiveData extends BaseEntity
|
||||
{
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/** id */
|
||||
private Long id;
|
||||
|
||||
/** 镇耕地面积(万亩) */
|
||||
@Excel(name = "镇耕地面积(万亩)")
|
||||
private Float cultivatedArea;
|
||||
|
||||
/** 粮食总产(万吨) */
|
||||
@Excel(name = "粮食总产(万吨)")
|
||||
private Float foodstuffProduction;
|
||||
|
||||
/** 蔬菜种植面积(亩) */
|
||||
@Excel(name = "蔬菜种植面积(亩)")
|
||||
private Long vegetablePlantingArea;
|
||||
|
||||
/** 蔬菜总产(吨) */
|
||||
@Excel(name = "蔬菜总产(吨)")
|
||||
private Long vegetableProduction;
|
||||
|
||||
/** 农产品种类 */
|
||||
@Excel(name = "农产品种类")
|
||||
private Long type;
|
||||
|
||||
/** 农产品种植面积(亩) */
|
||||
@Excel(name = "农产品种植面积(亩)")
|
||||
private Long agriculturalPlantingArea;
|
||||
|
||||
/** 特色农业总产量(吨) */
|
||||
@Excel(name = "特色农业总产量(吨)")
|
||||
private Long agricultureProduction;
|
||||
|
||||
/** 特色农业年产值(万元) */
|
||||
@Excel(name = "特色农业年产值(万元)")
|
||||
private Long agricultureOutputVaule;
|
||||
|
||||
/** 总人口(人) */
|
||||
@Excel(name = "总人口(人)")
|
||||
private Long totalPopulation;
|
||||
|
||||
/** 占地面积(平方公里) */
|
||||
@Excel(name = "占地面积(平方公里)")
|
||||
private Float coverArea;
|
||||
|
||||
/** 示范大棚数量(个) */
|
||||
@Excel(name = "示范大棚数量(个)")
|
||||
private Long exampleGreenhouse;
|
||||
|
||||
/** 村居数量(个) */
|
||||
@Excel(name = "村居数量(个)")
|
||||
private Long rusticate;
|
||||
|
||||
/** 联合社耕地面积(万亩) */
|
||||
@Excel(name = "联合社耕地面积(万亩)")
|
||||
private Float cultivatedAlly;
|
||||
|
||||
/** 大棚数量(个) */
|
||||
@Excel(name = "大棚数量(个)")
|
||||
private Long greenhouse;
|
||||
|
||||
/** 农产品产值(万元) */
|
||||
@Excel(name = "农产品产值(万元)")
|
||||
private Long outputValue;
|
||||
|
||||
/** 庞家镇矢量边界 */
|
||||
@Excel(name = "庞家镇矢量边界")
|
||||
private String vectorBoundary;
|
||||
|
||||
/** 庞家镇村庄矢量边界 */
|
||||
@Excel(name = "庞家镇村庄矢量边界")
|
||||
private String villageVectorBoundary;
|
||||
|
||||
/** 图片 */
|
||||
private String img;
|
||||
|
||||
/** 创建人 */
|
||||
@Excel(name = "创建人")
|
||||
private String createdBy;
|
||||
|
||||
/** 创建时间 */
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@Excel(name = "创建时间", width = 30, dateFormat = "yyyy-MM-dd")
|
||||
private Date createdTime;
|
||||
|
||||
public void setId(Long id)
|
||||
{
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
public Long getId()
|
||||
{
|
||||
return id;
|
||||
}
|
||||
public void setCultivatedArea(Float cultivatedArea)
|
||||
{
|
||||
this.cultivatedArea = cultivatedArea;
|
||||
}
|
||||
|
||||
public Float getCultivatedArea()
|
||||
{
|
||||
return cultivatedArea;
|
||||
}
|
||||
public void setFoodstuffProduction(Float foodstuffProduction)
|
||||
{
|
||||
this.foodstuffProduction = foodstuffProduction;
|
||||
}
|
||||
|
||||
public Float getFoodstuffProduction()
|
||||
{
|
||||
return foodstuffProduction;
|
||||
}
|
||||
public void setVegetablePlantingArea(Long vegetablePlantingArea)
|
||||
{
|
||||
this.vegetablePlantingArea = vegetablePlantingArea;
|
||||
}
|
||||
|
||||
public Long getVegetablePlantingArea()
|
||||
{
|
||||
return vegetablePlantingArea;
|
||||
}
|
||||
public void setVegetableProduction(Long vegetableProduction)
|
||||
{
|
||||
this.vegetableProduction = vegetableProduction;
|
||||
}
|
||||
|
||||
public Long getVegetableProduction()
|
||||
{
|
||||
return vegetableProduction;
|
||||
}
|
||||
public void setType(Long type)
|
||||
{
|
||||
this.type = type;
|
||||
}
|
||||
|
||||
public Long getType()
|
||||
{
|
||||
return type;
|
||||
}
|
||||
public void setAgriculturalPlantingArea(Long agriculturalPlantingArea)
|
||||
{
|
||||
this.agriculturalPlantingArea = agriculturalPlantingArea;
|
||||
}
|
||||
|
||||
public Long getAgriculturalPlantingArea()
|
||||
{
|
||||
return agriculturalPlantingArea;
|
||||
}
|
||||
public void setAgricultureProduction(Long agricultureProduction)
|
||||
{
|
||||
this.agricultureProduction = agricultureProduction;
|
||||
}
|
||||
|
||||
public Long getAgricultureProduction()
|
||||
{
|
||||
return agricultureProduction;
|
||||
}
|
||||
public void setAgricultureOutputVaule(Long agricultureOutputVaule)
|
||||
{
|
||||
this.agricultureOutputVaule = agricultureOutputVaule;
|
||||
}
|
||||
|
||||
public Long getAgricultureOutputVaule()
|
||||
{
|
||||
return agricultureOutputVaule;
|
||||
}
|
||||
public void setTotalPopulation(Long totalPopulation)
|
||||
{
|
||||
this.totalPopulation = totalPopulation;
|
||||
}
|
||||
|
||||
public Long getTotalPopulation()
|
||||
{
|
||||
return totalPopulation;
|
||||
}
|
||||
public void setCoverArea(Float coverArea)
|
||||
{
|
||||
this.coverArea = coverArea;
|
||||
}
|
||||
|
||||
public Float getCoverArea()
|
||||
{
|
||||
return coverArea;
|
||||
}
|
||||
public void setExampleGreenhouse(Long exampleGreenhouse)
|
||||
{
|
||||
this.exampleGreenhouse = exampleGreenhouse;
|
||||
}
|
||||
|
||||
public Long getExampleGreenhouse()
|
||||
{
|
||||
return exampleGreenhouse;
|
||||
}
|
||||
public void setRusticate(Long rusticate)
|
||||
{
|
||||
this.rusticate = rusticate;
|
||||
}
|
||||
|
||||
public Long getRusticate()
|
||||
{
|
||||
return rusticate;
|
||||
}
|
||||
public void setCultivatedAlly(Float cultivatedAlly)
|
||||
{
|
||||
this.cultivatedAlly = cultivatedAlly;
|
||||
}
|
||||
|
||||
public Float getCultivatedAlly()
|
||||
{
|
||||
return cultivatedAlly;
|
||||
}
|
||||
public void setGreenhouse(Long greenhouse)
|
||||
{
|
||||
this.greenhouse = greenhouse;
|
||||
}
|
||||
|
||||
public Long getGreenhouse()
|
||||
{
|
||||
return greenhouse;
|
||||
}
|
||||
public void setOutputValue(Long outputValue)
|
||||
{
|
||||
this.outputValue = outputValue;
|
||||
}
|
||||
|
||||
public Long getOutputValue()
|
||||
{
|
||||
return outputValue;
|
||||
}
|
||||
public void setVectorBoundary(String vectorBoundary)
|
||||
{
|
||||
this.vectorBoundary = vectorBoundary;
|
||||
}
|
||||
|
||||
public String getVectorBoundary()
|
||||
{
|
||||
return vectorBoundary;
|
||||
}
|
||||
public void setVillageVectorBoundary(String villageVectorBoundary)
|
||||
{
|
||||
this.villageVectorBoundary = villageVectorBoundary;
|
||||
}
|
||||
|
||||
public String getVillageVectorBoundary()
|
||||
{
|
||||
return villageVectorBoundary;
|
||||
}
|
||||
public void setCreatedBy(String createdBy)
|
||||
{
|
||||
this.createdBy = createdBy;
|
||||
}
|
||||
|
||||
public String getCreatedBy()
|
||||
{
|
||||
return createdBy;
|
||||
}
|
||||
public void setCreatedTime(Date createdTime)
|
||||
{
|
||||
this.createdTime = createdTime;
|
||||
}
|
||||
|
||||
public Date getCreatedTime()
|
||||
{
|
||||
return createdTime;
|
||||
}
|
||||
|
||||
public String getImg() {
|
||||
return img;
|
||||
}
|
||||
|
||||
public void setImg(String img) {
|
||||
this.img = img;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "CropsComprehensiveData{" +
|
||||
"id=" + id +
|
||||
", cultivatedArea=" + cultivatedArea +
|
||||
", foodstuffProduction=" + foodstuffProduction +
|
||||
", vegetablePlantingArea=" + vegetablePlantingArea +
|
||||
", vegetableProduction=" + vegetableProduction +
|
||||
", type=" + type +
|
||||
", agriculturalPlantingArea=" + agriculturalPlantingArea +
|
||||
", agricultureProduction=" + agricultureProduction +
|
||||
", agricultureOutputVaule=" + agricultureOutputVaule +
|
||||
", totalPopulation=" + totalPopulation +
|
||||
", coverArea=" + coverArea +
|
||||
", exampleGreenhouse=" + exampleGreenhouse +
|
||||
", rusticate=" + rusticate +
|
||||
", cultivatedAlly=" + cultivatedAlly +
|
||||
", greenhouse=" + greenhouse +
|
||||
", outputValue=" + outputValue +
|
||||
", vectorBoundary='" + vectorBoundary + '\'' +
|
||||
", villageVectorBoundary='" + villageVectorBoundary + '\'' +
|
||||
", img='" + img + '\'' +
|
||||
", createdBy='" + createdBy + '\'' +
|
||||
", createdTime=" + createdTime +
|
||||
'}';
|
||||
}
|
||||
}
|
@ -0,0 +1,110 @@
|
||||
package com.ruoyi.crops.domain;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.util.Date;
|
||||
|
||||
/**
|
||||
* 作物旱情;
|
||||
* @author : http://www.chiner.pro
|
||||
* @date : 2023-4-24
|
||||
*/
|
||||
public class CropsDrought implements Serializable,Cloneable{
|
||||
/** id */
|
||||
private Integer id ;
|
||||
/** 区域 */
|
||||
private String zone ;
|
||||
/** 时间 */
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
private Date imageDate ;
|
||||
/** 严重干旱面积 */
|
||||
private Double severeArea ;
|
||||
/** 中度干旱面积 */
|
||||
private Double modArea ;
|
||||
/** 轻度干旱面积 */
|
||||
private Double mildArea ;
|
||||
/** 适宜面积 */
|
||||
private Double suitArea ;
|
||||
/** 湿润面积 */
|
||||
private Double humidArea ;
|
||||
|
||||
|
||||
public Integer getId() {
|
||||
return id;
|
||||
}
|
||||
|
||||
public void setId(Integer id) {
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
public String getZone() {
|
||||
return zone;
|
||||
}
|
||||
|
||||
public void setZone(String zone) {
|
||||
this.zone = zone;
|
||||
}
|
||||
|
||||
public Date getImageDate() {
|
||||
return imageDate;
|
||||
}
|
||||
|
||||
public void setImageDate(Date imageDate) {
|
||||
this.imageDate = imageDate;
|
||||
}
|
||||
|
||||
public Double getSevereArea() {
|
||||
return severeArea;
|
||||
}
|
||||
|
||||
public void setSevereArea(Double severeArea) {
|
||||
this.severeArea = severeArea;
|
||||
}
|
||||
|
||||
public Double getModArea() {
|
||||
return modArea;
|
||||
}
|
||||
|
||||
public void setModArea(Double modArea) {
|
||||
this.modArea = modArea;
|
||||
}
|
||||
|
||||
public Double getMildArea() {
|
||||
return mildArea;
|
||||
}
|
||||
|
||||
public void setMildArea(Double mildArea) {
|
||||
this.mildArea = mildArea;
|
||||
}
|
||||
|
||||
public Double getSuitArea() {
|
||||
return suitArea;
|
||||
}
|
||||
|
||||
public void setSuitArea(Double suitArea) {
|
||||
this.suitArea = suitArea;
|
||||
}
|
||||
|
||||
public Double getHumidArea() {
|
||||
return humidArea;
|
||||
}
|
||||
|
||||
public void setHumidArea(Double humidArea) {
|
||||
this.humidArea = humidArea;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "CropsDrought{" +
|
||||
"id=" + id +
|
||||
", zone='" + zone + '\'' +
|
||||
", imageDate=" + imageDate +
|
||||
", severeArea=" + severeArea +
|
||||
", modArea=" + modArea +
|
||||
", mildArea=" + mildArea +
|
||||
", suitArea=" + suitArea +
|
||||
", humidArea=" + humidArea +
|
||||
'}';
|
||||
}
|
||||
}
|
@ -0,0 +1,110 @@
|
||||
package com.ruoyi.crops.domain;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import com.ruoyi.common.core.domain.BaseEntity;
|
||||
|
||||
import java.util.Date;
|
||||
|
||||
/**
|
||||
* 作物长势;
|
||||
* @author : http://www.chiner.pro
|
||||
* @date : 2023-4-24
|
||||
*/
|
||||
public class CropsGrowth {
|
||||
/** id */
|
||||
private Integer id ;
|
||||
/** 区域 */
|
||||
private String zone ;
|
||||
/** 时间 */
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
private Date imageDate ;
|
||||
/** 长势差面积 */
|
||||
private Double poorArea ;
|
||||
/** 长势较差面积 */
|
||||
private Double lowArea ;
|
||||
/** 长势适中面积 */
|
||||
private Double mediumArea ;
|
||||
/** 长势较好面积 */
|
||||
private Double goodArea ;
|
||||
/** 长势好面积 */
|
||||
private Double excellentArea ;
|
||||
|
||||
public Integer getId() {
|
||||
return id;
|
||||
}
|
||||
|
||||
public void setId(Integer id) {
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
public String getZone() {
|
||||
return zone;
|
||||
}
|
||||
|
||||
public void setZone(String zone) {
|
||||
this.zone = zone;
|
||||
}
|
||||
|
||||
public Date getImageDate() {
|
||||
return imageDate;
|
||||
}
|
||||
|
||||
public void setImageDate(Date imageDate) {
|
||||
this.imageDate = imageDate;
|
||||
}
|
||||
|
||||
public Double getPoorArea() {
|
||||
return poorArea;
|
||||
}
|
||||
|
||||
public void setPoorArea(Double poorArea) {
|
||||
this.poorArea = poorArea;
|
||||
}
|
||||
|
||||
public Double getLowArea() {
|
||||
return lowArea;
|
||||
}
|
||||
|
||||
public void setLowArea(Double lowArea) {
|
||||
this.lowArea = lowArea;
|
||||
}
|
||||
|
||||
public Double getMediumArea() {
|
||||
return mediumArea;
|
||||
}
|
||||
|
||||
public void setMediumArea(Double mediumArea) {
|
||||
this.mediumArea = mediumArea;
|
||||
}
|
||||
|
||||
public Double getGoodArea() {
|
||||
return goodArea;
|
||||
}
|
||||
|
||||
public void setGoodArea(Double goodArea) {
|
||||
this.goodArea = goodArea;
|
||||
}
|
||||
|
||||
public Double getExcellentArea() {
|
||||
return excellentArea;
|
||||
}
|
||||
|
||||
public void setExcellentArea(Double excellentArea) {
|
||||
this.excellentArea = excellentArea;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "CropsGrowth{" +
|
||||
"id=" + id +
|
||||
", zone='" + zone + '\'' +
|
||||
", imageDate=" + imageDate +
|
||||
", poorArea=" + poorArea +
|
||||
", lowArea=" + lowArea +
|
||||
", mediumArea=" + mediumArea +
|
||||
", goodArea=" + goodArea +
|
||||
", excellentArea=" + excellentArea +
|
||||
'}';
|
||||
}
|
||||
}
|
||||
|
@ -0,0 +1,71 @@
|
||||
package com.ruoyi.crops.domain;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import org.springframework.format.annotation.DateTimeFormat;
|
||||
|
||||
import java.util.Date;
|
||||
|
||||
public class CropsYield {
|
||||
/** id */
|
||||
private Integer id ;
|
||||
/** 区域 */
|
||||
private String zone ;
|
||||
/** 时间 */
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
private Date imageDate ;
|
||||
/** 作物类型 */
|
||||
private String cropType ;
|
||||
/** 产量 */
|
||||
private Double yield ;
|
||||
|
||||
public Integer getId() {
|
||||
return id;
|
||||
}
|
||||
|
||||
public void setId(Integer id) {
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
public String getZone() {
|
||||
return zone;
|
||||
}
|
||||
|
||||
public void setZone(String zone) {
|
||||
this.zone = zone;
|
||||
}
|
||||
|
||||
public Date getImageDate() {
|
||||
return imageDate;
|
||||
}
|
||||
|
||||
public void setImageDate(Date imageDate) {
|
||||
this.imageDate = imageDate;
|
||||
}
|
||||
|
||||
public String getCropType() {
|
||||
return cropType;
|
||||
}
|
||||
|
||||
public void setCropType(String croptype) {
|
||||
this.cropType = croptype;
|
||||
}
|
||||
|
||||
public Double getYield() {
|
||||
return yield;
|
||||
}
|
||||
|
||||
public void setYield(Double yield) {
|
||||
this.yield = yield;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "CropsYield{" +
|
||||
"id=" + id +
|
||||
", zone='" + zone + '\'' +
|
||||
", imageDate=" + imageDate +
|
||||
", cropType='" + cropType + '\'' +
|
||||
", yield=" + yield +
|
||||
'}';
|
||||
}
|
||||
}
|
@ -0,0 +1,116 @@
|
||||
package com.ruoyi.crops.domain;
|
||||
|
||||
/**
|
||||
* 环境数据;
|
||||
* @author : http://www.chiner.pro
|
||||
* @date : 2023-4-27
|
||||
*/
|
||||
public class EnvironmentalData{
|
||||
/** id */
|
||||
private Integer id ;
|
||||
/**
|
||||
* 大棚编号
|
||||
*/
|
||||
private Integer greenhouseNumber;
|
||||
/** 土壤温度 */
|
||||
private Double soilTemperature ;
|
||||
/** 土壤湿度 */
|
||||
private Double soilHumidity ;
|
||||
/** 氮含量 */
|
||||
private Integer nitrogenContent ;
|
||||
/** 磷含量 */
|
||||
private Integer phosphorusContent ;
|
||||
/** 钾含量 */
|
||||
private Integer potassiumContent ;
|
||||
/** 空气温度 */
|
||||
private Double airTemperature ;
|
||||
/** 空气湿度 */
|
||||
private Double airHumidity ;
|
||||
|
||||
public Integer getId() {
|
||||
return id;
|
||||
}
|
||||
|
||||
public void setId(Integer id) {
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
public Integer getGreenhouseNumber() {
|
||||
return greenhouseNumber;
|
||||
}
|
||||
|
||||
public void setGreenhouseNumber(Integer greenhouseNumber) {
|
||||
this.greenhouseNumber = greenhouseNumber;
|
||||
}
|
||||
|
||||
public Double getSoilTemperature() {
|
||||
return soilTemperature;
|
||||
}
|
||||
|
||||
public void setSoilTemperature(Double soilTemperature) {
|
||||
this.soilTemperature = soilTemperature;
|
||||
}
|
||||
|
||||
public Double getSoilHumidity() {
|
||||
return soilHumidity;
|
||||
}
|
||||
|
||||
public void setSoilHumidity(Double soilHumidity) {
|
||||
this.soilHumidity = soilHumidity;
|
||||
}
|
||||
|
||||
public Integer getNitrogenContent() {
|
||||
return nitrogenContent;
|
||||
}
|
||||
|
||||
public void setNitrogenContent(Integer nitrogenContent) {
|
||||
this.nitrogenContent = nitrogenContent;
|
||||
}
|
||||
|
||||
public Integer getPhosphorusContent() {
|
||||
return phosphorusContent;
|
||||
}
|
||||
|
||||
public void setPhosphorusContent(Integer phosphorusContent) {
|
||||
this.phosphorusContent = phosphorusContent;
|
||||
}
|
||||
|
||||
public Integer getPotassiumContent() {
|
||||
return potassiumContent;
|
||||
}
|
||||
|
||||
public void setPotassiumContent(Integer potassiumContent) {
|
||||
this.potassiumContent = potassiumContent;
|
||||
}
|
||||
|
||||
public Double getAirTemperature() {
|
||||
return airTemperature;
|
||||
}
|
||||
|
||||
public void setAirTemperature(Double airTemperature) {
|
||||
this.airTemperature = airTemperature;
|
||||
}
|
||||
|
||||
public Double getAirHumidity() {
|
||||
return airHumidity;
|
||||
}
|
||||
|
||||
public void setAirHumidity(Double airHumidity) {
|
||||
this.airHumidity = airHumidity;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "EnvironmentalData{" +
|
||||
"id=" + id +
|
||||
", greenhouseNumber=" + greenhouseNumber +
|
||||
", soilTemperature=" + soilTemperature +
|
||||
", soilHumidity=" + soilHumidity +
|
||||
", nitrogenContent=" + nitrogenContent +
|
||||
", phosphorusContent=" + phosphorusContent +
|
||||
", potassiumContent=" + potassiumContent +
|
||||
", airTemperature=" + airTemperature +
|
||||
", airHumidity=" + airHumidity +
|
||||
'}';
|
||||
}
|
||||
}
|
@ -0,0 +1,59 @@
|
||||
package com.ruoyi.crops.domain;
|
||||
|
||||
/**
|
||||
* 大棚信息;
|
||||
* @author : http://www.chiner.pro
|
||||
* @date : 2023-4-27
|
||||
*/
|
||||
public class GreenhouseInformation {
|
||||
/** id */
|
||||
private Integer id ;
|
||||
/** 区域 */
|
||||
private String zone ;
|
||||
/** 经营模式 */
|
||||
private String managementModel ;
|
||||
/** 园区介绍 */
|
||||
private String introduce ;
|
||||
|
||||
public Integer getId() {
|
||||
return id;
|
||||
}
|
||||
|
||||
public void setId(Integer id) {
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
public String getZone() {
|
||||
return zone;
|
||||
}
|
||||
|
||||
public void setZone(String zone) {
|
||||
this.zone = zone;
|
||||
}
|
||||
|
||||
public String getManagementModel() {
|
||||
return managementModel;
|
||||
}
|
||||
|
||||
public void setManagementModel(String managementModel) {
|
||||
this.managementModel = managementModel;
|
||||
}
|
||||
|
||||
public String getIntroduce() {
|
||||
return introduce;
|
||||
}
|
||||
|
||||
public void setIntroduce(String introduce) {
|
||||
this.introduce = introduce;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "GreenhouseInformation{" +
|
||||
"id=" + id +
|
||||
", zone='" + zone + '\'' +
|
||||
", managementModel='" + managementModel + '\'' +
|
||||
", introduce='" + introduce + '\'' +
|
||||
'}';
|
||||
}
|
||||
}
|
@ -0,0 +1,21 @@
|
||||
package com.ruoyi.crops.domain;
|
||||
|
||||
import javax.xml.crypto.Data;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
|
||||
public class GsonParseFoundationBean {
|
||||
|
||||
public Integer code;
|
||||
public ArrayList<Foundation> data;
|
||||
public String msg;
|
||||
public Boolean result;
|
||||
public String time;
|
||||
|
||||
public class Foundation {
|
||||
public Integer foundationId;
|
||||
public String foundationName;
|
||||
}
|
||||
|
||||
}
|
@ -0,0 +1,82 @@
|
||||
package com.ruoyi.crops.domain;
|
||||
import java.io.Serializable;
|
||||
|
||||
/**
|
||||
* 水肥一体机智能控制;
|
||||
* @author : http://www.chiner.pro
|
||||
* @date : 2023-4-27
|
||||
*/
|
||||
public class IntelligentControl{
|
||||
/** id */
|
||||
private Integer id ;
|
||||
/** 大棚名称 */
|
||||
private String greenhouseName ;
|
||||
/** 阀门编号 */
|
||||
private Integer valveNumber ;
|
||||
/** 阀门状态 */
|
||||
private Integer valveStatus ;
|
||||
/** 开关 */
|
||||
private Integer disjunctor ;
|
||||
/** 进度 */
|
||||
private Double schedule;
|
||||
|
||||
public Integer getId() {
|
||||
return id;
|
||||
}
|
||||
|
||||
public void setId(Integer id) {
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
public String getGreenhouseName() {
|
||||
return greenhouseName;
|
||||
}
|
||||
|
||||
public void setGreenhouseName(String greenhouseName) {
|
||||
this.greenhouseName = greenhouseName;
|
||||
}
|
||||
|
||||
public Integer getValveNumber() {
|
||||
return valveNumber;
|
||||
}
|
||||
|
||||
public void setValveNumber(Integer valveNumber) {
|
||||
this.valveNumber = valveNumber;
|
||||
}
|
||||
|
||||
public Integer getValveStatus() {
|
||||
return valveStatus;
|
||||
}
|
||||
|
||||
public void setValveStatus(Integer valveStatus) {
|
||||
this.valveStatus = valveStatus;
|
||||
}
|
||||
|
||||
public Integer getDisjunctor() {
|
||||
return disjunctor;
|
||||
}
|
||||
|
||||
public void setDisjunctor(Integer option) {
|
||||
this.disjunctor = option;
|
||||
}
|
||||
|
||||
public Double getSchedule() {
|
||||
return schedule;
|
||||
}
|
||||
|
||||
public void setSchedule(Double schedule) {
|
||||
this.schedule = schedule;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "IntelligentControl{" +
|
||||
"id=" + id +
|
||||
", greenhouseName='" + greenhouseName + '\'' +
|
||||
", valveNumber=" + valveNumber +
|
||||
", valveStatus=" + valveStatus +
|
||||
", option=" + disjunctor +
|
||||
", schedule=" + schedule +
|
||||
'}';
|
||||
}
|
||||
}
|
@ -0,0 +1,70 @@
|
||||
package com.ruoyi.crops.domain;
|
||||
|
||||
/**
|
||||
* 水肥一体机参数;
|
||||
* @author : http://www.chiner.pro
|
||||
* @date : 2023-4-27
|
||||
*/
|
||||
public class MachineParameter{
|
||||
/** id */
|
||||
private String id ;
|
||||
/** 大棚名称 */
|
||||
private String greenhouseName ;
|
||||
/** 压力 */
|
||||
private Double pressure ;
|
||||
/** 流量 */
|
||||
private Double flow ;
|
||||
/** 电导率 */
|
||||
private Double conductivity ;
|
||||
|
||||
public String getId() {
|
||||
return id;
|
||||
}
|
||||
|
||||
public void setId(String id) {
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
public String getGreenhouseName() {
|
||||
return greenhouseName;
|
||||
}
|
||||
|
||||
public void setGreenhouseName(String greenhouseName) {
|
||||
this.greenhouseName = greenhouseName;
|
||||
}
|
||||
|
||||
public Double getPressure() {
|
||||
return pressure;
|
||||
}
|
||||
|
||||
public void setPressure(Double pressure) {
|
||||
this.pressure = pressure;
|
||||
}
|
||||
|
||||
public Double getFlow() {
|
||||
return flow;
|
||||
}
|
||||
|
||||
public void setFlow(Double flow) {
|
||||
this.flow = flow;
|
||||
}
|
||||
|
||||
public Double getConductivity() {
|
||||
return conductivity;
|
||||
}
|
||||
|
||||
public void setConductivity(Double conductivity) {
|
||||
this.conductivity = conductivity;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "MachineParameter{" +
|
||||
"id='" + id + '\'' +
|
||||
", greenhouseName='" + greenhouseName + '\'' +
|
||||
", pressure=" + pressure +
|
||||
", flow=" + flow +
|
||||
", conductivity=" + conductivity +
|
||||
'}';
|
||||
}
|
||||
}
|
@ -0,0 +1,64 @@
|
||||
package com.ruoyi.crops.domain;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
|
||||
import java.util.Date;
|
||||
|
||||
/**
|
||||
* 操作记录;
|
||||
* @author : http://www.chiner.pro
|
||||
* @date : 2023-4-27
|
||||
*/
|
||||
public class OperationRecords {
|
||||
/** id */
|
||||
private String id ;
|
||||
/** 更新时间 */
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
private Date updateTime ;
|
||||
/** 操作内容 */
|
||||
private String operationContent ;
|
||||
/** 更新人 */
|
||||
private String updateBy ;
|
||||
|
||||
public String getId() {
|
||||
return id;
|
||||
}
|
||||
|
||||
public void setId(String id) {
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
public Date getUpdateTime() {
|
||||
return updateTime;
|
||||
}
|
||||
|
||||
public void setUpdateTime(Date updateTime) {
|
||||
this.updateTime = updateTime;
|
||||
}
|
||||
|
||||
public String getOperationContent() {
|
||||
return operationContent;
|
||||
}
|
||||
|
||||
public void setOperationContent(String operationContent) {
|
||||
this.operationContent = operationContent;
|
||||
}
|
||||
|
||||
public String getUpdateBy() {
|
||||
return updateBy;
|
||||
}
|
||||
|
||||
public void setUpdateBy(String updateBy) {
|
||||
this.updateBy = updateBy;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "OperationRecords{" +
|
||||
"id='" + id + '\'' +
|
||||
", updateTime=" + updateTime +
|
||||
", operationContent='" + operationContent + '\'' +
|
||||
", updateBy='" + updateBy + '\'' +
|
||||
'}';
|
||||
}
|
||||
}
|
@ -0,0 +1,74 @@
|
||||
package com.ruoyi.crops.domain;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
|
||||
import java.util.Date;
|
||||
|
||||
/**
|
||||
* 服务类型;
|
||||
* @author : http://www.chiner.pro
|
||||
* @date : 2023-4-26
|
||||
*/
|
||||
public class ServiceType {
|
||||
/** id */
|
||||
private Integer id ;
|
||||
/** 服务类型 */
|
||||
private String serviceType ;
|
||||
/** 时间 */
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
private Date time ;
|
||||
/** 服务名称 */
|
||||
private String serviceName ;
|
||||
/** 样式 */
|
||||
private String style ;
|
||||
|
||||
public Integer getId() {
|
||||
return id;
|
||||
}
|
||||
|
||||
public void setId(Integer id) {
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
public String getServiceType() {
|
||||
return serviceType;
|
||||
}
|
||||
|
||||
public void setServiceType(String serviceType) {
|
||||
this.serviceType = serviceType;
|
||||
}
|
||||
|
||||
public Date getTime() {
|
||||
return time;
|
||||
}
|
||||
|
||||
public void setTime(Date time) {
|
||||
this.time = time;
|
||||
}
|
||||
|
||||
public String getServiceName() {
|
||||
return serviceName;
|
||||
}
|
||||
|
||||
public void setServiceName(String serviceName) {
|
||||
this.serviceName = serviceName;
|
||||
}
|
||||
|
||||
public String getStyle() {
|
||||
return style;
|
||||
}
|
||||
|
||||
public void setStyle(String style) {
|
||||
this.style = style;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "ServiceType{" +
|
||||
"id=" + id +
|
||||
", serviceType='" + serviceType + '\'' +
|
||||
", time=" + time +
|
||||
", serviceName='" + serviceName + '\'' +
|
||||
", style='" + style + '\'' +
|
||||
'}';
|
||||
}
|
||||
}
|
30
ruoyi-crops/src/main/java/com/ruoyi/crops/domain/User.java
Normal file
30
ruoyi-crops/src/main/java/com/ruoyi/crops/domain/User.java
Normal file
@ -0,0 +1,30 @@
|
||||
package com.ruoyi.crops.domain;
|
||||
|
||||
public class User {
|
||||
private String username;
|
||||
private String password;
|
||||
|
||||
public String getUsername() {
|
||||
return username;
|
||||
}
|
||||
|
||||
public void setUsername(String username) {
|
||||
this.username = username;
|
||||
}
|
||||
|
||||
public String getPassword() {
|
||||
return password;
|
||||
}
|
||||
|
||||
public void setPassword(String password) {
|
||||
this.password = password;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "User{" +
|
||||
"username='" + username + '\'' +
|
||||
", password='" + password + '\'' +
|
||||
'}';
|
||||
}
|
||||
}
|
@ -0,0 +1,52 @@
|
||||
package com.ruoyi.crops.domain;
|
||||
|
||||
import java.util.Date;
|
||||
|
||||
public class UserInfo {
|
||||
private String id;
|
||||
private String token;
|
||||
private Long expire;
|
||||
private String userInfo;
|
||||
|
||||
public String getId() {
|
||||
return id;
|
||||
}
|
||||
|
||||
public void setId(String id) {
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
public String getToken() {
|
||||
return token;
|
||||
}
|
||||
|
||||
public void setToken(String token) {
|
||||
this.token = token;
|
||||
}
|
||||
|
||||
public Long getExpire() {
|
||||
return expire;
|
||||
}
|
||||
|
||||
public void setExpire(Long expire) {
|
||||
this.expire = expire;
|
||||
}
|
||||
|
||||
public String getUserInfo() {
|
||||
return userInfo;
|
||||
}
|
||||
|
||||
public void setUserInfo(String userInfo) {
|
||||
this.userInfo = userInfo;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "UserInfo{" +
|
||||
"id=" + id +
|
||||
", token='" + token + '\'' +
|
||||
", expire=" + expire +
|
||||
", userInfo='" + userInfo + '\'' +
|
||||
'}';
|
||||
}
|
||||
}
|
@ -0,0 +1,86 @@
|
||||
package com.ruoyi.crops.domain;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
|
||||
import java.util.Date;
|
||||
|
||||
/**
|
||||
* 预警信息统计;
|
||||
* @author : http://www.chiner.pro
|
||||
* @date : 2023-4-27
|
||||
*/
|
||||
public class WarningInformation{
|
||||
/** id */
|
||||
private Integer id ;
|
||||
/** 大棚编号 */
|
||||
private Integer greenhouseNumber ;
|
||||
/** 监测指标 */
|
||||
private String monitoringIndicators ;
|
||||
/** 监测数值 */
|
||||
private Double monitoringValues ;
|
||||
/** 异常原因 */
|
||||
private String abnormalCause ;
|
||||
/** 预警时间 */
|
||||
@JsonFormat(pattern = "yyyy/MM/dd")
|
||||
private Date warningTime ;
|
||||
|
||||
public Integer getId() {
|
||||
return id;
|
||||
}
|
||||
|
||||
public void setId(Integer id) {
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
public Integer getGreenhouseNumber() {
|
||||
return greenhouseNumber;
|
||||
}
|
||||
|
||||
public void setGreenhouseName(Integer greenhouseNumber) {
|
||||
this.greenhouseNumber = greenhouseNumber;
|
||||
}
|
||||
|
||||
public String getMonitoringIndicators() {
|
||||
return monitoringIndicators;
|
||||
}
|
||||
|
||||
public void setMonitoringIndicators(String monitoringIndicators) {
|
||||
this.monitoringIndicators = monitoringIndicators;
|
||||
}
|
||||
|
||||
public Double getMonitoringValues() {
|
||||
return monitoringValues;
|
||||
}
|
||||
|
||||
public void setMonitoringValues(Double monitoringValues) {
|
||||
this.monitoringValues = monitoringValues;
|
||||
}
|
||||
|
||||
public String getAbnormalCause() {
|
||||
return abnormalCause;
|
||||
}
|
||||
|
||||
public void setAbnormalCause(String abnormalCause) {
|
||||
this.abnormalCause = abnormalCause;
|
||||
}
|
||||
|
||||
public Date getWarningTime() {
|
||||
return warningTime;
|
||||
}
|
||||
|
||||
public void setWarningTime(Date warningTime) {
|
||||
this.warningTime = warningTime;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "WarningInformation{" +
|
||||
"id=" + id +
|
||||
", greenhouseName=" + greenhouseNumber +
|
||||
", monitoringIndicators='" + monitoringIndicators + '\'' +
|
||||
", monitoringValues=" + monitoringValues +
|
||||
", abnormalCause='" + abnormalCause + '\'' +
|
||||
", warningTime=" + warningTime +
|
||||
'}';
|
||||
}
|
||||
}
|
@ -0,0 +1,61 @@
|
||||
package com.ruoyi.crops.mapper;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.crops.domain.CropsComprehensiveData;
|
||||
|
||||
/**
|
||||
* 作物综合数据Mapper接口
|
||||
*
|
||||
* @author my
|
||||
* @date 2023-04-20
|
||||
*/
|
||||
public interface CropsComprehensiveDataMapper
|
||||
{
|
||||
/**
|
||||
* 查询作物综合数据
|
||||
*
|
||||
* @param id 作物综合数据主键
|
||||
* @return 作物综合数据
|
||||
*/
|
||||
public CropsComprehensiveData selectCropsComprehensiveDataById(Long id);
|
||||
|
||||
/**
|
||||
* 查询作物综合数据列表
|
||||
*
|
||||
* @param cropsComprehensiveData 作物综合数据
|
||||
* @return 作物综合数据集合
|
||||
*/
|
||||
public List<CropsComprehensiveData> selectCropsComprehensiveDataList(CropsComprehensiveData cropsComprehensiveData);
|
||||
|
||||
/**
|
||||
* 新增作物综合数据
|
||||
*
|
||||
* @param cropsComprehensiveData 作物综合数据
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertCropsComprehensiveData(CropsComprehensiveData cropsComprehensiveData);
|
||||
|
||||
/**
|
||||
* 修改作物综合数据
|
||||
*
|
||||
* @param cropsComprehensiveData 作物综合数据
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateCropsComprehensiveData(CropsComprehensiveData cropsComprehensiveData);
|
||||
|
||||
/**
|
||||
* 删除作物综合数据
|
||||
*
|
||||
* @param id 作物综合数据主键
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteCropsComprehensiveDataById(Long id);
|
||||
|
||||
/**
|
||||
* 批量删除作物综合数据
|
||||
*
|
||||
* @param ids 需要删除的数据主键集合
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteCropsComprehensiveDataByIds(Long[] ids);
|
||||
}
|
@ -0,0 +1,13 @@
|
||||
package com.ruoyi.crops.mapper;
|
||||
|
||||
import com.ruoyi.crops.domain.CropsDrought;
|
||||
import org.springframework.data.repository.query.Param;
|
||||
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
|
||||
public interface CropsDroughtMapper {
|
||||
public int insertBatch(@Param("list") List<CropsDrought> cropsDroughtList);
|
||||
|
||||
List<CropsDrought> selectByTime(Date time);
|
||||
}
|
@ -0,0 +1,14 @@
|
||||
package com.ruoyi.crops.mapper;
|
||||
|
||||
import com.ruoyi.crops.domain.CropsGrowth;
|
||||
import org.springframework.data.repository.query.Param;
|
||||
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
|
||||
public interface CropsGrowthMapper {
|
||||
|
||||
public int insertBatch(@Param("list")List<CropsGrowth> list);
|
||||
|
||||
public List<CropsGrowth> selectByTime(Date time);
|
||||
}
|
@ -0,0 +1,20 @@
|
||||
package com.ruoyi.crops.mapper;
|
||||
|
||||
import com.ruoyi.crops.domain.CropStructure;
|
||||
import org.springframework.data.repository.query.Param;
|
||||
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
|
||||
public interface CropsStructureMapper {
|
||||
/**
|
||||
* 新增作物种植结构
|
||||
* @param cropStructure
|
||||
* @return
|
||||
*/
|
||||
public int insertCropsStructure(CropStructure cropStructure);
|
||||
|
||||
public int insertBatch(@Param("list") List<CropStructure> list);
|
||||
|
||||
public List<CropStructure> selectByTime(Date time);
|
||||
}
|
@ -0,0 +1,13 @@
|
||||
package com.ruoyi.crops.mapper;
|
||||
|
||||
import com.ruoyi.crops.domain.CropsYield;
|
||||
import org.springframework.data.repository.query.Param;
|
||||
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
|
||||
public interface CropsYieldMapper {
|
||||
public List<CropsYield> selectByYear(Integer year);
|
||||
|
||||
public int insertBatch(@Param("list") List<CropsYield> list);
|
||||
}
|
@ -0,0 +1,11 @@
|
||||
package com.ruoyi.crops.mapper;
|
||||
|
||||
import com.ruoyi.crops.domain.EnvironmentalData;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
public interface EnvironmentalMapper {
|
||||
List<EnvironmentalData> selectByNumber(Integer number);
|
||||
|
||||
int insert(EnvironmentalData environmentalData);
|
||||
}
|
@ -0,0 +1,11 @@
|
||||
package com.ruoyi.crops.mapper;
|
||||
|
||||
import com.ruoyi.crops.domain.GreenhouseInformation;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
public interface GreenhouseMapper {
|
||||
List<GreenhouseInformation> selectByName(String name);
|
||||
|
||||
int insert(GreenhouseInformation greenhouseInformation);
|
||||
}
|
@ -0,0 +1,13 @@
|
||||
package com.ruoyi.crops.mapper;
|
||||
|
||||
import com.ruoyi.crops.domain.IntelligentControl;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
public interface IntelligentControlMapper {
|
||||
int insert(IntelligentControl intelligentControl);
|
||||
|
||||
List<IntelligentControl> selectAll();
|
||||
|
||||
int edit(IntelligentControl intelligentControl);
|
||||
}
|
@ -0,0 +1,11 @@
|
||||
package com.ruoyi.crops.mapper;
|
||||
|
||||
import com.ruoyi.crops.domain.MachineParameter;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
public interface MachineParameterMapper {
|
||||
List<MachineParameter> selectByName(String name);
|
||||
|
||||
int insert(MachineParameter machineParameter);
|
||||
}
|
@ -0,0 +1,11 @@
|
||||
package com.ruoyi.crops.mapper;
|
||||
|
||||
import com.ruoyi.crops.domain.OperationRecords;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
public interface OperationRecordsMapper {
|
||||
List<OperationRecords> selectAll();
|
||||
|
||||
int insert(OperationRecords operationRecords);
|
||||
}
|
@ -0,0 +1,16 @@
|
||||
package com.ruoyi.crops.mapper;
|
||||
|
||||
import com.ruoyi.crops.domain.ServiceType;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
public interface ServiceTypeMapper {
|
||||
|
||||
List<ServiceType> selectByType(String type);
|
||||
|
||||
int insert(ServiceType serviceType);
|
||||
|
||||
List<ServiceType> selectAll();
|
||||
|
||||
int deleteByIds(Long[] ids);
|
||||
}
|
@ -0,0 +1,12 @@
|
||||
package com.ruoyi.crops.mapper;
|
||||
|
||||
import com.ruoyi.crops.domain.WarningInformation;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
public interface WarningMapper {
|
||||
List<WarningInformation> selectByNumber(Integer number);
|
||||
|
||||
int insert(WarningInformation warningInformation);
|
||||
|
||||
}
|
@ -0,0 +1,61 @@
|
||||
package com.ruoyi.crops.service;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.crops.domain.CropsComprehensiveData;
|
||||
|
||||
/**
|
||||
* 作物综合数据Service接口
|
||||
*
|
||||
* @author my
|
||||
* @date 2023-04-20
|
||||
*/
|
||||
public interface ICropsComprehensiveDataService
|
||||
{
|
||||
/**
|
||||
* 查询作物综合数据
|
||||
*
|
||||
* @param id 作物综合数据主键
|
||||
* @return 作物综合数据
|
||||
*/
|
||||
public CropsComprehensiveData selectCropsComprehensiveDataById(Long id);
|
||||
|
||||
/**
|
||||
* 查询作物综合数据列表
|
||||
*
|
||||
* @param cropsComprehensiveData 作物综合数据
|
||||
* @return 作物综合数据集合
|
||||
*/
|
||||
public List<CropsComprehensiveData> selectCropsComprehensiveDataList(CropsComprehensiveData cropsComprehensiveData);
|
||||
|
||||
/**
|
||||
* 新增作物综合数据
|
||||
*
|
||||
* @param cropsComprehensiveData 作物综合数据
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertCropsComprehensiveData(CropsComprehensiveData cropsComprehensiveData);
|
||||
|
||||
/**
|
||||
* 修改作物综合数据
|
||||
*
|
||||
* @param cropsComprehensiveData 作物综合数据
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateCropsComprehensiveData(CropsComprehensiveData cropsComprehensiveData);
|
||||
|
||||
/**
|
||||
* 批量删除作物综合数据
|
||||
*
|
||||
* @param ids 需要删除的作物综合数据主键集合
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteCropsComprehensiveDataByIds(Long[] ids);
|
||||
|
||||
/**
|
||||
* 删除作物综合数据信息
|
||||
*
|
||||
* @param id 作物综合数据主键
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteCropsComprehensiveDataById(Long id);
|
||||
}
|
@ -0,0 +1,14 @@
|
||||
package com.ruoyi.crops.service;
|
||||
|
||||
import com.ruoyi.crops.domain.CropsDrought;
|
||||
import com.ruoyi.crops.domain.CropsYield;
|
||||
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
|
||||
public interface ICropsDroughtService {
|
||||
|
||||
public int insertBatch(List<CropsDrought> cropsYieldList);
|
||||
|
||||
public List<CropsDrought> selectByTime(Date time);
|
||||
}
|
@ -0,0 +1,18 @@
|
||||
package com.ruoyi.crops.service;
|
||||
|
||||
import com.ruoyi.crops.domain.CropsGrowth;
|
||||
|
||||
import javax.xml.crypto.Data;
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
|
||||
public interface ICropsGrowthService {
|
||||
/**
|
||||
* 批量新增
|
||||
* @param cropGrowth
|
||||
* @return
|
||||
*/
|
||||
public int insertBatch(List<CropsGrowth> cropGrowth);
|
||||
|
||||
public List<CropsGrowth> selectByTime(Date time);
|
||||
}
|
@ -0,0 +1,29 @@
|
||||
package com.ruoyi.crops.service;
|
||||
|
||||
import com.ruoyi.crops.domain.CropStructure;
|
||||
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
|
||||
public interface ICropsStructureService {
|
||||
/**
|
||||
* 新增作物种植结构
|
||||
* @param cropStructure
|
||||
* @return
|
||||
*/
|
||||
public int insertCropsStructure(CropStructure cropStructure);
|
||||
|
||||
/**
|
||||
* 批量新增作物种植结构
|
||||
* @param cropStructureList
|
||||
* @return
|
||||
*/
|
||||
public int insertBatch(List<CropStructure> cropStructureList);
|
||||
|
||||
/**
|
||||
* 根据时间查询
|
||||
* @param time
|
||||
* @return
|
||||
*/
|
||||
public List<CropStructure> selectByTime(Date time);
|
||||
}
|
@ -0,0 +1,12 @@
|
||||
package com.ruoyi.crops.service;
|
||||
|
||||
import com.ruoyi.crops.domain.CropsYield;
|
||||
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
|
||||
public interface ICropsYieldService {
|
||||
public List<CropsYield> selectByYear(Integer year);
|
||||
|
||||
public int insertBatch (List<CropsYield> cropYieldList);
|
||||
}
|
@ -0,0 +1,12 @@
|
||||
package com.ruoyi.crops.service;
|
||||
|
||||
import com.ruoyi.crops.domain.EnvironmentalData;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
public interface IEnvironmentalService {
|
||||
List<EnvironmentalData> selectByNumber(Integer number);
|
||||
|
||||
|
||||
int insert(EnvironmentalData environmentalData);
|
||||
}
|
@ -0,0 +1,5 @@
|
||||
package com.ruoyi.crops.service;
|
||||
|
||||
public interface IFoundationService {
|
||||
String getFoundation(String id);
|
||||
}
|
@ -0,0 +1,11 @@
|
||||
package com.ruoyi.crops.service;
|
||||
|
||||
import com.ruoyi.crops.domain.GreenhouseInformation;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
public interface IGreenhouseService {
|
||||
List<GreenhouseInformation> selectByName(String name);
|
||||
|
||||
int insert(GreenhouseInformation greenhouseInformation);
|
||||
}
|
@ -0,0 +1,13 @@
|
||||
package com.ruoyi.crops.service;
|
||||
|
||||
import com.ruoyi.crops.domain.IntelligentControl;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
public interface IIntelligentControlService {
|
||||
int insert(IntelligentControl intelligentControl);
|
||||
|
||||
List<IntelligentControl> selectAll();
|
||||
|
||||
int edit(IntelligentControl intelligentControl);
|
||||
}
|
@ -0,0 +1,11 @@
|
||||
package com.ruoyi.crops.service;
|
||||
|
||||
import com.ruoyi.crops.domain.MachineParameter;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
public interface IMachineParameterService {
|
||||
List<MachineParameter> selectByName(String name);
|
||||
|
||||
int insert(MachineParameter machineParameter);
|
||||
}
|
@ -0,0 +1,11 @@
|
||||
package com.ruoyi.crops.service;
|
||||
|
||||
import com.ruoyi.crops.domain.OperationRecords;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
public interface IOperationRecordsService {
|
||||
List<OperationRecords> selectAll();
|
||||
|
||||
int insert(OperationRecords operationRecords);
|
||||
}
|
@ -0,0 +1,16 @@
|
||||
package com.ruoyi.crops.service;
|
||||
|
||||
import com.ruoyi.crops.domain.ServiceType;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
public interface IServiceTypeService {
|
||||
|
||||
List<ServiceType> selectByType(String type);
|
||||
|
||||
int insert(ServiceType serviceType);
|
||||
|
||||
List<ServiceType> selectAll();
|
||||
|
||||
int deleteByIds(Long[] ids);
|
||||
}
|
@ -0,0 +1,8 @@
|
||||
package com.ruoyi.crops.service;
|
||||
|
||||
import com.ruoyi.crops.domain.User;
|
||||
|
||||
public interface IUserInfoService {
|
||||
|
||||
String login(User user);
|
||||
}
|
@ -0,0 +1,11 @@
|
||||
package com.ruoyi.crops.service;
|
||||
|
||||
import com.ruoyi.crops.domain.WarningInformation;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
public interface IWarningService {
|
||||
List<WarningInformation> selectByNumber(Integer number);
|
||||
|
||||
int insert(WarningInformation warningInformation);
|
||||
}
|
@ -0,0 +1,93 @@
|
||||
package com.ruoyi.crops.service.impl;
|
||||
|
||||
import java.util.List;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import com.ruoyi.crops.mapper.CropsComprehensiveDataMapper;
|
||||
import com.ruoyi.crops.domain.CropsComprehensiveData;
|
||||
import com.ruoyi.crops.service.ICropsComprehensiveDataService;
|
||||
|
||||
/**
|
||||
* 作物综合数据Service业务层处理
|
||||
*
|
||||
* @author my
|
||||
* @date 2023-04-20
|
||||
*/
|
||||
@Service
|
||||
public class CropsComprehensiveDataServiceImpl implements ICropsComprehensiveDataService
|
||||
{
|
||||
@Autowired
|
||||
private CropsComprehensiveDataMapper cropsComprehensiveDataMapper;
|
||||
|
||||
/**
|
||||
* 查询作物综合数据
|
||||
*
|
||||
* @param id 作物综合数据主键
|
||||
* @return 作物综合数据
|
||||
*/
|
||||
@Override
|
||||
public CropsComprehensiveData selectCropsComprehensiveDataById(Long id)
|
||||
{
|
||||
return cropsComprehensiveDataMapper.selectCropsComprehensiveDataById(id);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询作物综合数据列表
|
||||
*
|
||||
* @param cropsComprehensiveData 作物综合数据
|
||||
* @return 作物综合数据
|
||||
*/
|
||||
@Override
|
||||
public List<CropsComprehensiveData> selectCropsComprehensiveDataList(CropsComprehensiveData cropsComprehensiveData)
|
||||
{
|
||||
return cropsComprehensiveDataMapper.selectCropsComprehensiveDataList(cropsComprehensiveData);
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增作物综合数据
|
||||
*
|
||||
* @param cropsComprehensiveData 作物综合数据
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int insertCropsComprehensiveData(CropsComprehensiveData cropsComprehensiveData)
|
||||
{
|
||||
return cropsComprehensiveDataMapper.insertCropsComprehensiveData(cropsComprehensiveData);
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改作物综合数据
|
||||
*
|
||||
* @param cropsComprehensiveData 作物综合数据
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int updateCropsComprehensiveData(CropsComprehensiveData cropsComprehensiveData)
|
||||
{
|
||||
return cropsComprehensiveDataMapper.updateCropsComprehensiveData(cropsComprehensiveData);
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除作物综合数据
|
||||
*
|
||||
* @param ids 需要删除的作物综合数据主键
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deleteCropsComprehensiveDataByIds(Long[] ids)
|
||||
{
|
||||
return cropsComprehensiveDataMapper.deleteCropsComprehensiveDataByIds(ids);
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除作物综合数据信息
|
||||
*
|
||||
* @param id 作物综合数据主键
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deleteCropsComprehensiveDataById(Long id)
|
||||
{
|
||||
return cropsComprehensiveDataMapper.deleteCropsComprehensiveDataById(id);
|
||||
}
|
||||
}
|
@ -0,0 +1,26 @@
|
||||
package com.ruoyi.crops.service.impl;
|
||||
|
||||
import com.ruoyi.crops.domain.CropsDrought;
|
||||
import com.ruoyi.crops.domain.CropsYield;
|
||||
import com.ruoyi.crops.mapper.CropsDroughtMapper;
|
||||
import com.ruoyi.crops.service.ICropsDroughtService;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
|
||||
@Service
|
||||
public class CropsDroughtServiceImpl implements ICropsDroughtService {
|
||||
@Autowired
|
||||
private CropsDroughtMapper cropsDroughtMapper;
|
||||
@Override
|
||||
public int insertBatch(List<CropsDrought> cropsYieldList) {
|
||||
return cropsDroughtMapper.insertBatch(cropsYieldList);
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<CropsDrought> selectByTime(Date time) {
|
||||
return cropsDroughtMapper.selectByTime(time);
|
||||
}
|
||||
}
|
@ -0,0 +1,25 @@
|
||||
package com.ruoyi.crops.service.impl;
|
||||
|
||||
import com.ruoyi.crops.domain.CropsGrowth;
|
||||
import com.ruoyi.crops.mapper.CropsGrowthMapper;
|
||||
import com.ruoyi.crops.service.ICropsGrowthService;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
|
||||
@Service
|
||||
public class CropsGrowthServiceImpl implements ICropsGrowthService {
|
||||
@Autowired
|
||||
private CropsGrowthMapper cropsGrowthMapper;
|
||||
@Override
|
||||
public int insertBatch(List<CropsGrowth> cropGrowth) {
|
||||
return cropsGrowthMapper.insertBatch(cropGrowth);
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<CropsGrowth> selectByTime(Date time) {
|
||||
return cropsGrowthMapper.selectByTime(time);
|
||||
}
|
||||
}
|
@ -0,0 +1,41 @@
|
||||
package com.ruoyi.crops.service.impl;
|
||||
|
||||
import com.ruoyi.crops.domain.CropStructure;
|
||||
import com.ruoyi.crops.mapper.CropsStructureMapper;
|
||||
import com.ruoyi.crops.service.ICropsStructureService;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
|
||||
@Service
|
||||
public class CropsStructureServiceImpl implements ICropsStructureService {
|
||||
@Autowired
|
||||
private CropsStructureMapper cropsStructureMapper;
|
||||
|
||||
/**
|
||||
* 新增作物种植结构
|
||||
* @param cropStructure
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
public int insertCropsStructure(CropStructure cropStructure) {
|
||||
return cropsStructureMapper.insertCropsStructure(cropStructure);
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量新增
|
||||
* @param cropStructureList
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
public int insertBatch(List<CropStructure> cropStructureList) {
|
||||
return cropsStructureMapper.insertBatch(cropStructureList);
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<CropStructure> selectByTime(Date time) {
|
||||
return cropsStructureMapper.selectByTime(time);
|
||||
}
|
||||
}
|
@ -0,0 +1,25 @@
|
||||
package com.ruoyi.crops.service.impl;
|
||||
|
||||
import com.ruoyi.crops.domain.CropsYield;
|
||||
import com.ruoyi.crops.mapper.CropsYieldMapper;
|
||||
import com.ruoyi.crops.service.ICropsYieldService;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
|
||||
@Service
|
||||
public class CropsYieldServiceImpl implements ICropsYieldService {
|
||||
@Autowired
|
||||
private CropsYieldMapper cropsYieldMapper;
|
||||
@Override
|
||||
public List<CropsYield> selectByYear(Integer year) {
|
||||
return cropsYieldMapper.selectByYear(year);
|
||||
}
|
||||
|
||||
@Override
|
||||
public int insertBatch(List<CropsYield> cropYieldList) {
|
||||
return cropsYieldMapper.insertBatch(cropYieldList);
|
||||
}
|
||||
}
|
@ -0,0 +1,24 @@
|
||||
package com.ruoyi.crops.service.impl;
|
||||
|
||||
import com.ruoyi.crops.domain.EnvironmentalData;
|
||||
import com.ruoyi.crops.mapper.EnvironmentalMapper;
|
||||
import com.ruoyi.crops.service.IEnvironmentalService;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
@Service
|
||||
public class EnvironmentalServiceImpl implements IEnvironmentalService {
|
||||
@Autowired
|
||||
private EnvironmentalMapper environmentalMapper;
|
||||
@Override
|
||||
public List<EnvironmentalData> selectByNumber(Integer number) {
|
||||
return environmentalMapper.selectByNumber(number);
|
||||
}
|
||||
|
||||
@Override
|
||||
public int insert(EnvironmentalData environmentalData) {
|
||||
return environmentalMapper.insert(environmentalData);
|
||||
}
|
||||
}
|
@ -0,0 +1,44 @@
|
||||
package com.ruoyi.crops.service.impl;
|
||||
|
||||
import cn.hutool.http.HttpUtil;
|
||||
import com.google.gson.Gson;
|
||||
import com.ruoyi.crops.domain.GsonParseFoundationBean;
|
||||
import com.ruoyi.crops.service.IFoundationService;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.beans.factory.annotation.Value;
|
||||
import org.springframework.data.redis.core.RedisTemplate;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.HashMap;
|
||||
import java.util.Map;
|
||||
|
||||
@Service
|
||||
public class FoundationServiceImpl implements IFoundationService {
|
||||
@Autowired
|
||||
private RedisTemplate redisTemplate;
|
||||
@Autowired
|
||||
private Gson gson;
|
||||
|
||||
@Value("${url.foundation}")
|
||||
private String url;
|
||||
@Override
|
||||
public String getFoundation(String id) {
|
||||
|
||||
Map<String, Object> map = new HashMap<>();//存放参数
|
||||
map.put("id", id);
|
||||
HashMap<String, String> headers = new HashMap<>();//存放请求头,可以存放多个请求头
|
||||
String token = (String) redisTemplate.opsForValue().get(id);
|
||||
headers.put("token", token);
|
||||
String result = HttpUtil.createPost(url).addHeaders(headers).form(map).execute().body();
|
||||
|
||||
GsonParseFoundationBean model = gson.fromJson(result, GsonParseFoundationBean.class);
|
||||
ArrayList<GsonParseFoundationBean.Foundation> foundations = model.data;
|
||||
for (GsonParseFoundationBean.Foundation Foundation : foundations) {
|
||||
Integer foundationId = Foundation.foundationId;
|
||||
String foundationName = Foundation.foundationName;
|
||||
// insert(foundationId,foundationName);
|
||||
}
|
||||
return token;
|
||||
}
|
||||
}
|
@ -0,0 +1,24 @@
|
||||
package com.ruoyi.crops.service.impl;
|
||||
|
||||
import com.ruoyi.crops.domain.GreenhouseInformation;
|
||||
import com.ruoyi.crops.mapper.GreenhouseMapper;
|
||||
import com.ruoyi.crops.service.IGreenhouseService;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
@Service
|
||||
public class GreenhouseServiceImpl implements IGreenhouseService {
|
||||
@Autowired
|
||||
private GreenhouseMapper greenhouseMapper;
|
||||
@Override
|
||||
public List<GreenhouseInformation> selectByName(String name) {
|
||||
return greenhouseMapper.selectByName(name);
|
||||
}
|
||||
|
||||
@Override
|
||||
public int insert(GreenhouseInformation greenhouseInformation) {
|
||||
return greenhouseMapper.insert(greenhouseInformation);
|
||||
}
|
||||
}
|
@ -0,0 +1,29 @@
|
||||
package com.ruoyi.crops.service.impl;
|
||||
|
||||
import com.ruoyi.crops.domain.IntelligentControl;
|
||||
import com.ruoyi.crops.mapper.IntelligentControlMapper;
|
||||
import com.ruoyi.crops.service.IIntelligentControlService;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
@Service
|
||||
public class IntelligentControlServiceImpl implements IIntelligentControlService {
|
||||
@Autowired
|
||||
private IntelligentControlMapper intelligentControlMapper;
|
||||
@Override
|
||||
public int insert(IntelligentControl intelligentControl) {
|
||||
return intelligentControlMapper.insert(intelligentControl);
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<IntelligentControl> selectAll() {
|
||||
return intelligentControlMapper.selectAll();
|
||||
}
|
||||
|
||||
@Override
|
||||
public int edit(IntelligentControl intelligentControl) {
|
||||
return intelligentControlMapper.edit(intelligentControl);
|
||||
}
|
||||
}
|
@ -0,0 +1,24 @@
|
||||
package com.ruoyi.crops.service.impl;
|
||||
|
||||
import com.ruoyi.crops.domain.MachineParameter;
|
||||
import com.ruoyi.crops.mapper.MachineParameterMapper;
|
||||
import com.ruoyi.crops.service.IMachineParameterService;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
@Service
|
||||
public class MachineParameterServiceImpl implements IMachineParameterService {
|
||||
@Autowired
|
||||
private MachineParameterMapper machineParameterMapper;
|
||||
@Override
|
||||
public List<MachineParameter> selectByName(String name) {
|
||||
return machineParameterMapper.selectByName(name);
|
||||
}
|
||||
|
||||
@Override
|
||||
public int insert(MachineParameter machineParameter) {
|
||||
return machineParameterMapper.insert(machineParameter);
|
||||
}
|
||||
}
|
@ -0,0 +1,24 @@
|
||||
package com.ruoyi.crops.service.impl;
|
||||
|
||||
import com.ruoyi.crops.domain.OperationRecords;
|
||||
import com.ruoyi.crops.mapper.OperationRecordsMapper;
|
||||
import com.ruoyi.crops.service.IOperationRecordsService;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
@Service
|
||||
public class OperationRecordsServiceImppl implements IOperationRecordsService {
|
||||
@Autowired
|
||||
private OperationRecordsMapper operationRecordsMapper;
|
||||
@Override
|
||||
public List<OperationRecords> selectAll() {
|
||||
return operationRecordsMapper.selectAll();
|
||||
}
|
||||
|
||||
@Override
|
||||
public int insert(OperationRecords operationRecords) {
|
||||
return operationRecordsMapper.insert(operationRecords);
|
||||
}
|
||||
}
|
@ -0,0 +1,35 @@
|
||||
package com.ruoyi.crops.service.impl;
|
||||
|
||||
import com.ruoyi.crops.domain.ServiceType;
|
||||
import com.ruoyi.crops.mapper.ServiceTypeMapper;
|
||||
import com.ruoyi.crops.service.IServiceTypeService;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
@Service
|
||||
public class ServiceTypeServiceImpl implements IServiceTypeService {
|
||||
@Autowired
|
||||
private ServiceTypeMapper serviceTypeMapper;
|
||||
@Override
|
||||
public List<ServiceType> selectByType(String type) {
|
||||
return serviceTypeMapper.selectByType(type);
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
public int insert(ServiceType serviceType) {
|
||||
return serviceTypeMapper.insert(serviceType);
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<ServiceType> selectAll() {
|
||||
return serviceTypeMapper.selectAll();
|
||||
}
|
||||
|
||||
@Override
|
||||
public int deleteByIds(Long[] ids) {
|
||||
return serviceTypeMapper.deleteByIds(ids);
|
||||
}
|
||||
}
|
@ -0,0 +1,35 @@
|
||||
package com.ruoyi.crops.service.impl;
|
||||
|
||||
import cn.hutool.http.HttpUtil;
|
||||
import com.alibaba.fastjson2.JSONObject;
|
||||
import com.ruoyi.crops.domain.User;
|
||||
import com.ruoyi.crops.domain.UserInfo;
|
||||
import com.ruoyi.crops.service.IUserInfoService;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.beans.factory.annotation.Value;
|
||||
import org.springframework.data.redis.core.RedisTemplate;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import java.time.Duration;
|
||||
import java.util.HashMap;
|
||||
|
||||
@Service
|
||||
public class UserInfoServiceImpl implements IUserInfoService {
|
||||
@Autowired
|
||||
private RedisTemplate redisTemplate;
|
||||
@Value("${url.userInfo}")
|
||||
private String url;
|
||||
|
||||
@Override
|
||||
public String login(User user) {
|
||||
HashMap<String, Object> paramMap = new HashMap<>();
|
||||
paramMap.put("username", user.getUsername());
|
||||
paramMap.put("password", user.getPassword());
|
||||
String result = HttpUtil.post(url, paramMap);
|
||||
|
||||
UserInfo userInfo = JSONObject.parseObject(result, UserInfo.class);
|
||||
redisTemplate.opsForValue().set(userInfo.getId(), userInfo.getToken(), Duration.ofMillis(userInfo.getExpire()) );
|
||||
|
||||
return userInfo.toString();
|
||||
}
|
||||
}
|
@ -0,0 +1,23 @@
|
||||
package com.ruoyi.crops.service.impl;
|
||||
|
||||
import com.ruoyi.crops.domain.WarningInformation;
|
||||
import com.ruoyi.crops.mapper.WarningMapper;
|
||||
import com.ruoyi.crops.service.IWarningService;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import java.util.List;
|
||||
@Service
|
||||
public class WarningServiceImpl implements IWarningService {
|
||||
@Autowired
|
||||
private WarningMapper warningMapper;
|
||||
@Override
|
||||
public List<WarningInformation> selectByNumber(Integer number) {
|
||||
return warningMapper.selectByNumber(number);
|
||||
}
|
||||
|
||||
@Override
|
||||
public int insert(WarningInformation warningInformation) {
|
||||
return warningMapper.insert(warningInformation);
|
||||
}
|
||||
}
|
@ -0,0 +1,151 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<!DOCTYPE mapper
|
||||
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="com.ruoyi.crops.mapper.CropsComprehensiveDataMapper">
|
||||
|
||||
<resultMap type="com.ruoyi.crops.domain.CropsComprehensiveData" id="CropsComprehensiveDataResult">
|
||||
<result property="id" column="id" />
|
||||
<result property="cultivatedArea" column="cultivated_area" />
|
||||
<result property="foodstuffProduction" column="foodstuff_production" />
|
||||
<result property="vegetablePlantingArea" column="vegetable_planting_area" />
|
||||
<result property="vegetableProduction" column="vegetable_production" />
|
||||
<result property="type" column="type" />
|
||||
<result property="agriculturalPlantingArea" column="agricultural_planting_area" />
|
||||
<result property="agricultureProduction" column="agriculture_production" />
|
||||
<result property="agricultureOutputVaule" column="agriculture_output_vaule" />
|
||||
<result property="totalPopulation" column="total_population" />
|
||||
<result property="coverArea" column="cover_area" />
|
||||
<result property="exampleGreenhouse" column="example_greenhouse" />
|
||||
<result property="rusticate" column="rusticate" />
|
||||
<result property="cultivatedAlly" column="cultivated_ally" />
|
||||
<result property="greenhouse" column="greenhouse" />
|
||||
<result property="outputValue" column="output_value" />
|
||||
<result property="vectorBoundary" column="vector_boundary" />
|
||||
<result property="villageVectorBoundary" column="village_vector_boundary" />
|
||||
<result property="img" column="img" />
|
||||
<result property="createdBy" column="created_by" />
|
||||
<result property="createdTime" column="created_time" />
|
||||
</resultMap>
|
||||
|
||||
<sql id="selectCropsComprehensiveDataVo">
|
||||
select id, cultivated_area, foodstuff_production, vegetable_planting_area, vegetable_production, type, agricultural_planting_area, agriculture_production, agriculture_output_vaule, total_population, cover_area, example_greenhouse, rusticate, cultivated_ally, greenhouse, output_value, vector_boundary, village_vector_boundary,img, created_by, created_time from crops_comprehensive_data
|
||||
</sql>
|
||||
|
||||
<select id="selectCropsComprehensiveDataList" parameterType="CropsComprehensiveData" resultMap="CropsComprehensiveDataResult">
|
||||
<include refid="selectCropsComprehensiveDataVo"/>
|
||||
<where>
|
||||
<if test="cultivatedArea != null "> and cultivated_area = #{cultivatedArea}</if>
|
||||
<if test="foodstuffProduction != null "> and foodstuff_production = #{foodstuffProduction}</if>
|
||||
<if test="vegetablePlantingArea != null "> and vegetable_planting_area = #{vegetablePlantingArea}</if>
|
||||
<if test="vegetableProduction != null "> and vegetable_production = #{vegetableProduction}</if>
|
||||
<if test="type != null "> and type = #{type}</if>
|
||||
<if test="agriculturalPlantingArea != null "> and agricultural_planting_area = #{agriculturalPlantingArea}</if>
|
||||
<if test="agricultureProduction != null "> and agriculture_production = #{agricultureProduction}</if>
|
||||
<if test="agricultureOutputVaule != null "> and agriculture_output_vaule = #{agricultureOutputVaule}</if>
|
||||
<if test="totalPopulation != null "> and total_population = #{totalPopulation}</if>
|
||||
<if test="coverArea != null "> and cover_area = #{coverArea}</if>
|
||||
<if test="exampleGreenhouse != null "> and example_greenhouse = #{exampleGreenhouse}</if>
|
||||
<if test="rusticate != null "> and rusticate = #{rusticate}</if>
|
||||
<if test="cultivatedAlly != null "> and cultivated_ally = #{cultivatedAlly}</if>
|
||||
<if test="greenhouse != null "> and greenhouse = #{greenhouse}</if>
|
||||
<if test="outputValue != null "> and output_value = #{outputValue}</if>
|
||||
<if test="vectorBoundary != null and vectorBoundary != ''"> and vector_boundary = #{vectorBoundary}</if>
|
||||
<if test="villageVectorBoundary != null and villageVectorBoundary != ''"> and village_vector_boundary = #{villageVectorBoundary}</if>
|
||||
<if test="img != null and img != ''"> and img = #{img}</if>
|
||||
<if test="createdBy != null and createdBy != ''"> and created_by = #{createdBy}</if>
|
||||
<if test="createdTime != null "> and created_time = #{createdTime}</if>
|
||||
</where>
|
||||
</select>
|
||||
|
||||
<select id="selectCropsComprehensiveDataById" parameterType="Long" resultMap="CropsComprehensiveDataResult">
|
||||
<include refid="selectCropsComprehensiveDataVo"/>
|
||||
where id = #{id}
|
||||
</select>
|
||||
|
||||
<insert id="insertCropsComprehensiveData" parameterType="com.ruoyi.crops.domain.CropsComprehensiveData" useGeneratedKeys="true" keyProperty="id">
|
||||
insert into ruoyi.crops_comprehensive_data
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
<if test="cultivatedArea != null">cultivated_area,</if>
|
||||
<if test="foodstuffProduction != null">foodstuff_production,</if>
|
||||
<if test="vegetablePlantingArea != null">vegetable_planting_area,</if>
|
||||
<if test="vegetableProduction != null">vegetable_production,</if>
|
||||
<if test="type != null">type,</if>
|
||||
<if test="agriculturalPlantingArea != null">agricultural_planting_area,</if>
|
||||
<if test="agricultureProduction != null">agriculture_production,</if>
|
||||
<if test="agricultureOutputVaule != null">agriculture_output_vaule,</if>
|
||||
<if test="totalPopulation != null">total_population,</if>
|
||||
<if test="coverArea != null">cover_area,</if>
|
||||
<if test="exampleGreenhouse != null">example_greenhouse,</if>
|
||||
<if test="rusticate != null">rusticate,</if>
|
||||
<if test="cultivatedAlly != null">cultivated_ally,</if>
|
||||
<if test="greenhouse != null">greenhouse,</if>
|
||||
<if test="outputValue != null">output_value,</if>
|
||||
<if test="vectorBoundary != null">vector_boundary,</if>
|
||||
<if test="villageVectorBoundary != null">village_vector_boundary,</if>
|
||||
<if test="img != null">img,</if>
|
||||
<if test="createdBy != null">created_by,</if>
|
||||
<if test="createdTime != null">created_time,</if>
|
||||
</trim>
|
||||
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||
<if test="cultivatedArea != null">#{cultivatedArea},</if>
|
||||
<if test="foodstuffProduction != null">#{foodstuffProduction},</if>
|
||||
<if test="vegetablePlantingArea != null">#{vegetablePlantingArea},</if>
|
||||
<if test="vegetableProduction != null">#{vegetableProduction},</if>
|
||||
<if test="type != null">#{type},</if>
|
||||
<if test="agriculturalPlantingArea != null">#{agriculturalPlantingArea},</if>
|
||||
<if test="agricultureProduction != null">#{agricultureProduction},</if>
|
||||
<if test="agricultureOutputVaule != null">#{agricultureOutputVaule},</if>
|
||||
<if test="totalPopulation != null">#{totalPopulation},</if>
|
||||
<if test="coverArea != null">#{coverArea},</if>
|
||||
<if test="exampleGreenhouse != null">#{exampleGreenhouse},</if>
|
||||
<if test="rusticate != null">#{rusticate},</if>
|
||||
<if test="cultivatedAlly != null">#{cultivatedAlly},</if>
|
||||
<if test="greenhouse != null">#{greenhouse},</if>
|
||||
<if test="outputValue != null">#{outputValue},</if>
|
||||
<if test="vectorBoundary != null">#{vectorBoundary},</if>
|
||||
<if test="villageVectorBoundary != null">#{villageVectorBoundary},</if>
|
||||
<if test="img != null">#{img},</if>
|
||||
<if test="createdBy != null">#{createdBy},</if>
|
||||
<if test="createdTime != null">#{createdTime},</if>
|
||||
</trim>
|
||||
</insert>
|
||||
|
||||
<update id="updateCropsComprehensiveData" parameterType="CropsComprehensiveData">
|
||||
update crops_comprehensive_data
|
||||
<trim prefix="SET" suffixOverrides=",">
|
||||
<if test="cultivatedArea != null">cultivated_area = #{cultivatedArea},</if>
|
||||
<if test="foodstuffProduction != null">foodstuff_production = #{foodstuffProduction},</if>
|
||||
<if test="vegetablePlantingArea != null">vegetable_planting_area = #{vegetablePlantingArea},</if>
|
||||
<if test="vegetableProduction != null">vegetable_production = #{vegetableProduction},</if>
|
||||
<if test="type != null">type = #{type},</if>
|
||||
<if test="agriculturalPlantingArea != null">agricultural_planting_area = #{agriculturalPlantingArea},</if>
|
||||
<if test="agricultureProduction != null">agriculture_production = #{agricultureProduction},</if>
|
||||
<if test="agricultureOutputVaule != null">agriculture_output_vaule = #{agricultureOutputVaule},</if>
|
||||
<if test="totalPopulation != null">total_population = #{totalPopulation},</if>
|
||||
<if test="coverArea != null">cover_area = #{coverArea},</if>
|
||||
<if test="exampleGreenhouse != null">example_greenhouse = #{exampleGreenhouse},</if>
|
||||
<if test="rusticate != null">rusticate = #{rusticate},</if>
|
||||
<if test="cultivatedAlly != null">cultivated_ally = #{cultivatedAlly},</if>
|
||||
<if test="greenhouse != null">greenhouse = #{greenhouse},</if>
|
||||
<if test="outputValue != null">output_value = #{outputValue},</if>
|
||||
<if test="vectorBoundary != null">vector_boundary = #{vectorBoundary},</if>
|
||||
<if test="villageVectorBoundary != null">village_vector_boundary = #{villageVectorBoundary},</if>
|
||||
<if test="img != null">village_vector_boundary = #{img},</if>
|
||||
<if test="createdBy != null">created_by = #{createdBy},</if>
|
||||
<if test="createdTime != null">created_time = #{createdTime},</if>
|
||||
</trim>
|
||||
where id = #{id}
|
||||
</update>
|
||||
|
||||
<delete id="deleteCropsComprehensiveDataById" parameterType="Long">
|
||||
delete from crops_comprehensive_data where id = #{id}
|
||||
</delete>
|
||||
|
||||
<delete id="deleteCropsComprehensiveDataByIds" parameterType="String">
|
||||
delete from crops_comprehensive_data where id in
|
||||
<foreach item="id" collection="array" open="(" separator="," close=")">
|
||||
#{id}
|
||||
</foreach>
|
||||
</delete>
|
||||
</mapper>
|
@ -0,0 +1,27 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="com.ruoyi.crops.mapper.CropsDroughtMapper">
|
||||
<resultMap type="com.ruoyi.crops.domain.CropsDrought" id="CropDroughtMap">
|
||||
<result property="id" column="id" jdbcType="INTEGER"/>
|
||||
<result property="zone" column="zone" jdbcType="VARCHAR"/>
|
||||
<result property="imageDate" column="imageDate" jdbcType="DATE"/>
|
||||
<result property="severeArea" column="severeArea" jdbcType="DOUBLE"/>
|
||||
<result property="modArea" column="modArea" jdbcType="DOUBLE"/>
|
||||
<result property="mildArea" column="mildArea" jdbcType="DOUBLE"/>
|
||||
<result property="suitArea" column="suitArea" jdbcType="DOUBLE"/>
|
||||
<result property="humidArea" column="humidArea" jdbcType="DOUBLE"/>
|
||||
</resultMap>
|
||||
|
||||
<insert id="insertBatch" parameterType="list" keyProperty="id" useGeneratedKeys="true" >
|
||||
insert into ruoyi.crop_drought(zone,imageDate,severeArea,modArea,mildArea,suitArea,humidArea)
|
||||
values
|
||||
<foreach collection="list" item="entity" separator=",">
|
||||
(#{entity.zone},#{entity.imageDate},#{entity.severeArea},#{entity.modArea},#{entity.mildArea},#{entity.suitArea},#{entity.humidArea})
|
||||
</foreach>
|
||||
</insert>
|
||||
|
||||
<select id="selectByTime" resultMap="CropDroughtMap">
|
||||
select * from ruoyi.crop_drought
|
||||
where imageDate = #{time}
|
||||
</select>
|
||||
</mapper>
|
@ -0,0 +1,31 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="com.ruoyi.crops.mapper.CropsGrowthMapper">
|
||||
<resultMap type="com.ruoyi.crops.domain.CropsGrowth" id="CropGrowthMap">
|
||||
<result property="id" column="id" jdbcType="INTEGER"/>
|
||||
<result property="zone" column="zone" jdbcType="VARCHAR"/>
|
||||
<result property="imageDate" column="imageDate" jdbcType="DATE"/>
|
||||
<result property="poorArea" column="poorArea" jdbcType="DOUBLE"/>
|
||||
<result property="lowArea" column="lowArea" jdbcType="DOUBLE"/>
|
||||
<result property="mediumArea" column="mediumArea" jdbcType="DOUBLE"/>
|
||||
<result property="goodArea" column="goodArea" jdbcType="DOUBLE"/>
|
||||
<result property="excellentArea" column="excellentArea" jdbcType="DOUBLE"/>
|
||||
</resultMap>
|
||||
<sql id="selectCropsCropsGrowthVo">
|
||||
select id,zone,imageDate,poorArea,lowArea,mediumArea,goodArea,excellentArea from ruoyi.crop_growth
|
||||
</sql>
|
||||
|
||||
<insert id="insertBatch" useGeneratedKeys="true" keyProperty="id">
|
||||
insert into ruoyi.crop_growth(zone,imageDate,poorArea,lowArea,mediumArea,goodArea,excellentArea)
|
||||
values
|
||||
<foreach collection="list" item="entity" separator=",">
|
||||
(#{entity.zone},#{entity.imageDate},#{entity.poorArea},#{entity.lowArea},#{entity.mediumArea},#{entity.goodArea},#{entity.excellentArea})
|
||||
</foreach>
|
||||
</insert>
|
||||
|
||||
<select id="selectByTime" resultMap="CropGrowthMap">
|
||||
<include refid="selectCropsCropsGrowthVo">
|
||||
</include>
|
||||
where imageDate = #{time}
|
||||
</select>
|
||||
</mapper>
|
@ -0,0 +1,58 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="com.ruoyi.crops.mapper.CropsStructureMapper">
|
||||
<resultMap type="com.ruoyi.crops.domain.CropStructure" id="CropStructureMap">
|
||||
<result property="id" column="id" jdbcType="INTEGER"/>
|
||||
<result property="zone" column="zone" jdbcType="VARCHAR"/>
|
||||
<result property="imageDate" column="imageDate" jdbcType="DATE"/>
|
||||
<result property="wheatArea" column="wheatArea" jdbcType="DOUBLE"/>
|
||||
<result property="cornArea" column="cornArea" jdbcType="DOUBLE"/>
|
||||
<result property="peanutArea" column="peanutArea" jdbcType="DOUBLE"/>
|
||||
<result property="soybeanArea" column="soybeanArea" jdbcType="DOUBLE"/>
|
||||
<result property="otherArea" column="otherArea" jdbcType="DOUBLE"/>
|
||||
<result property="toalArea" column="toalArea" jdbcType="DOUBLE"/>
|
||||
</resultMap>
|
||||
|
||||
<sql id="selectCropsStructureVo">
|
||||
select id, zone, imageDate, wheatArea, cornArea, peanutArea, soybeanArea,otherArea, toalArea from ruoyi.crop_structure
|
||||
</sql>
|
||||
<!--新增数据-->
|
||||
<insert id="insertCropsStructure" parameterType="com.ruoyi.crops.domain.CropStructure" useGeneratedKeys="true" keyProperty="id">
|
||||
insert into ruoyi.crop_structure
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
<if test="zone != null">zone,</if>
|
||||
<if test="imageDate != null">imageDate,</if>
|
||||
<if test="wheatArea != null">wheatArea,</if>
|
||||
<if test="cornArea != null">cornArea,</if>
|
||||
<if test="peanutArea != null">peanutArea,</if>
|
||||
<if test="soybeanArea != null">soybeanArea,</if>
|
||||
<if test="otherArea != null">otherArea,</if>
|
||||
<if test="toalArea != null">toalArea,</if>
|
||||
</trim>
|
||||
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||
<if test="zone != null">#{zone},</if>
|
||||
<if test="imageDate != null">#{imageDate},</if>
|
||||
<if test="wheatArea != null">#{wheatArea},</if>
|
||||
<if test="cornArea != null">#{cornArea},</if>
|
||||
<if test="peanutArea != null">#{peanutArea},</if>
|
||||
<if test="soybeanArea != null">#{soybeanArea},</if>
|
||||
<if test="otherArea != null">#{otherArea},</if>
|
||||
<if test="toalArea != null">#{toalArea},</if>
|
||||
</trim>
|
||||
</insert>
|
||||
|
||||
<!-- 批量新增数据 -->
|
||||
<insert id="insertBatch" parameterType="list" keyProperty="id" useGeneratedKeys="true" >
|
||||
insert into ruoyi.crop_structure(zone,imageDate,wheatArea,cornArea,peanutArea,soybeanArea,otherArea,toalArea)
|
||||
values
|
||||
<foreach collection="list" item="entity" separator=",">
|
||||
(#{entity.zone},#{entity.imageDate},#{entity.wheatArea},#{entity.cornArea},#{entity.peanutArea},#{entity.soybeanArea},#{entity.otherArea},#{entity.toalArea})
|
||||
</foreach>
|
||||
</insert>
|
||||
|
||||
<select id="selectByTime" resultMap="CropStructureMap">
|
||||
<include refid="selectCropsStructureVo">
|
||||
</include>
|
||||
where imageDate = #{time}
|
||||
</select>
|
||||
</mapper>
|
@ -0,0 +1,28 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="com.ruoyi.crops.mapper.CropsYieldMapper">
|
||||
<resultMap type="com.ruoyi.crops.domain.CropsYield" id="CropYieldMap">
|
||||
<result property="id" column="id" jdbcType="INTEGER"/>
|
||||
<result property="zone" column="zone" jdbcType="VARCHAR"/>
|
||||
<result property="imageDate" column="imageDate" jdbcType="DATE"/>
|
||||
<result property="cropType" column="cropType" jdbcType="VARCHAR"/>
|
||||
<result property="yield" column="yield" jdbcType="DOUBLE"/>
|
||||
|
||||
</resultMap>
|
||||
<sql id="selectCropsYieldVo">
|
||||
select id,zone,imageDate,cropType,yield from ruoyi.crop_yield
|
||||
</sql>
|
||||
<select id="selectByYear" resultMap="CropYieldMap">
|
||||
<include refid="selectCropsYieldVo">
|
||||
</include>
|
||||
where year(imageDate)=#{time}
|
||||
</select>
|
||||
|
||||
<insert id="insertBatch" parameterType="list" keyProperty="id" useGeneratedKeys="true" >
|
||||
insert into ruoyi.crop_yield(zone,imageDate,cropType,yield)
|
||||
values
|
||||
<foreach collection="list" item="entity" separator=",">
|
||||
(#{entity.zone},#{entity.imageDate},#{entity.cropType},#{entity.yield})
|
||||
</foreach>
|
||||
</insert>
|
||||
</mapper>
|
@ -0,0 +1,25 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="com.ruoyi.crops.mapper.EnvironmentalMapper">
|
||||
<resultMap type="com.ruoyi.crops.domain.EnvironmentalData" id="EnvironmentalDataMap">
|
||||
<result property="id" column="id" jdbcType="INTEGER"/>
|
||||
<result property="greenhouseNumber" column="greenhouse_number" jdbcType="INTEGER"/>
|
||||
<result property="soilTemperature" column="soil_temperature" jdbcType="DOUBLE"/>
|
||||
<result property="soilHumidity" column="soil_humidity" jdbcType="DOUBLE"/>
|
||||
<result property="nitrogenContent" column="nitrogen_content" jdbcType="INTEGER"/>
|
||||
<result property="phosphorusContent" column="phosphorus_content" jdbcType="INTEGER"/>
|
||||
<result property="potassiumContent" column="potassium_content" jdbcType="INTEGER"/>
|
||||
<result property="airTemperature" column="air_temperature" jdbcType="DOUBLE"/>
|
||||
<result property="airHumidity" column="air_humidity" jdbcType="DOUBLE"/>
|
||||
</resultMap>
|
||||
|
||||
<select id="selectByNumber" resultMap="EnvironmentalDataMap">
|
||||
select *from ruoyi.environmental_data
|
||||
where greenhouse_number=#{number}
|
||||
</select>
|
||||
|
||||
<insert id="insert">
|
||||
insert into ruoyi.environmental_data(greenhouse_number, soil_temperature, soil_humidity, nitrogen_content, phosphorus_content, potassium_content, air_temperature, air_humidity)
|
||||
VALUE(#{greenhouseNumber},#{soilTemperature},#{soilHumidity},#{nitrogenContent},#{phosphorusContent},#{potassiumContent},#{airTemperature},#{airHumidity})
|
||||
</insert>
|
||||
</mapper>
|
@ -0,0 +1,20 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="com.ruoyi.crops.mapper.GreenhouseMapper">
|
||||
<resultMap type="com.ruoyi.crops.domain.GreenhouseInformation" id="GreenhouseInformationMap">
|
||||
<result property="id" column="id" jdbcType="INTEGER"/>
|
||||
<result property="zone" column="zone" jdbcType="VARCHAR"/>
|
||||
<result property="managementModel" column="management_model" jdbcType="VARCHAR"/>
|
||||
<result property="introduce" column="introduce" jdbcType="VARCHAR"/>
|
||||
</resultMap>
|
||||
|
||||
<select id="selectByName" resultMap="GreenhouseInformationMap">
|
||||
select *from ruoyi.greenhouse_information
|
||||
where zone=#{name}
|
||||
</select>
|
||||
|
||||
<insert id="insert">
|
||||
insert into ruoyi.greenhouse_information(zone, management_model, introduce)
|
||||
VALUE (#{zone},#{managementModel},#{introduce})
|
||||
</insert>
|
||||
</mapper>
|
@ -0,0 +1,45 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="com.ruoyi.crops.mapper.IntelligentControlMapper">
|
||||
<resultMap type="com.ruoyi.crops.domain.IntelligentControl" id="IntelligentControlMap">
|
||||
<result property="id" column="id" jdbcType="INTEGER"/>
|
||||
<result property="greenhouseName" column="greenhouse_name" jdbcType="VARCHAR"/>
|
||||
<result property="valveNumber" column="valve_number" jdbcType="INTEGER"/>
|
||||
<result property="valveStatus" column="valve_status" jdbcType="INTEGER"/>
|
||||
<result property="disjunctor" column="disjunctor" jdbcType="INTEGER"/>
|
||||
<result property="schedule" column="schedule" jdbcType="DOUBLE"/>
|
||||
</resultMap>
|
||||
|
||||
<insert id="insert">
|
||||
insert into ruoyi.intelligent_control (greenhouse_name, valve_number, valve_status, disjunctor , schedule)
|
||||
VALUE(#{greenhouseName},#{valveNumber},#{valveStatus},#{disjunctor},#{schedule})
|
||||
</insert>
|
||||
|
||||
<select id="selectAll" resultMap="IntelligentControlMap">
|
||||
select *
|
||||
from ruoyi.intelligent_control;
|
||||
</select>
|
||||
|
||||
<!-- 更新数据 -->
|
||||
<update id="edit" parameterType="com.ruoyi.crops.domain.IntelligentControl">
|
||||
update Intelligent_Control
|
||||
<set>
|
||||
<if test="greenhouseName != null and greenhouseName != ''">
|
||||
greenhouse_name = #{greenhouseName},
|
||||
</if>
|
||||
<if test="valveNumber != null and valveNumber != ''">
|
||||
valve_number = #{valveNumber},
|
||||
</if>
|
||||
<if test="valveStatus != null and valveStatus != ''">
|
||||
valve_status = #{valveStatus},
|
||||
</if>
|
||||
<if test="disjunctor != null and disjunctor != ''">
|
||||
disjunctor = #{disjunctor},
|
||||
</if>
|
||||
<if test="schedule != null and schedule != ''">
|
||||
schedule = #{schedule},
|
||||
</if>
|
||||
</set>
|
||||
where id = #{id}
|
||||
</update>
|
||||
</mapper>
|
@ -0,0 +1,25 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="com.ruoyi.crops.mapper.MachineParameterMapper">
|
||||
<resultMap type="com.ruoyi.crops.domain.MachineParameter" id="MachineParameterMap">
|
||||
<result property="id" column="id" jdbcType="INTEGER"/>
|
||||
<result property="greenhouseName" column="greenhouse_name" jdbcType="VARCHAR"/>
|
||||
<result property="pressure" column="pressure" jdbcType="DOUBLE"/>
|
||||
<result property="flow" column="flow" jdbcType="DOUBLE"/>
|
||||
<result property="conductivity" column="conductivity" jdbcType="DOUBLE"/>
|
||||
</resultMap>
|
||||
<sql id="selectMachineParameterVo">
|
||||
select id, greenhouse_name, pressure, flow, conductivity
|
||||
from ruoyi.machine_parameter
|
||||
</sql>
|
||||
<select id="selectByName" resultMap="MachineParameterMap">
|
||||
<include refid="selectMachineParameterVo">
|
||||
</include>
|
||||
where greenhouse_name=#{name}
|
||||
</select>
|
||||
|
||||
<insert id="insert">
|
||||
insert into ruoyi.machine_parameter (greenhouse_name, pressure, flow, conductivity)
|
||||
VALUE (#{greenhouseName},#{pressure},#{flow},#{conductivity})
|
||||
</insert>
|
||||
</mapper>
|
@ -0,0 +1,20 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="com.ruoyi.crops.mapper.OperationRecordsMapper">
|
||||
<resultMap type="com.ruoyi.crops.domain.OperationRecords" id="OperationRecordsMap">
|
||||
<result property="id" column="id" jdbcType="VARCHAR"/>
|
||||
<result property="updateTime" column="update_time" jdbcType="DATETIMEOFFSET"/>
|
||||
<result property="operationContent" column="operation_content" jdbcType="VARCHAR"/>
|
||||
<result property="updateBy" column="update_by" jdbcType="VARCHAR"/>
|
||||
</resultMap>
|
||||
|
||||
<select id="selectAll" resultMap="OperationRecordsMap">
|
||||
select *
|
||||
from ruoyi.operation_records;
|
||||
</select>
|
||||
|
||||
<insert id="insert">
|
||||
insert into ruoyi.operation_records(update_time, operation_content, update_by)
|
||||
VALUE(#{updateTime},#{operationContent},#{updateBy})
|
||||
</insert>
|
||||
</mapper>
|
@ -0,0 +1,38 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="com.ruoyi.crops.mapper.ServiceTypeMapper">
|
||||
<resultMap type="com.ruoyi.crops.domain.ServiceType" id="ServiceTypeMap">
|
||||
<result property="id" column="id" jdbcType="INTEGER"/>
|
||||
<result property="serviceType" column="service_type" jdbcType="VARCHAR"/>
|
||||
<result property="time" column="time" jdbcType="DATE"/>
|
||||
<result property="serviceName" column="service_name" jdbcType="VARCHAR"/>
|
||||
<result property="style" column="style" jdbcType="VARCHAR"/>
|
||||
</resultMap>
|
||||
|
||||
<sql id="selectServiceTypeVo">
|
||||
select id,service_type,time,service_name,style from ruoyi.service_type
|
||||
</sql>
|
||||
<select id="selectByType" resultMap="ServiceTypeMap">
|
||||
<include refid="selectServiceTypeVo">
|
||||
</include>
|
||||
where service_type=#{type}
|
||||
</select>
|
||||
|
||||
<insert id="insert" keyProperty="id" useGeneratedKeys="true">
|
||||
insert into ruoyi.service_type(service_type, time, service_name, style)
|
||||
value (#{serviceType},#{time},#{serviceName},#{style})
|
||||
</insert>
|
||||
|
||||
<select id="selectAll" resultMap="ServiceTypeMap">
|
||||
<include refid="selectServiceTypeVo">
|
||||
</include>
|
||||
</select>
|
||||
|
||||
<delete id="deleteByIds" parameterType="string">
|
||||
delete from ruoyi.service_type where id in
|
||||
<foreach item="id" collection="array" open="(" separator="," close=")">
|
||||
#{id}
|
||||
</foreach>
|
||||
</delete>
|
||||
|
||||
</mapper>
|
@ -0,0 +1,22 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="com.ruoyi.crops.mapper.WarningMapper">
|
||||
<resultMap type="com.ruoyi.crops.domain.WarningInformation" id="WarningInformationMap">
|
||||
<result property="id" column="id" jdbcType="INTEGER"/>
|
||||
<result property="greenhouseNumber" column="greenhouse_number" jdbcType="INTEGER"/>
|
||||
<result property="monitoringIndicators" column="monitoring_indicators" jdbcType="VARCHAR"/>
|
||||
<result property="monitoringValues" column="monitoring_values" jdbcType="DOUBLE"/>
|
||||
<result property="abnormalCause" column="abnormal_cause" jdbcType="VARCHAR"/>
|
||||
<result property="warningTime" column="warning_time" jdbcType="DATE"/>
|
||||
</resultMap>
|
||||
|
||||
<select id="selectByNumber" resultMap="WarningInformationMap">
|
||||
select * from ruoyi.warning_information
|
||||
where greenhouse_number= #{number}
|
||||
</select>
|
||||
|
||||
<insert id="insert">
|
||||
insert into ruoyi.warning_information(greenhouse_number, monitoring_indicators, monitoring_values, abnormal_cause, warning_time)
|
||||
VALUE(#{greenhouseNumber},#{monitoringIndicators},#{monitoringValues},#{abnormalCause},#{warningTime})
|
||||
</insert>
|
||||
</mapper>
|
Reference in New Issue
Block a user