商汤线上版本维护更新
This commit is contained in:
28
ruoyi-system/pom.xml
Normal file
28
ruoyi-system/pom.xml
Normal file
@ -0,0 +1,28 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project xmlns="http://maven.apache.org/POM/4.0.0"
|
||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
|
||||
<parent>
|
||||
<artifactId>ruoyi</artifactId>
|
||||
<groupId>com.ruoyi</groupId>
|
||||
<version>3.8.2</version>
|
||||
</parent>
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
|
||||
<artifactId>ruoyi-system</artifactId>
|
||||
|
||||
<description>
|
||||
system系统模块
|
||||
</description>
|
||||
|
||||
<dependencies>
|
||||
|
||||
<!-- 通用工具-->
|
||||
<dependency>
|
||||
<groupId>com.ruoyi</groupId>
|
||||
<artifactId>ruoyi-common</artifactId>
|
||||
</dependency>
|
||||
|
||||
</dependencies>
|
||||
|
||||
</project>
|
@ -0,0 +1,111 @@
|
||||
package com.ruoyi.system.domain;
|
||||
|
||||
import javax.validation.constraints.NotBlank;
|
||||
import javax.validation.constraints.Size;
|
||||
import org.apache.commons.lang3.builder.ToStringBuilder;
|
||||
import org.apache.commons.lang3.builder.ToStringStyle;
|
||||
import com.ruoyi.common.annotation.Excel;
|
||||
import com.ruoyi.common.annotation.Excel.ColumnType;
|
||||
import com.ruoyi.common.core.domain.BaseEntity;
|
||||
|
||||
/**
|
||||
* 参数配置表 sys_config
|
||||
*
|
||||
* @author ruoyi
|
||||
*/
|
||||
public class SysConfig extends BaseEntity
|
||||
{
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/** 参数主键 */
|
||||
@Excel(name = "参数主键", cellType = ColumnType.NUMERIC)
|
||||
private Long configId;
|
||||
|
||||
/** 参数名称 */
|
||||
@Excel(name = "参数名称")
|
||||
private String configName;
|
||||
|
||||
/** 参数键名 */
|
||||
@Excel(name = "参数键名")
|
||||
private String configKey;
|
||||
|
||||
/** 参数键值 */
|
||||
@Excel(name = "参数键值")
|
||||
private String configValue;
|
||||
|
||||
/** 系统内置(Y是 N否) */
|
||||
@Excel(name = "系统内置", readConverterExp = "Y=是,N=否")
|
||||
private String configType;
|
||||
|
||||
public Long getConfigId()
|
||||
{
|
||||
return configId;
|
||||
}
|
||||
|
||||
public void setConfigId(Long configId)
|
||||
{
|
||||
this.configId = configId;
|
||||
}
|
||||
|
||||
@NotBlank(message = "参数名称不能为空")
|
||||
@Size(min = 0, max = 100, message = "参数名称不能超过100个字符")
|
||||
public String getConfigName()
|
||||
{
|
||||
return configName;
|
||||
}
|
||||
|
||||
public void setConfigName(String configName)
|
||||
{
|
||||
this.configName = configName;
|
||||
}
|
||||
|
||||
@NotBlank(message = "参数键名长度不能为空")
|
||||
@Size(min = 0, max = 100, message = "参数键名长度不能超过100个字符")
|
||||
public String getConfigKey()
|
||||
{
|
||||
return configKey;
|
||||
}
|
||||
|
||||
public void setConfigKey(String configKey)
|
||||
{
|
||||
this.configKey = configKey;
|
||||
}
|
||||
|
||||
@NotBlank(message = "参数键值不能为空")
|
||||
@Size(min = 0, max = 500, message = "参数键值长度不能超过500个字符")
|
||||
public String getConfigValue()
|
||||
{
|
||||
return configValue;
|
||||
}
|
||||
|
||||
public void setConfigValue(String configValue)
|
||||
{
|
||||
this.configValue = configValue;
|
||||
}
|
||||
|
||||
public String getConfigType()
|
||||
{
|
||||
return configType;
|
||||
}
|
||||
|
||||
public void setConfigType(String configType)
|
||||
{
|
||||
this.configType = configType;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
|
||||
.append("configId", getConfigId())
|
||||
.append("configName", getConfigName())
|
||||
.append("configKey", getConfigKey())
|
||||
.append("configValue", getConfigValue())
|
||||
.append("configType", getConfigType())
|
||||
.append("createBy", getCreateBy())
|
||||
.append("createTime", getCreateTime())
|
||||
.append("updateBy", getUpdateBy())
|
||||
.append("updateTime", getUpdateTime())
|
||||
.append("remark", getRemark())
|
||||
.toString();
|
||||
}
|
||||
}
|
@ -0,0 +1,144 @@
|
||||
package com.ruoyi.system.domain;
|
||||
|
||||
import java.util.Date;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import com.ruoyi.common.annotation.Excel;
|
||||
import com.ruoyi.common.annotation.Excel.ColumnType;
|
||||
import com.ruoyi.common.core.domain.BaseEntity;
|
||||
|
||||
/**
|
||||
* 系统访问记录表 sys_logininfor
|
||||
*
|
||||
* @author ruoyi
|
||||
*/
|
||||
public class SysLogininfor extends BaseEntity
|
||||
{
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/** ID */
|
||||
@Excel(name = "序号", cellType = ColumnType.NUMERIC)
|
||||
private Long infoId;
|
||||
|
||||
/** 用户账号 */
|
||||
@Excel(name = "用户账号")
|
||||
private String userName;
|
||||
|
||||
/** 登录状态 0成功 1失败 */
|
||||
@Excel(name = "登录状态", readConverterExp = "0=成功,1=失败")
|
||||
private String status;
|
||||
|
||||
/** 登录IP地址 */
|
||||
@Excel(name = "登录地址")
|
||||
private String ipaddr;
|
||||
|
||||
/** 登录地点 */
|
||||
@Excel(name = "登录地点")
|
||||
private String loginLocation;
|
||||
|
||||
/** 浏览器类型 */
|
||||
@Excel(name = "浏览器")
|
||||
private String browser;
|
||||
|
||||
/** 操作系统 */
|
||||
@Excel(name = "操作系统")
|
||||
private String os;
|
||||
|
||||
/** 提示消息 */
|
||||
@Excel(name = "提示消息")
|
||||
private String msg;
|
||||
|
||||
/** 访问时间 */
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@Excel(name = "访问时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
|
||||
private Date loginTime;
|
||||
|
||||
public Long getInfoId()
|
||||
{
|
||||
return infoId;
|
||||
}
|
||||
|
||||
public void setInfoId(Long infoId)
|
||||
{
|
||||
this.infoId = infoId;
|
||||
}
|
||||
|
||||
public String getUserName()
|
||||
{
|
||||
return userName;
|
||||
}
|
||||
|
||||
public void setUserName(String userName)
|
||||
{
|
||||
this.userName = userName;
|
||||
}
|
||||
|
||||
public String getStatus()
|
||||
{
|
||||
return status;
|
||||
}
|
||||
|
||||
public void setStatus(String status)
|
||||
{
|
||||
this.status = status;
|
||||
}
|
||||
|
||||
public String getIpaddr()
|
||||
{
|
||||
return ipaddr;
|
||||
}
|
||||
|
||||
public void setIpaddr(String ipaddr)
|
||||
{
|
||||
this.ipaddr = ipaddr;
|
||||
}
|
||||
|
||||
public String getLoginLocation()
|
||||
{
|
||||
return loginLocation;
|
||||
}
|
||||
|
||||
public void setLoginLocation(String loginLocation)
|
||||
{
|
||||
this.loginLocation = loginLocation;
|
||||
}
|
||||
|
||||
public String getBrowser()
|
||||
{
|
||||
return browser;
|
||||
}
|
||||
|
||||
public void setBrowser(String browser)
|
||||
{
|
||||
this.browser = browser;
|
||||
}
|
||||
|
||||
public String getOs()
|
||||
{
|
||||
return os;
|
||||
}
|
||||
|
||||
public void setOs(String os)
|
||||
{
|
||||
this.os = os;
|
||||
}
|
||||
|
||||
public String getMsg()
|
||||
{
|
||||
return msg;
|
||||
}
|
||||
|
||||
public void setMsg(String msg)
|
||||
{
|
||||
this.msg = msg;
|
||||
}
|
||||
|
||||
public Date getLoginTime()
|
||||
{
|
||||
return loginTime;
|
||||
}
|
||||
|
||||
public void setLoginTime(Date loginTime)
|
||||
{
|
||||
this.loginTime = loginTime;
|
||||
}
|
||||
}
|
@ -0,0 +1,102 @@
|
||||
package com.ruoyi.system.domain;
|
||||
|
||||
import javax.validation.constraints.NotBlank;
|
||||
import javax.validation.constraints.Size;
|
||||
import org.apache.commons.lang3.builder.ToStringBuilder;
|
||||
import org.apache.commons.lang3.builder.ToStringStyle;
|
||||
import com.ruoyi.common.core.domain.BaseEntity;
|
||||
import com.ruoyi.common.xss.Xss;
|
||||
|
||||
/**
|
||||
* 通知公告表 sys_notice
|
||||
*
|
||||
* @author ruoyi
|
||||
*/
|
||||
public class SysNotice extends BaseEntity
|
||||
{
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/** 公告ID */
|
||||
private Long noticeId;
|
||||
|
||||
/** 公告标题 */
|
||||
private String noticeTitle;
|
||||
|
||||
/** 公告类型(1通知 2公告) */
|
||||
private String noticeType;
|
||||
|
||||
/** 公告内容 */
|
||||
private String noticeContent;
|
||||
|
||||
/** 公告状态(0正常 1关闭) */
|
||||
private String status;
|
||||
|
||||
public Long getNoticeId()
|
||||
{
|
||||
return noticeId;
|
||||
}
|
||||
|
||||
public void setNoticeId(Long noticeId)
|
||||
{
|
||||
this.noticeId = noticeId;
|
||||
}
|
||||
|
||||
public void setNoticeTitle(String noticeTitle)
|
||||
{
|
||||
this.noticeTitle = noticeTitle;
|
||||
}
|
||||
|
||||
@Xss(message = "公告标题不能包含脚本字符")
|
||||
@NotBlank(message = "公告标题不能为空")
|
||||
@Size(min = 0, max = 50, message = "公告标题不能超过50个字符")
|
||||
public String getNoticeTitle()
|
||||
{
|
||||
return noticeTitle;
|
||||
}
|
||||
|
||||
public void setNoticeType(String noticeType)
|
||||
{
|
||||
this.noticeType = noticeType;
|
||||
}
|
||||
|
||||
public String getNoticeType()
|
||||
{
|
||||
return noticeType;
|
||||
}
|
||||
|
||||
public void setNoticeContent(String noticeContent)
|
||||
{
|
||||
this.noticeContent = noticeContent;
|
||||
}
|
||||
|
||||
public String getNoticeContent()
|
||||
{
|
||||
return noticeContent;
|
||||
}
|
||||
|
||||
public void setStatus(String status)
|
||||
{
|
||||
this.status = status;
|
||||
}
|
||||
|
||||
public String getStatus()
|
||||
{
|
||||
return status;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
|
||||
.append("noticeId", getNoticeId())
|
||||
.append("noticeTitle", getNoticeTitle())
|
||||
.append("noticeType", getNoticeType())
|
||||
.append("noticeContent", getNoticeContent())
|
||||
.append("status", getStatus())
|
||||
.append("createBy", getCreateBy())
|
||||
.append("createTime", getCreateTime())
|
||||
.append("updateBy", getUpdateBy())
|
||||
.append("updateTime", getUpdateTime())
|
||||
.append("remark", getRemark())
|
||||
.toString();
|
||||
}
|
||||
}
|
@ -0,0 +1,255 @@
|
||||
package com.ruoyi.system.domain;
|
||||
|
||||
import java.util.Date;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import com.ruoyi.common.annotation.Excel;
|
||||
import com.ruoyi.common.annotation.Excel.ColumnType;
|
||||
import com.ruoyi.common.core.domain.BaseEntity;
|
||||
|
||||
/**
|
||||
* 操作日志记录表 oper_log
|
||||
*
|
||||
* @author ruoyi
|
||||
*/
|
||||
public class SysOperLog extends BaseEntity
|
||||
{
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/** 日志主键 */
|
||||
@Excel(name = "操作序号", cellType = ColumnType.NUMERIC)
|
||||
private Long operId;
|
||||
|
||||
/** 操作模块 */
|
||||
@Excel(name = "操作模块")
|
||||
private String title;
|
||||
|
||||
/** 业务类型(0其它 1新增 2修改 3删除) */
|
||||
@Excel(name = "业务类型", readConverterExp = "0=其它,1=新增,2=修改,3=删除,4=授权,5=导出,6=导入,7=强退,8=生成代码,9=清空数据")
|
||||
private Integer businessType;
|
||||
|
||||
/** 业务类型数组 */
|
||||
private Integer[] businessTypes;
|
||||
|
||||
/** 请求方法 */
|
||||
@Excel(name = "请求方法")
|
||||
private String method;
|
||||
|
||||
/** 请求方式 */
|
||||
@Excel(name = "请求方式")
|
||||
private String requestMethod;
|
||||
|
||||
/** 操作类别(0其它 1后台用户 2手机端用户) */
|
||||
@Excel(name = "操作类别", readConverterExp = "0=其它,1=后台用户,2=手机端用户")
|
||||
private Integer operatorType;
|
||||
|
||||
/** 操作人员 */
|
||||
@Excel(name = "操作人员")
|
||||
private String operName;
|
||||
|
||||
/** 部门名称 */
|
||||
@Excel(name = "部门名称")
|
||||
private String deptName;
|
||||
|
||||
/** 请求url */
|
||||
@Excel(name = "请求地址")
|
||||
private String operUrl;
|
||||
|
||||
/** 操作地址 */
|
||||
@Excel(name = "操作地址")
|
||||
private String operIp;
|
||||
|
||||
/** 操作地点 */
|
||||
@Excel(name = "操作地点")
|
||||
private String operLocation;
|
||||
|
||||
/** 请求参数 */
|
||||
@Excel(name = "请求参数")
|
||||
private String operParam;
|
||||
|
||||
/** 返回参数 */
|
||||
@Excel(name = "返回参数")
|
||||
private String jsonResult;
|
||||
|
||||
/** 操作状态(0正常 1异常) */
|
||||
@Excel(name = "状态", readConverterExp = "0=正常,1=异常")
|
||||
private Integer status;
|
||||
|
||||
/** 错误消息 */
|
||||
@Excel(name = "错误消息")
|
||||
private String errorMsg;
|
||||
|
||||
/** 操作时间 */
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@Excel(name = "操作时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
|
||||
private Date operTime;
|
||||
|
||||
public Long getOperId()
|
||||
{
|
||||
return operId;
|
||||
}
|
||||
|
||||
public void setOperId(Long operId)
|
||||
{
|
||||
this.operId = operId;
|
||||
}
|
||||
|
||||
public String getTitle()
|
||||
{
|
||||
return title;
|
||||
}
|
||||
|
||||
public void setTitle(String title)
|
||||
{
|
||||
this.title = title;
|
||||
}
|
||||
|
||||
public Integer getBusinessType()
|
||||
{
|
||||
return businessType;
|
||||
}
|
||||
|
||||
public void setBusinessType(Integer businessType)
|
||||
{
|
||||
this.businessType = businessType;
|
||||
}
|
||||
|
||||
public Integer[] getBusinessTypes()
|
||||
{
|
||||
return businessTypes;
|
||||
}
|
||||
|
||||
public void setBusinessTypes(Integer[] businessTypes)
|
||||
{
|
||||
this.businessTypes = businessTypes;
|
||||
}
|
||||
|
||||
public String getMethod()
|
||||
{
|
||||
return method;
|
||||
}
|
||||
|
||||
public void setMethod(String method)
|
||||
{
|
||||
this.method = method;
|
||||
}
|
||||
|
||||
public String getRequestMethod()
|
||||
{
|
||||
return requestMethod;
|
||||
}
|
||||
|
||||
public void setRequestMethod(String requestMethod)
|
||||
{
|
||||
this.requestMethod = requestMethod;
|
||||
}
|
||||
|
||||
public Integer getOperatorType()
|
||||
{
|
||||
return operatorType;
|
||||
}
|
||||
|
||||
public void setOperatorType(Integer operatorType)
|
||||
{
|
||||
this.operatorType = operatorType;
|
||||
}
|
||||
|
||||
public String getOperName()
|
||||
{
|
||||
return operName;
|
||||
}
|
||||
|
||||
public void setOperName(String operName)
|
||||
{
|
||||
this.operName = operName;
|
||||
}
|
||||
|
||||
public String getDeptName()
|
||||
{
|
||||
return deptName;
|
||||
}
|
||||
|
||||
public void setDeptName(String deptName)
|
||||
{
|
||||
this.deptName = deptName;
|
||||
}
|
||||
|
||||
public String getOperUrl()
|
||||
{
|
||||
return operUrl;
|
||||
}
|
||||
|
||||
public void setOperUrl(String operUrl)
|
||||
{
|
||||
this.operUrl = operUrl;
|
||||
}
|
||||
|
||||
public String getOperIp()
|
||||
{
|
||||
return operIp;
|
||||
}
|
||||
|
||||
public void setOperIp(String operIp)
|
||||
{
|
||||
this.operIp = operIp;
|
||||
}
|
||||
|
||||
public String getOperLocation()
|
||||
{
|
||||
return operLocation;
|
||||
}
|
||||
|
||||
public void setOperLocation(String operLocation)
|
||||
{
|
||||
this.operLocation = operLocation;
|
||||
}
|
||||
|
||||
public String getOperParam()
|
||||
{
|
||||
return operParam;
|
||||
}
|
||||
|
||||
public void setOperParam(String operParam)
|
||||
{
|
||||
this.operParam = operParam;
|
||||
}
|
||||
|
||||
public String getJsonResult()
|
||||
{
|
||||
return jsonResult;
|
||||
}
|
||||
|
||||
public void setJsonResult(String jsonResult)
|
||||
{
|
||||
this.jsonResult = jsonResult;
|
||||
}
|
||||
|
||||
public Integer getStatus()
|
||||
{
|
||||
return status;
|
||||
}
|
||||
|
||||
public void setStatus(Integer status)
|
||||
{
|
||||
this.status = status;
|
||||
}
|
||||
|
||||
public String getErrorMsg()
|
||||
{
|
||||
return errorMsg;
|
||||
}
|
||||
|
||||
public void setErrorMsg(String errorMsg)
|
||||
{
|
||||
this.errorMsg = errorMsg;
|
||||
}
|
||||
|
||||
public Date getOperTime()
|
||||
{
|
||||
return operTime;
|
||||
}
|
||||
|
||||
public void setOperTime(Date operTime)
|
||||
{
|
||||
this.operTime = operTime;
|
||||
}
|
||||
}
|
123
ruoyi-system/src/main/java/com/ruoyi/system/domain/SysPost.java
Normal file
123
ruoyi-system/src/main/java/com/ruoyi/system/domain/SysPost.java
Normal file
@ -0,0 +1,123 @@
|
||||
package com.ruoyi.system.domain;
|
||||
|
||||
import javax.validation.constraints.NotBlank;
|
||||
import javax.validation.constraints.Size;
|
||||
import org.apache.commons.lang3.builder.ToStringBuilder;
|
||||
import org.apache.commons.lang3.builder.ToStringStyle;
|
||||
import com.ruoyi.common.annotation.Excel;
|
||||
import com.ruoyi.common.annotation.Excel.ColumnType;
|
||||
import com.ruoyi.common.core.domain.BaseEntity;
|
||||
|
||||
/**
|
||||
* 岗位表 sys_post
|
||||
*
|
||||
* @author ruoyi
|
||||
*/
|
||||
public class SysPost extends BaseEntity
|
||||
{
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/** 岗位序号 */
|
||||
@Excel(name = "岗位序号", cellType = ColumnType.NUMERIC)
|
||||
private Long postId;
|
||||
|
||||
/** 岗位编码 */
|
||||
@Excel(name = "岗位编码")
|
||||
private String postCode;
|
||||
|
||||
/** 岗位名称 */
|
||||
@Excel(name = "岗位名称")
|
||||
private String postName;
|
||||
|
||||
/** 岗位排序 */
|
||||
@Excel(name = "岗位排序")
|
||||
private String postSort;
|
||||
|
||||
/** 状态(0正常 1停用) */
|
||||
@Excel(name = "状态", readConverterExp = "0=正常,1=停用")
|
||||
private String status;
|
||||
|
||||
/** 用户是否存在此岗位标识 默认不存在 */
|
||||
private boolean flag = false;
|
||||
|
||||
public Long getPostId()
|
||||
{
|
||||
return postId;
|
||||
}
|
||||
|
||||
public void setPostId(Long postId)
|
||||
{
|
||||
this.postId = postId;
|
||||
}
|
||||
|
||||
@NotBlank(message = "岗位编码不能为空")
|
||||
@Size(min = 0, max = 64, message = "岗位编码长度不能超过64个字符")
|
||||
public String getPostCode()
|
||||
{
|
||||
return postCode;
|
||||
}
|
||||
|
||||
public void setPostCode(String postCode)
|
||||
{
|
||||
this.postCode = postCode;
|
||||
}
|
||||
|
||||
@NotBlank(message = "岗位名称不能为空")
|
||||
@Size(min = 0, max = 50, message = "岗位名称长度不能超过50个字符")
|
||||
public String getPostName()
|
||||
{
|
||||
return postName;
|
||||
}
|
||||
|
||||
public void setPostName(String postName)
|
||||
{
|
||||
this.postName = postName;
|
||||
}
|
||||
|
||||
@NotBlank(message = "显示顺序不能为空")
|
||||
public String getPostSort()
|
||||
{
|
||||
return postSort;
|
||||
}
|
||||
|
||||
public void setPostSort(String postSort)
|
||||
{
|
||||
this.postSort = postSort;
|
||||
}
|
||||
|
||||
public String getStatus()
|
||||
{
|
||||
return status;
|
||||
}
|
||||
|
||||
public void setStatus(String status)
|
||||
{
|
||||
this.status = status;
|
||||
}
|
||||
|
||||
public boolean isFlag()
|
||||
{
|
||||
return flag;
|
||||
}
|
||||
|
||||
public void setFlag(boolean flag)
|
||||
{
|
||||
this.flag = flag;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
|
||||
.append("postId", getPostId())
|
||||
.append("postCode", getPostCode())
|
||||
.append("postName", getPostName())
|
||||
.append("postSort", getPostSort())
|
||||
.append("status", getStatus())
|
||||
.append("createBy", getCreateBy())
|
||||
.append("createTime", getCreateTime())
|
||||
.append("updateBy", getUpdateBy())
|
||||
.append("updateTime", getUpdateTime())
|
||||
.append("remark", getRemark())
|
||||
.toString();
|
||||
}
|
||||
}
|
@ -0,0 +1,46 @@
|
||||
package com.ruoyi.system.domain;
|
||||
|
||||
import org.apache.commons.lang3.builder.ToStringBuilder;
|
||||
import org.apache.commons.lang3.builder.ToStringStyle;
|
||||
|
||||
/**
|
||||
* 角色和部门关联 sys_role_dept
|
||||
*
|
||||
* @author ruoyi
|
||||
*/
|
||||
public class SysRoleDept
|
||||
{
|
||||
/** 角色ID */
|
||||
private Long roleId;
|
||||
|
||||
/** 部门ID */
|
||||
private Long deptId;
|
||||
|
||||
public Long getRoleId()
|
||||
{
|
||||
return roleId;
|
||||
}
|
||||
|
||||
public void setRoleId(Long roleId)
|
||||
{
|
||||
this.roleId = roleId;
|
||||
}
|
||||
|
||||
public Long getDeptId()
|
||||
{
|
||||
return deptId;
|
||||
}
|
||||
|
||||
public void setDeptId(Long deptId)
|
||||
{
|
||||
this.deptId = deptId;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
|
||||
.append("roleId", getRoleId())
|
||||
.append("deptId", getDeptId())
|
||||
.toString();
|
||||
}
|
||||
}
|
@ -0,0 +1,46 @@
|
||||
package com.ruoyi.system.domain;
|
||||
|
||||
import org.apache.commons.lang3.builder.ToStringBuilder;
|
||||
import org.apache.commons.lang3.builder.ToStringStyle;
|
||||
|
||||
/**
|
||||
* 角色和菜单关联 sys_role_menu
|
||||
*
|
||||
* @author ruoyi
|
||||
*/
|
||||
public class SysRoleMenu
|
||||
{
|
||||
/** 角色ID */
|
||||
private Long roleId;
|
||||
|
||||
/** 菜单ID */
|
||||
private Long menuId;
|
||||
|
||||
public Long getRoleId()
|
||||
{
|
||||
return roleId;
|
||||
}
|
||||
|
||||
public void setRoleId(Long roleId)
|
||||
{
|
||||
this.roleId = roleId;
|
||||
}
|
||||
|
||||
public Long getMenuId()
|
||||
{
|
||||
return menuId;
|
||||
}
|
||||
|
||||
public void setMenuId(Long menuId)
|
||||
{
|
||||
this.menuId = menuId;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
|
||||
.append("roleId", getRoleId())
|
||||
.append("menuId", getMenuId())
|
||||
.toString();
|
||||
}
|
||||
}
|
@ -0,0 +1,113 @@
|
||||
package com.ruoyi.system.domain;
|
||||
|
||||
/**
|
||||
* 当前在线会话
|
||||
*
|
||||
* @author ruoyi
|
||||
*/
|
||||
public class SysUserOnline
|
||||
{
|
||||
/** 会话编号 */
|
||||
private String tokenId;
|
||||
|
||||
/** 部门名称 */
|
||||
private String deptName;
|
||||
|
||||
/** 用户名称 */
|
||||
private String userName;
|
||||
|
||||
/** 登录IP地址 */
|
||||
private String ipaddr;
|
||||
|
||||
/** 登录地址 */
|
||||
private String loginLocation;
|
||||
|
||||
/** 浏览器类型 */
|
||||
private String browser;
|
||||
|
||||
/** 操作系统 */
|
||||
private String os;
|
||||
|
||||
/** 登录时间 */
|
||||
private Long loginTime;
|
||||
|
||||
public String getTokenId()
|
||||
{
|
||||
return tokenId;
|
||||
}
|
||||
|
||||
public void setTokenId(String tokenId)
|
||||
{
|
||||
this.tokenId = tokenId;
|
||||
}
|
||||
|
||||
public String getDeptName()
|
||||
{
|
||||
return deptName;
|
||||
}
|
||||
|
||||
public void setDeptName(String deptName)
|
||||
{
|
||||
this.deptName = deptName;
|
||||
}
|
||||
|
||||
public String getUserName()
|
||||
{
|
||||
return userName;
|
||||
}
|
||||
|
||||
public void setUserName(String userName)
|
||||
{
|
||||
this.userName = userName;
|
||||
}
|
||||
|
||||
public String getIpaddr()
|
||||
{
|
||||
return ipaddr;
|
||||
}
|
||||
|
||||
public void setIpaddr(String ipaddr)
|
||||
{
|
||||
this.ipaddr = ipaddr;
|
||||
}
|
||||
|
||||
public String getLoginLocation()
|
||||
{
|
||||
return loginLocation;
|
||||
}
|
||||
|
||||
public void setLoginLocation(String loginLocation)
|
||||
{
|
||||
this.loginLocation = loginLocation;
|
||||
}
|
||||
|
||||
public String getBrowser()
|
||||
{
|
||||
return browser;
|
||||
}
|
||||
|
||||
public void setBrowser(String browser)
|
||||
{
|
||||
this.browser = browser;
|
||||
}
|
||||
|
||||
public String getOs()
|
||||
{
|
||||
return os;
|
||||
}
|
||||
|
||||
public void setOs(String os)
|
||||
{
|
||||
this.os = os;
|
||||
}
|
||||
|
||||
public Long getLoginTime()
|
||||
{
|
||||
return loginTime;
|
||||
}
|
||||
|
||||
public void setLoginTime(Long loginTime)
|
||||
{
|
||||
this.loginTime = loginTime;
|
||||
}
|
||||
}
|
@ -0,0 +1,46 @@
|
||||
package com.ruoyi.system.domain;
|
||||
|
||||
import org.apache.commons.lang3.builder.ToStringBuilder;
|
||||
import org.apache.commons.lang3.builder.ToStringStyle;
|
||||
|
||||
/**
|
||||
* 用户和岗位关联 sys_user_post
|
||||
*
|
||||
* @author ruoyi
|
||||
*/
|
||||
public class SysUserPost
|
||||
{
|
||||
/** 用户ID */
|
||||
private Long userId;
|
||||
|
||||
/** 岗位ID */
|
||||
private Long postId;
|
||||
|
||||
public Long getUserId()
|
||||
{
|
||||
return userId;
|
||||
}
|
||||
|
||||
public void setUserId(Long userId)
|
||||
{
|
||||
this.userId = userId;
|
||||
}
|
||||
|
||||
public Long getPostId()
|
||||
{
|
||||
return postId;
|
||||
}
|
||||
|
||||
public void setPostId(Long postId)
|
||||
{
|
||||
this.postId = postId;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
|
||||
.append("userId", getUserId())
|
||||
.append("postId", getPostId())
|
||||
.toString();
|
||||
}
|
||||
}
|
@ -0,0 +1,46 @@
|
||||
package com.ruoyi.system.domain;
|
||||
|
||||
import org.apache.commons.lang3.builder.ToStringBuilder;
|
||||
import org.apache.commons.lang3.builder.ToStringStyle;
|
||||
|
||||
/**
|
||||
* 用户和角色关联 sys_user_role
|
||||
*
|
||||
* @author ruoyi
|
||||
*/
|
||||
public class SysUserRole
|
||||
{
|
||||
/** 用户ID */
|
||||
private Long userId;
|
||||
|
||||
/** 角色ID */
|
||||
private Long roleId;
|
||||
|
||||
public Long getUserId()
|
||||
{
|
||||
return userId;
|
||||
}
|
||||
|
||||
public void setUserId(Long userId)
|
||||
{
|
||||
this.userId = userId;
|
||||
}
|
||||
|
||||
public Long getRoleId()
|
||||
{
|
||||
return roleId;
|
||||
}
|
||||
|
||||
public void setRoleId(Long roleId)
|
||||
{
|
||||
this.roleId = roleId;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
|
||||
.append("userId", getUserId())
|
||||
.append("roleId", getRoleId())
|
||||
.toString();
|
||||
}
|
||||
}
|
@ -0,0 +1,106 @@
|
||||
package com.ruoyi.system.domain.vo;
|
||||
|
||||
import com.ruoyi.common.utils.StringUtils;
|
||||
|
||||
/**
|
||||
* 路由显示信息
|
||||
*
|
||||
* @author ruoyi
|
||||
*/
|
||||
public class MetaVo
|
||||
{
|
||||
/**
|
||||
* 设置该路由在侧边栏和面包屑中展示的名字
|
||||
*/
|
||||
private String title;
|
||||
|
||||
/**
|
||||
* 设置该路由的图标,对应路径src/assets/icons/svg
|
||||
*/
|
||||
private String icon;
|
||||
|
||||
/**
|
||||
* 设置为true,则不会被 <keep-alive>缓存
|
||||
*/
|
||||
private boolean noCache;
|
||||
|
||||
/**
|
||||
* 内链地址(http(s)://开头)
|
||||
*/
|
||||
private String link;
|
||||
|
||||
public MetaVo()
|
||||
{
|
||||
}
|
||||
|
||||
public MetaVo(String title, String icon)
|
||||
{
|
||||
this.title = title;
|
||||
this.icon = icon;
|
||||
}
|
||||
|
||||
public MetaVo(String title, String icon, boolean noCache)
|
||||
{
|
||||
this.title = title;
|
||||
this.icon = icon;
|
||||
this.noCache = noCache;
|
||||
}
|
||||
|
||||
public MetaVo(String title, String icon, String link)
|
||||
{
|
||||
this.title = title;
|
||||
this.icon = icon;
|
||||
this.link = link;
|
||||
}
|
||||
|
||||
public MetaVo(String title, String icon, boolean noCache, String link)
|
||||
{
|
||||
this.title = title;
|
||||
this.icon = icon;
|
||||
this.noCache = noCache;
|
||||
if (StringUtils.ishttp(link))
|
||||
{
|
||||
this.link = link;
|
||||
}
|
||||
}
|
||||
|
||||
public boolean isNoCache()
|
||||
{
|
||||
return noCache;
|
||||
}
|
||||
|
||||
public void setNoCache(boolean noCache)
|
||||
{
|
||||
this.noCache = noCache;
|
||||
}
|
||||
|
||||
public String getTitle()
|
||||
{
|
||||
return title;
|
||||
}
|
||||
|
||||
public void setTitle(String title)
|
||||
{
|
||||
this.title = title;
|
||||
}
|
||||
|
||||
public String getIcon()
|
||||
{
|
||||
return icon;
|
||||
}
|
||||
|
||||
public void setIcon(String icon)
|
||||
{
|
||||
this.icon = icon;
|
||||
}
|
||||
|
||||
public String getLink()
|
||||
{
|
||||
return link;
|
||||
}
|
||||
|
||||
public void setLink(String link)
|
||||
{
|
||||
this.link = link;
|
||||
}
|
||||
}
|
@ -0,0 +1,148 @@
|
||||
package com.ruoyi.system.domain.vo;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonInclude;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 路由配置信息
|
||||
*
|
||||
* @author ruoyi
|
||||
*/
|
||||
@JsonInclude(JsonInclude.Include.NON_EMPTY)
|
||||
public class RouterVo
|
||||
{
|
||||
/**
|
||||
* 路由名字
|
||||
*/
|
||||
private String name;
|
||||
|
||||
/**
|
||||
* 路由地址
|
||||
*/
|
||||
private String path;
|
||||
|
||||
/**
|
||||
* 是否隐藏路由,当设置 true 的时候该路由不会再侧边栏出现
|
||||
*/
|
||||
private boolean hidden;
|
||||
|
||||
/**
|
||||
* 重定向地址,当设置 noRedirect 的时候该路由在面包屑导航中不可被点击
|
||||
*/
|
||||
private String redirect;
|
||||
|
||||
/**
|
||||
* 组件地址
|
||||
*/
|
||||
private String component;
|
||||
|
||||
/**
|
||||
* 路由参数:如 {"id": 1, "name": "ry"}
|
||||
*/
|
||||
private String query;
|
||||
|
||||
/**
|
||||
* 当你一个路由下面的 children 声明的路由大于1个时,自动会变成嵌套的模式--如组件页面
|
||||
*/
|
||||
private Boolean alwaysShow;
|
||||
|
||||
/**
|
||||
* 其他元素
|
||||
*/
|
||||
private MetaVo meta;
|
||||
|
||||
/**
|
||||
* 子路由
|
||||
*/
|
||||
private List<RouterVo> children;
|
||||
|
||||
public String getName()
|
||||
{
|
||||
return name;
|
||||
}
|
||||
|
||||
public void setName(String name)
|
||||
{
|
||||
this.name = name;
|
||||
}
|
||||
|
||||
public String getPath()
|
||||
{
|
||||
return path;
|
||||
}
|
||||
|
||||
public void setPath(String path)
|
||||
{
|
||||
this.path = path;
|
||||
}
|
||||
|
||||
public boolean getHidden()
|
||||
{
|
||||
return hidden;
|
||||
}
|
||||
|
||||
public void setHidden(boolean hidden)
|
||||
{
|
||||
this.hidden = hidden;
|
||||
}
|
||||
|
||||
public String getRedirect()
|
||||
{
|
||||
return redirect;
|
||||
}
|
||||
|
||||
public void setRedirect(String redirect)
|
||||
{
|
||||
this.redirect = redirect;
|
||||
}
|
||||
|
||||
public String getComponent()
|
||||
{
|
||||
return component;
|
||||
}
|
||||
|
||||
public void setComponent(String component)
|
||||
{
|
||||
this.component = component;
|
||||
}
|
||||
|
||||
public String getQuery()
|
||||
{
|
||||
return query;
|
||||
}
|
||||
|
||||
public void setQuery(String query)
|
||||
{
|
||||
this.query = query;
|
||||
}
|
||||
|
||||
public Boolean getAlwaysShow()
|
||||
{
|
||||
return alwaysShow;
|
||||
}
|
||||
|
||||
public void setAlwaysShow(Boolean alwaysShow)
|
||||
{
|
||||
this.alwaysShow = alwaysShow;
|
||||
}
|
||||
|
||||
public MetaVo getMeta()
|
||||
{
|
||||
return meta;
|
||||
}
|
||||
|
||||
public void setMeta(MetaVo meta)
|
||||
{
|
||||
this.meta = meta;
|
||||
}
|
||||
|
||||
public List<RouterVo> getChildren()
|
||||
{
|
||||
return children;
|
||||
}
|
||||
|
||||
public void setChildren(List<RouterVo> children)
|
||||
{
|
||||
this.children = children;
|
||||
}
|
||||
}
|
@ -0,0 +1,187 @@
|
||||
package com.ruoyi.system.domain_shate;
|
||||
|
||||
|
||||
import java.time.LocalDateTime;
|
||||
|
||||
/**
|
||||
* @Author: JinSheng Song
|
||||
* @Date: 2022/7/7 9:36
|
||||
*/
|
||||
public class Altitude extends SysSTEntity
|
||||
{
|
||||
/**
|
||||
* 指定主键,建立自增序列,主键值取自序列
|
||||
*/
|
||||
|
||||
private Integer id;
|
||||
|
||||
|
||||
private String zone;
|
||||
|
||||
private Double Level1;
|
||||
|
||||
private Double Level2;
|
||||
|
||||
private Double Level3;
|
||||
|
||||
private Double Level4;
|
||||
|
||||
private Double Level5;
|
||||
|
||||
private Double max;
|
||||
|
||||
private String imageDate;
|
||||
|
||||
private String year;
|
||||
|
||||
private String productCode1;
|
||||
|
||||
|
||||
private String productCode2;
|
||||
|
||||
|
||||
private String productCode3;
|
||||
|
||||
|
||||
private String createdBy;
|
||||
|
||||
private LocalDateTime craeteTime;
|
||||
|
||||
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 Double getLevel1() {
|
||||
return Level1;
|
||||
}
|
||||
|
||||
public void setLevel1(Double level1) {
|
||||
Level1 = level1;
|
||||
}
|
||||
|
||||
public Double getLevel2() {
|
||||
return Level2;
|
||||
}
|
||||
|
||||
public void setLevel2(Double level2) {
|
||||
Level2 = level2;
|
||||
}
|
||||
|
||||
public Double getLevel3() {
|
||||
return Level3;
|
||||
}
|
||||
|
||||
public void setLevel3(Double level3) {
|
||||
Level3 = level3;
|
||||
}
|
||||
|
||||
public Double getLevel4() {
|
||||
return Level4;
|
||||
}
|
||||
|
||||
public void setLevel4(Double level4) {
|
||||
Level4 = level4;
|
||||
}
|
||||
|
||||
public Double getLevel5() {
|
||||
return Level5;
|
||||
}
|
||||
|
||||
public void setLevel5(Double level5) {
|
||||
Level5 = level5;
|
||||
}
|
||||
|
||||
public String getImageDate() {
|
||||
return imageDate;
|
||||
}
|
||||
|
||||
public void setImageDate(String imageDate) {
|
||||
this.imageDate = imageDate;
|
||||
}
|
||||
|
||||
public String getProductCode1() {
|
||||
return productCode1;
|
||||
}
|
||||
|
||||
public void setProductCode1(String productCode1) {
|
||||
this.productCode1 = productCode1;
|
||||
}
|
||||
|
||||
public String getProductCode2() {
|
||||
return productCode2;
|
||||
}
|
||||
|
||||
public void setProductCode2(String productCode2) {
|
||||
this.productCode2 = productCode2;
|
||||
}
|
||||
|
||||
public String getProductCode3() {
|
||||
return productCode3;
|
||||
}
|
||||
|
||||
public void setProductCode3(String productCode3) {
|
||||
this.productCode3 = productCode3;
|
||||
}
|
||||
|
||||
public String getCreatedBy() {
|
||||
return createdBy;
|
||||
}
|
||||
|
||||
public void setCreatedBy(String createdBy) {
|
||||
this.createdBy = createdBy;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "Altitude{" +
|
||||
"id=" + id +
|
||||
", zone='" + zone + '\'' +
|
||||
", Level1=" + Level1 +
|
||||
", Level2=" + Level2 +
|
||||
", Level3=" + Level3 +
|
||||
", Level4=" + Level4 +
|
||||
", Level5=" + Level5 +
|
||||
", imageDate=" + imageDate +
|
||||
", productCode1='" + productCode1 + '\'' +
|
||||
", productCode2='" + productCode2 + '\'' +
|
||||
", productCode3='" + productCode3 + '\'' +
|
||||
", createdBy='" + createdBy + '\'' +
|
||||
'}';
|
||||
}
|
||||
|
||||
public LocalDateTime getCraeteTime() {
|
||||
return craeteTime;
|
||||
}
|
||||
|
||||
public void setCraeteTime(LocalDateTime craeteTime) {
|
||||
this.craeteTime = craeteTime;
|
||||
}
|
||||
|
||||
public String getYear() {
|
||||
return year;
|
||||
}
|
||||
|
||||
public void setYear(String year) {
|
||||
this.year = year;
|
||||
}
|
||||
|
||||
public Double getMax() {
|
||||
return max;
|
||||
}
|
||||
|
||||
public void setMax(Double max) {
|
||||
this.max = max;
|
||||
}
|
||||
}
|
@ -0,0 +1,222 @@
|
||||
package com.ruoyi.system.domain_shate;
|
||||
|
||||
import java.time.LocalDateTime;
|
||||
|
||||
/**
|
||||
* @Author: JinSheng Song
|
||||
* @Date: 2022/7/7 9:36
|
||||
*/
|
||||
|
||||
public class Aspect extends SysSTEntity{
|
||||
/**
|
||||
* 指定主键,建立自增序列,主键值取自序列
|
||||
*/
|
||||
|
||||
private Integer id;
|
||||
|
||||
private String zone;
|
||||
|
||||
private String year;
|
||||
|
||||
private Double north;
|
||||
|
||||
private Double northeast;
|
||||
|
||||
private Double east;
|
||||
|
||||
private Double southeast;
|
||||
|
||||
private Double south;
|
||||
|
||||
private Double southwest;
|
||||
|
||||
private Double max;
|
||||
|
||||
private Double west;
|
||||
|
||||
private Double northwest;
|
||||
|
||||
|
||||
private String imageDate;
|
||||
|
||||
|
||||
|
||||
private String productCode1;
|
||||
|
||||
|
||||
private String productCode2;
|
||||
|
||||
|
||||
private String productCode3;
|
||||
|
||||
|
||||
private String createdBy;
|
||||
|
||||
private LocalDateTime craeteTime;
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "Aspect{" +
|
||||
"id=" + id +
|
||||
", zone='" + zone + '\'' +
|
||||
", north=" + north +
|
||||
", northeast=" + northeast +
|
||||
", east=" + east +
|
||||
", southeast=" + southeast +
|
||||
", south=" + south +
|
||||
", southwest=" + southwest +
|
||||
", west=" + west +
|
||||
", northwest=" + northwest +
|
||||
", imageDate=" + imageDate +
|
||||
", productCode1='" + productCode1 + '\'' +
|
||||
", productCode2='" + productCode2 + '\'' +
|
||||
", productCode3='" + productCode3 + '\'' +
|
||||
", createdBy='" + createdBy + '\'' +
|
||||
", craeteTime=" + craeteTime +
|
||||
'}';
|
||||
}
|
||||
|
||||
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 Double getNorth() {
|
||||
return north;
|
||||
}
|
||||
|
||||
public void setNorth(Double north) {
|
||||
this.north = north;
|
||||
}
|
||||
|
||||
public Double getNortheast() {
|
||||
return northeast;
|
||||
}
|
||||
|
||||
public void setNortheast(Double northeast) {
|
||||
this.northeast = northeast;
|
||||
}
|
||||
|
||||
public Double getEast() {
|
||||
return east;
|
||||
}
|
||||
|
||||
public void setEast(Double east) {
|
||||
this.east = east;
|
||||
}
|
||||
|
||||
public Double getSoutheast() {
|
||||
return southeast;
|
||||
}
|
||||
|
||||
public void setSoutheast(Double southeast) {
|
||||
this.southeast = southeast;
|
||||
}
|
||||
|
||||
public Double getSouth() {
|
||||
return south;
|
||||
}
|
||||
|
||||
public void setSouth(Double south) {
|
||||
this.south = south;
|
||||
}
|
||||
|
||||
public Double getSouthwest() {
|
||||
return southwest;
|
||||
}
|
||||
|
||||
public void setSouthwest(Double southwest) {
|
||||
this.southwest = southwest;
|
||||
}
|
||||
|
||||
public Double getWest() {
|
||||
return west;
|
||||
}
|
||||
|
||||
public void setWest(Double west) {
|
||||
this.west = west;
|
||||
}
|
||||
|
||||
public Double getNorthwest() {
|
||||
return northwest;
|
||||
}
|
||||
|
||||
public void setNorthwest(Double northwest) {
|
||||
this.northwest = northwest;
|
||||
}
|
||||
|
||||
public String getImageDate() {
|
||||
return imageDate;
|
||||
}
|
||||
|
||||
public void setImageDate(String imageDate) {
|
||||
this.imageDate = imageDate;
|
||||
}
|
||||
|
||||
public String getProductCode1() {
|
||||
return productCode1;
|
||||
}
|
||||
|
||||
public void setProductCode1(String productCode1) {
|
||||
this.productCode1 = productCode1;
|
||||
}
|
||||
|
||||
public String getProductCode2() {
|
||||
return productCode2;
|
||||
}
|
||||
|
||||
public void setProductCode2(String productCode2) {
|
||||
this.productCode2 = productCode2;
|
||||
}
|
||||
|
||||
public String getProductCode3() {
|
||||
return productCode3;
|
||||
}
|
||||
|
||||
public void setProductCode3(String productCode3) {
|
||||
this.productCode3 = productCode3;
|
||||
}
|
||||
|
||||
public String getCreatedBy() {
|
||||
return createdBy;
|
||||
}
|
||||
|
||||
public void setCreatedBy(String createdBy) {
|
||||
this.createdBy = createdBy;
|
||||
}
|
||||
|
||||
public LocalDateTime getCraeteTime() {
|
||||
return craeteTime;
|
||||
}
|
||||
|
||||
public void setCraeteTime(LocalDateTime craeteTime) {
|
||||
this.craeteTime = craeteTime;
|
||||
}
|
||||
|
||||
public String getYear() {
|
||||
return year;
|
||||
}
|
||||
|
||||
public void setYear(String year) {
|
||||
this.year = year;
|
||||
}
|
||||
|
||||
public Double getMax() {
|
||||
return max;
|
||||
}
|
||||
|
||||
public void setMax(Double max) {
|
||||
this.max = max;
|
||||
}
|
||||
}
|
@ -0,0 +1,78 @@
|
||||
package com.ruoyi.system.domain_shate;
|
||||
|
||||
/**
|
||||
* @Author: JinSheng Song
|
||||
* @Date: 2022/5/19 14:50
|
||||
*/
|
||||
public class AustraliaMiddleEastVO extends SysBaseEntity
|
||||
{
|
||||
private String id;
|
||||
|
||||
private String yearMonth;
|
||||
|
||||
private String month;
|
||||
|
||||
private Double sstAnomalyIndex;
|
||||
|
||||
private Double temperatureAnomolies;
|
||||
|
||||
private Double precipitationAnomolies;
|
||||
|
||||
private Double vaiAnomolies;
|
||||
|
||||
public String getId() {
|
||||
return id;
|
||||
}
|
||||
|
||||
public void setId(String id) {
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
public String getYearMonth() {
|
||||
return yearMonth;
|
||||
}
|
||||
|
||||
public void setYearMonth(String yearMonth) {
|
||||
this.yearMonth = yearMonth;
|
||||
}
|
||||
|
||||
public Double getSstAnomalyIndex() {
|
||||
return sstAnomalyIndex;
|
||||
}
|
||||
|
||||
public void setSstAnomalyIndex(Double sstAnomalyIndex) {
|
||||
this.sstAnomalyIndex = sstAnomalyIndex;
|
||||
}
|
||||
|
||||
public Double getTemperatureAnomolies() {
|
||||
return temperatureAnomolies;
|
||||
}
|
||||
|
||||
public void setTemperatureAnomolies(Double temperatureAnomolies) {
|
||||
this.temperatureAnomolies = temperatureAnomolies;
|
||||
}
|
||||
|
||||
public Double getPrecipitationAnomolies() {
|
||||
return precipitationAnomolies;
|
||||
}
|
||||
|
||||
public void setPrecipitationAnomolies(Double precipitationAnomolies) {
|
||||
this.precipitationAnomolies = precipitationAnomolies;
|
||||
}
|
||||
|
||||
public Double getVaiAnomolies() {
|
||||
return vaiAnomolies;
|
||||
}
|
||||
|
||||
public void setVaiAnomolies(Double vaiAnomolies) {
|
||||
this.vaiAnomolies = vaiAnomolies;
|
||||
}
|
||||
|
||||
public String getMonth() {
|
||||
return month;
|
||||
}
|
||||
|
||||
public void setMonth(String month) {
|
||||
this.month = month;
|
||||
}
|
||||
}
|
@ -0,0 +1,58 @@
|
||||
package com.ruoyi.system.domain_shate;
|
||||
|
||||
/**
|
||||
* @Author: JinSheng Song
|
||||
* @Date: 2022/7/18 21:09
|
||||
*/
|
||||
public class Climate {
|
||||
|
||||
private String zone;
|
||||
|
||||
private String temperature;
|
||||
|
||||
private String precipitation;
|
||||
|
||||
private String humidity;
|
||||
|
||||
private String wind;
|
||||
|
||||
public String getZone() {
|
||||
return zone;
|
||||
}
|
||||
|
||||
public void setZone(String zone) {
|
||||
this.zone = zone;
|
||||
}
|
||||
|
||||
public String getTemperature() {
|
||||
return temperature;
|
||||
}
|
||||
|
||||
public void setTemperature(String temperature) {
|
||||
this.temperature = temperature;
|
||||
}
|
||||
|
||||
public String getPrecipitation() {
|
||||
return precipitation;
|
||||
}
|
||||
|
||||
public void setPrecipitation(String precipitation) {
|
||||
this.precipitation = precipitation;
|
||||
}
|
||||
|
||||
public String getHumidity() {
|
||||
return humidity;
|
||||
}
|
||||
|
||||
public void setHumidity(String humidity) {
|
||||
this.humidity = humidity;
|
||||
}
|
||||
|
||||
public String getWind() {
|
||||
return wind;
|
||||
}
|
||||
|
||||
public void setWind(String wind) {
|
||||
this.wind = wind;
|
||||
}
|
||||
}
|
@ -0,0 +1,285 @@
|
||||
package com.ruoyi.system.domain_shate;
|
||||
|
||||
import org.springframework.web.multipart.MultipartFile;
|
||||
|
||||
import java.time.LocalDate;
|
||||
import java.time.LocalDateTime;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @Author: JinSheng Song
|
||||
* @Date: 2022/7/11 15:32
|
||||
*/
|
||||
public class DateUpload
|
||||
{
|
||||
private String id;
|
||||
|
||||
private String zone;
|
||||
|
||||
private String link;
|
||||
|
||||
private String fileName;
|
||||
|
||||
private String dataTime;
|
||||
|
||||
private String type;
|
||||
|
||||
private String type1;
|
||||
|
||||
private String type2;
|
||||
|
||||
private String data_id;
|
||||
|
||||
private String area;
|
||||
|
||||
private String band_index;
|
||||
|
||||
private String bands;
|
||||
|
||||
private String cols;
|
||||
|
||||
private String depth;
|
||||
|
||||
private String description;
|
||||
|
||||
private List<Float> extent;
|
||||
|
||||
private MultipartFile multipartFile;
|
||||
|
||||
private String extent1;
|
||||
|
||||
private String name;
|
||||
|
||||
private String projection;
|
||||
|
||||
private String resolution;
|
||||
|
||||
private Double size;
|
||||
|
||||
private String tifLink;
|
||||
|
||||
private String route;
|
||||
|
||||
private Integer month;
|
||||
|
||||
private String year;
|
||||
|
||||
public String getArea() {
|
||||
return area;
|
||||
}
|
||||
|
||||
public void setArea(String area) {
|
||||
this.area = area;
|
||||
}
|
||||
|
||||
|
||||
public String getBands() {
|
||||
return bands;
|
||||
}
|
||||
|
||||
public void setBands(String bands) {
|
||||
this.bands = bands;
|
||||
}
|
||||
|
||||
public String getCols() {
|
||||
return cols;
|
||||
}
|
||||
|
||||
public void setCols(String cols) {
|
||||
this.cols = cols;
|
||||
}
|
||||
|
||||
public String getDepth() {
|
||||
return depth;
|
||||
}
|
||||
|
||||
public void setDepth(String depth) {
|
||||
this.depth = depth;
|
||||
}
|
||||
|
||||
public String getDescription() {
|
||||
return description;
|
||||
}
|
||||
|
||||
public void setDescription(String description) {
|
||||
this.description = description;
|
||||
}
|
||||
|
||||
public List<Float> getExtent() {
|
||||
return extent;
|
||||
}
|
||||
|
||||
public void setExtent(List<Float> extent) {
|
||||
this.extent = extent;
|
||||
}
|
||||
|
||||
public String getName() {
|
||||
return name;
|
||||
}
|
||||
|
||||
public void setName(String name) {
|
||||
this.name = name;
|
||||
}
|
||||
|
||||
public String getProjection() {
|
||||
return projection;
|
||||
}
|
||||
|
||||
public void setProjection(String projection) {
|
||||
this.projection = projection;
|
||||
}
|
||||
|
||||
public String getResolution() {
|
||||
return resolution;
|
||||
}
|
||||
|
||||
public void setResolution(String resolution) {
|
||||
this.resolution = resolution;
|
||||
}
|
||||
|
||||
public Double getSize() {
|
||||
return size;
|
||||
}
|
||||
|
||||
public void setSize(Double size) {
|
||||
this.size = size;
|
||||
}
|
||||
|
||||
private String createdTime;
|
||||
|
||||
public String getId() {
|
||||
return id;
|
||||
}
|
||||
|
||||
public void setId(String id) {
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
public String getZone() {
|
||||
return zone;
|
||||
}
|
||||
|
||||
public void setZone(String zone) {
|
||||
this.zone = zone;
|
||||
}
|
||||
|
||||
public String getLink() {
|
||||
return link;
|
||||
}
|
||||
|
||||
public void setLink(String link) {
|
||||
this.link = link;
|
||||
}
|
||||
|
||||
public String getFileName() {
|
||||
return fileName;
|
||||
}
|
||||
|
||||
public void setFileName(String fileName) {
|
||||
this.fileName = fileName;
|
||||
}
|
||||
|
||||
public String getDataTime() {
|
||||
return dataTime;
|
||||
}
|
||||
|
||||
public void setDataTime(String dataTime) {
|
||||
this.dataTime = dataTime;
|
||||
}
|
||||
|
||||
public String getCreatedTime() {
|
||||
return createdTime;
|
||||
}
|
||||
|
||||
public void setCreatedTime(String createdTime) {
|
||||
this.createdTime = createdTime;
|
||||
}
|
||||
|
||||
public String getType() {
|
||||
return type;
|
||||
}
|
||||
|
||||
public void setType(String type) {
|
||||
this.type = type;
|
||||
}
|
||||
|
||||
public String getType1() {
|
||||
return type1;
|
||||
}
|
||||
|
||||
public void setType1(String type1) {
|
||||
this.type1 = type1;
|
||||
}
|
||||
|
||||
public String getType2() {
|
||||
return type2;
|
||||
}
|
||||
|
||||
public void setType2(String type2) {
|
||||
this.type2 = type2;
|
||||
}
|
||||
|
||||
public String getData_id() {
|
||||
return data_id;
|
||||
}
|
||||
|
||||
public void setData_id(String data_id) {
|
||||
this.data_id = data_id;
|
||||
}
|
||||
|
||||
public String getBand_index() {
|
||||
return band_index;
|
||||
}
|
||||
|
||||
public void setBand_index(String band_index) {
|
||||
this.band_index = band_index;
|
||||
}
|
||||
|
||||
public String getExtent1() {
|
||||
return extent1;
|
||||
}
|
||||
|
||||
public void setExtent1(String extent1) {
|
||||
this.extent1 = extent1;
|
||||
}
|
||||
|
||||
public String getTifLink() {
|
||||
return tifLink;
|
||||
}
|
||||
|
||||
public void setTifLink(String tifLink) {
|
||||
this.tifLink = tifLink;
|
||||
}
|
||||
|
||||
public MultipartFile getMultipartFile() {
|
||||
return multipartFile;
|
||||
}
|
||||
|
||||
public void setMultipartFile(MultipartFile multipartFile) {
|
||||
this.multipartFile = multipartFile;
|
||||
}
|
||||
|
||||
public String getRoute() {
|
||||
return route;
|
||||
}
|
||||
|
||||
public void setRoute(String route) {
|
||||
this.route = route;
|
||||
}
|
||||
|
||||
public Integer getMonth() {
|
||||
return month;
|
||||
}
|
||||
|
||||
public void setMonth(Integer month) {
|
||||
this.month = month;
|
||||
}
|
||||
|
||||
public String getYear() {
|
||||
return year;
|
||||
}
|
||||
|
||||
public void setYear(String year) {
|
||||
this.year = year;
|
||||
}
|
||||
}
|
@ -0,0 +1,37 @@
|
||||
package com.ruoyi.system.domain_shate;
|
||||
|
||||
/**
|
||||
* @Author: JinSheng Song
|
||||
* @Date: 2022/7/22 16:50
|
||||
*/
|
||||
public class HelpLandUse {
|
||||
private String year;
|
||||
|
||||
private String zone;
|
||||
|
||||
private String[] landUses;
|
||||
|
||||
public String getYear() {
|
||||
return year;
|
||||
}
|
||||
|
||||
public void setYear(String year) {
|
||||
this.year = year;
|
||||
}
|
||||
|
||||
public String getZone() {
|
||||
return zone;
|
||||
}
|
||||
|
||||
public void setZone(String zone) {
|
||||
this.zone = zone;
|
||||
}
|
||||
|
||||
public String[] getLandUses() {
|
||||
return landUses;
|
||||
}
|
||||
|
||||
public void setLandUses(String[] landUses) {
|
||||
this.landUses = landUses;
|
||||
}
|
||||
}
|
@ -0,0 +1,168 @@
|
||||
package com.ruoyi.system.domain_shate;
|
||||
|
||||
|
||||
import java.time.LocalDateTime;
|
||||
|
||||
/**
|
||||
* @Author: JinSheng Song
|
||||
* @Date: 2022/7/7 9:36
|
||||
*/
|
||||
|
||||
public class LandUse extends SysSTEntity
|
||||
{
|
||||
/**
|
||||
* 指定主键,建立自增序列,主键值取自序列
|
||||
*/
|
||||
|
||||
private Integer id;
|
||||
|
||||
|
||||
private String zone;
|
||||
|
||||
private String landUse;
|
||||
|
||||
private Double area;
|
||||
|
||||
private Double percent;
|
||||
|
||||
private Double total;
|
||||
|
||||
private String imageDate;
|
||||
|
||||
|
||||
|
||||
private String productCode1;
|
||||
|
||||
|
||||
private String productCode2;
|
||||
|
||||
private String productCode3;
|
||||
|
||||
private String year;
|
||||
|
||||
|
||||
private String createdBy;
|
||||
|
||||
private LocalDateTime createdTime;
|
||||
|
||||
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 getLandUse() {
|
||||
return landUse;
|
||||
}
|
||||
|
||||
public void setLandUse(String landUse) {
|
||||
this.landUse = landUse;
|
||||
}
|
||||
|
||||
public Double getArea() {
|
||||
return area;
|
||||
}
|
||||
|
||||
public void setArea(Double area) {
|
||||
this.area = area;
|
||||
}
|
||||
|
||||
public Double getPercent() {
|
||||
return percent;
|
||||
}
|
||||
|
||||
public void setPercent(Double percent) {
|
||||
this.percent = percent;
|
||||
}
|
||||
|
||||
public String getImageDate() {
|
||||
return imageDate;
|
||||
}
|
||||
|
||||
public void setImageDate(String imageDate) {
|
||||
this.imageDate = imageDate;
|
||||
}
|
||||
|
||||
public String getProductCode1() {
|
||||
return productCode1;
|
||||
}
|
||||
|
||||
public void setProductCode1(String productCode1) {
|
||||
this.productCode1 = productCode1;
|
||||
}
|
||||
|
||||
public String getProductCode2() {
|
||||
return productCode2;
|
||||
}
|
||||
|
||||
public void setProductCode2(String productCode2) {
|
||||
this.productCode2 = productCode2;
|
||||
}
|
||||
|
||||
public String getProductCode3() {
|
||||
return productCode3;
|
||||
}
|
||||
|
||||
public void setProductCode3(String productCode3) {
|
||||
this.productCode3 = productCode3;
|
||||
}
|
||||
|
||||
public String getCreatedBy() {
|
||||
return createdBy;
|
||||
}
|
||||
|
||||
public void setCreatedBy(String createdBy) {
|
||||
this.createdBy = createdBy;
|
||||
}
|
||||
|
||||
public LocalDateTime getCraetedTime() {
|
||||
return createdTime;
|
||||
}
|
||||
|
||||
public void setCraetedTime(LocalDateTime craeteTime) {
|
||||
this.createdTime = craeteTime;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "LandUse{" +
|
||||
"id=" + id +
|
||||
", zone='" + zone + '\'' +
|
||||
", landUse='" + landUse + '\'' +
|
||||
", area=" + area +
|
||||
", percent=" + percent +
|
||||
", imageDate=" + imageDate +
|
||||
", productCode1='" + productCode1 + '\'' +
|
||||
", productCode2='" + productCode2 + '\'' +
|
||||
", productCode3='" + productCode3 + '\'' +
|
||||
", createdBy='" + createdBy + '\'' +
|
||||
", craetedTime=" + createdTime +
|
||||
'}';
|
||||
}
|
||||
|
||||
public Double getTotal() {
|
||||
return total;
|
||||
}
|
||||
|
||||
public void setTotal(Double total) {
|
||||
this.total = total;
|
||||
}
|
||||
|
||||
public String getYear() {
|
||||
return year;
|
||||
}
|
||||
|
||||
public void setYear(String year) {
|
||||
this.year = year;
|
||||
}
|
||||
}
|
@ -0,0 +1,189 @@
|
||||
package com.ruoyi.system.domain_shate;
|
||||
|
||||
|
||||
import java.time.LocalDateTime;
|
||||
|
||||
/**
|
||||
* @Author: JinSheng Song
|
||||
* @Date: 2022/7/7 9:36
|
||||
*/
|
||||
|
||||
public class PlantingSuitability extends SysSTEntity
|
||||
{
|
||||
/**
|
||||
* 指定主键,建立自增序列,主键值取自序列
|
||||
*/
|
||||
private Integer id;
|
||||
|
||||
|
||||
private String zone;
|
||||
|
||||
private Double max;
|
||||
|
||||
private Double verySuitable;
|
||||
|
||||
private Double suitable;
|
||||
|
||||
private Double notSuitable;
|
||||
|
||||
private Double totalArea;
|
||||
|
||||
private String imageDate;
|
||||
|
||||
private String total;
|
||||
|
||||
|
||||
private String productCode1;
|
||||
|
||||
|
||||
private String productCode2;
|
||||
|
||||
|
||||
private String productCode3;
|
||||
|
||||
|
||||
private String createdBy;
|
||||
|
||||
private String year;
|
||||
|
||||
private LocalDateTime createdTime;
|
||||
|
||||
|
||||
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 Double getVerySuitable() {
|
||||
return verySuitable;
|
||||
}
|
||||
|
||||
public void setVerySuitable(Double verySuitable) {
|
||||
this.verySuitable = verySuitable;
|
||||
}
|
||||
|
||||
public Double getSuitable() {
|
||||
return suitable;
|
||||
}
|
||||
|
||||
public void setSuitable(Double suitable) {
|
||||
this.suitable = suitable;
|
||||
}
|
||||
|
||||
public Double getNotSuitable() {
|
||||
return notSuitable;
|
||||
}
|
||||
|
||||
public void setNotSuitable(Double notSuitable) {
|
||||
this.notSuitable = notSuitable;
|
||||
}
|
||||
|
||||
public Double getTotalArea() {
|
||||
return totalArea;
|
||||
}
|
||||
|
||||
public void setTotalArea(Double totalArea) {
|
||||
this.totalArea = totalArea;
|
||||
}
|
||||
|
||||
public String getImageDate() {
|
||||
return imageDate;
|
||||
}
|
||||
|
||||
public void setImageDate(String imageDate) {
|
||||
this.imageDate = imageDate;
|
||||
}
|
||||
|
||||
public String getProductCode1() {
|
||||
return productCode1;
|
||||
}
|
||||
|
||||
public void setProductCode1(String productCode1) {
|
||||
this.productCode1 = productCode1;
|
||||
}
|
||||
|
||||
public String getProductCode2() {
|
||||
return productCode2;
|
||||
}
|
||||
|
||||
public void setProductCode2(String productCode2) {
|
||||
this.productCode2 = productCode2;
|
||||
}
|
||||
|
||||
public String getProductCode3() {
|
||||
return productCode3;
|
||||
}
|
||||
|
||||
public void setProductCode3(String productCode3) {
|
||||
this.productCode3 = productCode3;
|
||||
}
|
||||
|
||||
public String getCreatedBy() {
|
||||
return createdBy;
|
||||
}
|
||||
|
||||
public void setCreatedBy(String createdBy) {
|
||||
this.createdBy = createdBy;
|
||||
}
|
||||
|
||||
public LocalDateTime getCreatedTime() {
|
||||
return createdTime;
|
||||
}
|
||||
|
||||
public void setCreatedTime(LocalDateTime createdTime) {
|
||||
this.createdTime = createdTime;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "PlantingSuitability{" +
|
||||
"id=" + id +
|
||||
", zone='" + zone + '\'' +
|
||||
", verySuitable=" + verySuitable +
|
||||
", suitable=" + suitable +
|
||||
", notSuitable=" + notSuitable +
|
||||
", totalArea=" + totalArea +
|
||||
", imageDate=" + imageDate +
|
||||
", productCode1='" + productCode1 + '\'' +
|
||||
", productCode2='" + productCode2 + '\'' +
|
||||
", productCode3='" + productCode3 + '\'' +
|
||||
", createdBy='" + createdBy + '\'' +
|
||||
", createdTime=" + createdTime +
|
||||
'}';
|
||||
}
|
||||
|
||||
public String getTotal() {
|
||||
return total;
|
||||
}
|
||||
|
||||
public void setTotal(String total) {
|
||||
this.total = total;
|
||||
}
|
||||
|
||||
public String getYear() {
|
||||
return year;
|
||||
}
|
||||
|
||||
public void setYear(String year) {
|
||||
this.year = year;
|
||||
}
|
||||
|
||||
public Double getMax() {
|
||||
return max;
|
||||
}
|
||||
|
||||
public void setMax(Double max) {
|
||||
this.max = max;
|
||||
}
|
||||
}
|
@ -0,0 +1,115 @@
|
||||
package com.ruoyi.system.domain_shate;
|
||||
|
||||
|
||||
import java.time.LocalDateTime;
|
||||
|
||||
/**
|
||||
* @Author: JinSheng Song
|
||||
* @Date: 2022/7/7 9:36
|
||||
*/
|
||||
|
||||
public class RegionIndex extends SysSTEntity{
|
||||
/**
|
||||
* 指定主键,建立自增序列,主键值取自序列
|
||||
*/
|
||||
private Integer id;
|
||||
|
||||
|
||||
private String zone;
|
||||
|
||||
private String year;
|
||||
|
||||
private Double waterArea;
|
||||
|
||||
private Double roadLength;
|
||||
|
||||
private String imageDate;
|
||||
|
||||
private String productCode;
|
||||
private String productCode1;
|
||||
|
||||
|
||||
private String createdBy;
|
||||
|
||||
private LocalDateTime craeteTime;
|
||||
|
||||
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 Double getWaterArea() {
|
||||
return waterArea;
|
||||
}
|
||||
|
||||
public void setWaterArea(Double waterArea) {
|
||||
this.waterArea = waterArea;
|
||||
}
|
||||
|
||||
public Double getRoadLength() {
|
||||
return roadLength;
|
||||
}
|
||||
|
||||
public void setRoadLength(Double roadLength) {
|
||||
this.roadLength = roadLength;
|
||||
}
|
||||
|
||||
public String getImageDate() {
|
||||
return imageDate;
|
||||
}
|
||||
|
||||
public void setImageDate(String imageDate) {
|
||||
this.imageDate = imageDate;
|
||||
}
|
||||
|
||||
public String getProductCode() {
|
||||
return productCode;
|
||||
}
|
||||
|
||||
public void setProductCode(String productCode) {
|
||||
this.productCode = productCode;
|
||||
}
|
||||
|
||||
public String getCreatedBy() {
|
||||
return createdBy;
|
||||
}
|
||||
|
||||
public void setCreatedBy(String createdBy) {
|
||||
this.createdBy = createdBy;
|
||||
}
|
||||
|
||||
public LocalDateTime getCraeteTime() {
|
||||
return craeteTime;
|
||||
}
|
||||
|
||||
public void setCraeteTime(LocalDateTime craeteTime) {
|
||||
this.craeteTime = craeteTime;
|
||||
}
|
||||
|
||||
public String getYear() {
|
||||
return year;
|
||||
}
|
||||
|
||||
public void setYear(String year) {
|
||||
this.year = year;
|
||||
}
|
||||
|
||||
public String getProductCode1() {
|
||||
return productCode1;
|
||||
}
|
||||
|
||||
public void setProductCode1(String productCode1) {
|
||||
this.productCode1 = productCode1;
|
||||
}
|
||||
}
|
@ -0,0 +1,180 @@
|
||||
package com.ruoyi.system.domain_shate;
|
||||
|
||||
|
||||
import java.time.LocalDateTime;
|
||||
|
||||
/**
|
||||
* @Author: JinSheng Song
|
||||
* @Date: 2022/7/7 9:36
|
||||
*/
|
||||
|
||||
public class RoadFactor extends SysSTEntity
|
||||
{
|
||||
/**
|
||||
* 指定主键,建立自增序列,主键值取自序列
|
||||
*/
|
||||
private Integer id;
|
||||
|
||||
private String year;
|
||||
|
||||
private String zone;
|
||||
|
||||
private Double max;
|
||||
|
||||
private Double Level1;
|
||||
|
||||
private Double Level2;
|
||||
|
||||
private Double Level3;
|
||||
|
||||
private Double Level4;
|
||||
|
||||
private Double Level5;
|
||||
|
||||
|
||||
private String imageDate;
|
||||
|
||||
|
||||
|
||||
private String productCode1;
|
||||
|
||||
|
||||
private String productCode2;
|
||||
|
||||
|
||||
|
||||
private String createdBy;
|
||||
|
||||
private LocalDateTime craeteTime;
|
||||
|
||||
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 Double getLevel1() {
|
||||
return Level1;
|
||||
}
|
||||
|
||||
public void setLevel1(Double level1) {
|
||||
Level1 = level1;
|
||||
}
|
||||
|
||||
public Double getLevel2() {
|
||||
return Level2;
|
||||
}
|
||||
|
||||
public void setLevel2(Double level2) {
|
||||
Level2 = level2;
|
||||
}
|
||||
|
||||
public Double getLevel3() {
|
||||
return Level3;
|
||||
}
|
||||
|
||||
public void setLevel3(Double level3) {
|
||||
Level3 = level3;
|
||||
}
|
||||
|
||||
public Double getLevel4() {
|
||||
return Level4;
|
||||
}
|
||||
|
||||
public void setLevel4(Double level4) {
|
||||
Level4 = level4;
|
||||
}
|
||||
|
||||
public Double getLevel5() {
|
||||
return Level5;
|
||||
}
|
||||
|
||||
public void setLevel5(Double level5) {
|
||||
Level5 = level5;
|
||||
}
|
||||
|
||||
public String getImageDate() {
|
||||
return imageDate;
|
||||
}
|
||||
|
||||
public void setImageDate(String imageDate) {
|
||||
this.imageDate = imageDate;
|
||||
}
|
||||
|
||||
public String getProductCode1() {
|
||||
return productCode1;
|
||||
}
|
||||
|
||||
public void setProductCode1(String productCode1) {
|
||||
this.productCode1 = productCode1;
|
||||
}
|
||||
|
||||
public String getProductCode2() {
|
||||
return productCode2;
|
||||
}
|
||||
|
||||
public void setProductCode2(String productCode2) {
|
||||
this.productCode2 = productCode2;
|
||||
}
|
||||
|
||||
|
||||
|
||||
public String getCreatedBy() {
|
||||
return createdBy;
|
||||
}
|
||||
|
||||
public void setCreatedBy(String createdBy) {
|
||||
this.createdBy = createdBy;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "Altitude{" +
|
||||
"id=" + id +
|
||||
", zone='" + zone + '\'' +
|
||||
", Level1=" + Level1 +
|
||||
", Level2=" + Level2 +
|
||||
", Level3=" + Level3 +
|
||||
", Level4=" + Level4 +
|
||||
", Level5=" + Level5 +
|
||||
", imageDate=" + imageDate +
|
||||
", productCode1='" + productCode1 + '\'' +
|
||||
", productCode2='" + productCode2 + '\'' +
|
||||
", createdBy='" + createdBy + '\'' +
|
||||
'}';
|
||||
}
|
||||
|
||||
public LocalDateTime getCraeteTime() {
|
||||
return craeteTime;
|
||||
}
|
||||
|
||||
public void setCraeteTime(LocalDateTime craeteTime) {
|
||||
this.craeteTime = craeteTime;
|
||||
}
|
||||
|
||||
public String getYear() {
|
||||
return year;
|
||||
}
|
||||
|
||||
public void setYear(String year) {
|
||||
this.year = year;
|
||||
}
|
||||
|
||||
public Double getMax() {
|
||||
return max;
|
||||
}
|
||||
|
||||
public void setMax(Double max) {
|
||||
this.max = max;
|
||||
}
|
||||
}
|
@ -0,0 +1,161 @@
|
||||
package com.ruoyi.system.domain_shate;
|
||||
|
||||
|
||||
import java.time.LocalDate;
|
||||
import java.time.LocalDateTime;
|
||||
|
||||
/**
|
||||
* @Author: JinSheng Song
|
||||
* @Date: 2022/7/7 9:36
|
||||
*/
|
||||
|
||||
public class SeedingSuccessRate extends SysSTEntity
|
||||
{
|
||||
/**
|
||||
* 指定主键,建立自增序列,主键值取自序列
|
||||
*/
|
||||
private Integer id;
|
||||
|
||||
|
||||
private String zone;
|
||||
|
||||
|
||||
private Double plantingArea;
|
||||
|
||||
private Double seedingSuccessArea;
|
||||
|
||||
private Double seedingSuccess;
|
||||
|
||||
private String imageDate;
|
||||
|
||||
|
||||
private String productCode1;
|
||||
|
||||
|
||||
private String productCode2;
|
||||
|
||||
|
||||
private String productCode3;
|
||||
|
||||
|
||||
private String createdBy;
|
||||
|
||||
private LocalDateTime createdTime;
|
||||
|
||||
private String year;
|
||||
|
||||
public SeedingSuccessRate() {
|
||||
|
||||
}
|
||||
|
||||
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 Double getPlantingArea() {
|
||||
return plantingArea;
|
||||
}
|
||||
|
||||
public void setPlantingArea(Double plantingArea) {
|
||||
this.plantingArea = plantingArea;
|
||||
}
|
||||
|
||||
public Double getSeedingSuccessArea() {
|
||||
return seedingSuccessArea;
|
||||
}
|
||||
|
||||
public void setSeedingSuccessArea(Double seedingSuccessArea) {
|
||||
this.seedingSuccessArea = seedingSuccessArea;
|
||||
}
|
||||
|
||||
|
||||
|
||||
public String getImageDate() {
|
||||
return imageDate;
|
||||
}
|
||||
|
||||
public void setImageDate(String imageDate) {
|
||||
this.imageDate = imageDate;
|
||||
}
|
||||
|
||||
public String getProductCode1() {
|
||||
return productCode1;
|
||||
}
|
||||
|
||||
public void setProductCode1(String productCode1) {
|
||||
this.productCode1 = productCode1;
|
||||
}
|
||||
|
||||
public String getProductCode2() {
|
||||
return productCode2;
|
||||
}
|
||||
|
||||
public void setProductCode2(String productCode2) {
|
||||
this.productCode2 = productCode2;
|
||||
}
|
||||
|
||||
public String getProductCode3() {
|
||||
return productCode3;
|
||||
}
|
||||
|
||||
public void setProductCode3(String productCode3) {
|
||||
this.productCode3 = productCode3;
|
||||
}
|
||||
|
||||
public String getCreatedBy() {
|
||||
return createdBy;
|
||||
}
|
||||
|
||||
public void setCreatedBy(String createdBy) {
|
||||
this.createdBy = createdBy;
|
||||
}
|
||||
|
||||
public LocalDateTime getCreatedTime() {
|
||||
return createdTime;
|
||||
}
|
||||
|
||||
public void setCreatedTime(LocalDateTime createdTime) {
|
||||
this.createdTime = createdTime;
|
||||
}
|
||||
|
||||
public SeedingSuccessRate(Integer id, String zone, Double plantingArea, Double seedingSuccessArea, String imageDate, String productCode1, String productCode2, String productCode3, String createdBy, LocalDateTime createdTime) {
|
||||
this.id = id;
|
||||
this.zone = zone;
|
||||
this.plantingArea = plantingArea;
|
||||
this.seedingSuccessArea = seedingSuccessArea;
|
||||
this.imageDate = imageDate;
|
||||
this.productCode1 = productCode1;
|
||||
this.productCode2 = productCode2;
|
||||
this.productCode3 = productCode3;
|
||||
this.createdBy = createdBy;
|
||||
this.createdTime = createdTime;
|
||||
}
|
||||
|
||||
public String getYear() {
|
||||
return year;
|
||||
}
|
||||
|
||||
public void setYear(String year) {
|
||||
this.year = year;
|
||||
}
|
||||
|
||||
public Double getSeedingSuccess() {
|
||||
return seedingSuccess;
|
||||
}
|
||||
|
||||
public void setSeedingSuccess(Double seedingSuccess) {
|
||||
this.seedingSuccess = seedingSuccess;
|
||||
}
|
||||
}
|
@ -0,0 +1,178 @@
|
||||
package com.ruoyi.system.domain_shate;
|
||||
|
||||
|
||||
import java.time.LocalDateTime;
|
||||
|
||||
/**
|
||||
* @Author: JinSheng Song
|
||||
* @Date: 2022/7/7 9:36
|
||||
*/
|
||||
|
||||
public class Slope extends SysSTEntity
|
||||
{
|
||||
/**
|
||||
* 指定主键,建立自增序列,主键值取自序列
|
||||
*/
|
||||
|
||||
private Integer id;
|
||||
|
||||
private String year;
|
||||
|
||||
private String zone;
|
||||
|
||||
private Double Level1;
|
||||
|
||||
private Double Level2;
|
||||
|
||||
private Double Level3;
|
||||
private Double Level4;
|
||||
|
||||
private Double Level5;
|
||||
|
||||
|
||||
private String imageDate;
|
||||
|
||||
|
||||
|
||||
private String productCode1;
|
||||
|
||||
|
||||
private String productCode2;
|
||||
|
||||
|
||||
private String productCode3;
|
||||
|
||||
|
||||
private String createdBy;
|
||||
|
||||
private LocalDateTime createdTime;
|
||||
@Override
|
||||
public String toString() {
|
||||
return "Slope{" +
|
||||
"id=" + id +
|
||||
", zone='" + zone + '\'' +
|
||||
", Level1=" + Level1 +
|
||||
", Level2=" + Level2 +
|
||||
", Level3=" + Level3 +
|
||||
", Level4=" + Level4 +
|
||||
", Level5=" + Level5 +
|
||||
", imageDate=" + imageDate +
|
||||
", productCode1='" + productCode1 + '\'' +
|
||||
", productCode2='" + productCode2 + '\'' +
|
||||
", productCode3='" + productCode3 + '\'' +
|
||||
", createdBy='" + createdBy + '\'' +
|
||||
'}';
|
||||
}
|
||||
|
||||
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 Double getLevel1() {
|
||||
return Level1;
|
||||
}
|
||||
|
||||
public void setLevel1(Double level1) {
|
||||
Level1 = level1;
|
||||
}
|
||||
|
||||
public Double getLevel2() {
|
||||
return Level2;
|
||||
}
|
||||
|
||||
public void setLevel2(Double level2) {
|
||||
Level2 = level2;
|
||||
}
|
||||
|
||||
public Double getLevel3() {
|
||||
return Level3;
|
||||
}
|
||||
|
||||
public void setLevel3(Double level3) {
|
||||
Level3 = level3;
|
||||
}
|
||||
|
||||
public Double getLevel4() {
|
||||
return Level4;
|
||||
}
|
||||
|
||||
public void setLevel4(Double level4) {
|
||||
Level4 = level4;
|
||||
}
|
||||
|
||||
public Double getLevel5() {
|
||||
return Level5;
|
||||
}
|
||||
|
||||
public void setLevel5(Double level5) {
|
||||
Level5 = level5;
|
||||
}
|
||||
|
||||
public String getImageDate() {
|
||||
return imageDate;
|
||||
}
|
||||
|
||||
public void setImageDate(String imageDate) {
|
||||
this.imageDate = imageDate;
|
||||
}
|
||||
|
||||
public String getProductCode1() {
|
||||
return productCode1;
|
||||
}
|
||||
|
||||
public void setProductCode1(String productCode1) {
|
||||
this.productCode1 = productCode1;
|
||||
}
|
||||
|
||||
public String getProductCode2() {
|
||||
return productCode2;
|
||||
}
|
||||
|
||||
public void setProductCode2(String productCode2) {
|
||||
this.productCode2 = productCode2;
|
||||
}
|
||||
|
||||
public String getProductCode3() {
|
||||
return productCode3;
|
||||
}
|
||||
|
||||
public void setProductCode3(String productCode3) {
|
||||
this.productCode3 = productCode3;
|
||||
}
|
||||
|
||||
public String getCreatedBy() {
|
||||
return createdBy;
|
||||
}
|
||||
|
||||
public void setCreatedBy(String createdBy) {
|
||||
this.createdBy = createdBy;
|
||||
}
|
||||
|
||||
public LocalDateTime getCreatedTime() {
|
||||
return createdTime;
|
||||
}
|
||||
|
||||
public void setCreatedTime(LocalDateTime createdTime) {
|
||||
this.createdTime = createdTime;
|
||||
}
|
||||
|
||||
public String getYear() {
|
||||
return year;
|
||||
}
|
||||
|
||||
public void setYear(String year) {
|
||||
this.year = year;
|
||||
}
|
||||
}
|
@ -0,0 +1,180 @@
|
||||
package com.ruoyi.system.domain_shate;
|
||||
|
||||
|
||||
import java.time.LocalDateTime;
|
||||
|
||||
/**
|
||||
* @Author: JinSheng Song
|
||||
* @Date: 2022/7/7 9:36
|
||||
*/
|
||||
|
||||
public class SoilDesertification extends SysSTEntity
|
||||
{
|
||||
/**
|
||||
* 指定主键,建立自增序列,主键值取自序列
|
||||
*/
|
||||
private Integer id;
|
||||
|
||||
private String year;
|
||||
|
||||
private String zone;
|
||||
|
||||
|
||||
private Double Level1;
|
||||
|
||||
private Double Level2;
|
||||
|
||||
private Double Level3;
|
||||
|
||||
private Double Level4;
|
||||
|
||||
private Double Level5;
|
||||
|
||||
private String imageDate;
|
||||
|
||||
|
||||
|
||||
private String productCode1;
|
||||
|
||||
|
||||
private String productCode2;
|
||||
|
||||
|
||||
private String productCode3;
|
||||
|
||||
|
||||
private String createdBy;
|
||||
|
||||
private LocalDateTime createdTime;
|
||||
|
||||
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 Double getLevel1() {
|
||||
return Level1;
|
||||
}
|
||||
|
||||
public void setLevel1(Double level1) {
|
||||
Level1 = level1;
|
||||
}
|
||||
|
||||
public Double getLevel2() {
|
||||
return Level2;
|
||||
}
|
||||
|
||||
public void setLevel2(Double level2) {
|
||||
Level2 = level2;
|
||||
}
|
||||
|
||||
public Double getLevel3() {
|
||||
return Level3;
|
||||
}
|
||||
|
||||
public void setLevel3(Double level3) {
|
||||
Level3 = level3;
|
||||
}
|
||||
|
||||
public Double getLevel4() {
|
||||
return Level4;
|
||||
}
|
||||
|
||||
public void setLevel4(Double level4) {
|
||||
Level4 = level4;
|
||||
}
|
||||
|
||||
public Double getLevel5() {
|
||||
return Level5;
|
||||
}
|
||||
|
||||
public void setLevel5(Double level5) {
|
||||
Level5 = level5;
|
||||
}
|
||||
|
||||
public String getImageDate() {
|
||||
return imageDate;
|
||||
}
|
||||
|
||||
public void setImageDate(String imageDate) {
|
||||
this.imageDate = imageDate;
|
||||
}
|
||||
|
||||
public String getProductCode1() {
|
||||
return productCode1;
|
||||
}
|
||||
|
||||
public void setProductCode1(String productCode1) {
|
||||
this.productCode1 = productCode1;
|
||||
}
|
||||
|
||||
public String getProductCode2() {
|
||||
return productCode2;
|
||||
}
|
||||
|
||||
public void setProductCode2(String productCode2) {
|
||||
this.productCode2 = productCode2;
|
||||
}
|
||||
|
||||
public String getProductCode3() {
|
||||
return productCode3;
|
||||
}
|
||||
|
||||
public void setProductCode3(String productCode3) {
|
||||
this.productCode3 = productCode3;
|
||||
}
|
||||
|
||||
public String getCreatedBy() {
|
||||
return createdBy;
|
||||
}
|
||||
|
||||
public void setCreatedBy(String createdBy) {
|
||||
this.createdBy = createdBy;
|
||||
}
|
||||
|
||||
public LocalDateTime getCreatedTime() {
|
||||
return createdTime;
|
||||
}
|
||||
|
||||
public void setCreatedTime(LocalDateTime createdTime) {
|
||||
this.createdTime = createdTime;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "SoilDesertification{" +
|
||||
"id=" + id +
|
||||
", zone='" + zone + '\'' +
|
||||
", Level1=" + Level1 +
|
||||
", Level2=" + Level2 +
|
||||
", Level3=" + Level3 +
|
||||
", Level4=" + Level4 +
|
||||
", Level5=" + Level5 +
|
||||
", imageDate=" + imageDate +
|
||||
", productCode1='" + productCode1 + '\'' +
|
||||
", productCode2='" + productCode2 + '\'' +
|
||||
", productCode3='" + productCode3 + '\'' +
|
||||
", createdBy='" + createdBy + '\'' +
|
||||
", createdTime=" + createdTime +
|
||||
'}';
|
||||
}
|
||||
|
||||
public String getYear() {
|
||||
return year;
|
||||
}
|
||||
|
||||
public void setYear(String year) {
|
||||
this.year = year;
|
||||
}
|
||||
}
|
@ -0,0 +1,169 @@
|
||||
package com.ruoyi.system.domain_shate;
|
||||
|
||||
|
||||
import java.time.LocalDateTime;
|
||||
|
||||
/**
|
||||
* @Author: JinSheng Song
|
||||
* @Date: 2022/7/7 9:36
|
||||
*/
|
||||
|
||||
public class SoilMoisture extends SysSTEntity
|
||||
{
|
||||
/**
|
||||
* 指定主键,建立自增序列,主键值取自序列
|
||||
*/
|
||||
private Integer id;
|
||||
|
||||
private String year;
|
||||
|
||||
private String zone;
|
||||
|
||||
private Double Level1;
|
||||
|
||||
private Double Level2;
|
||||
|
||||
private Double Level3;
|
||||
private Double Level4;
|
||||
|
||||
private Double Level5;
|
||||
|
||||
|
||||
private String imageDate;
|
||||
|
||||
|
||||
|
||||
private String productCode1;
|
||||
|
||||
|
||||
private String productCode2;
|
||||
|
||||
|
||||
|
||||
private String createdBy;
|
||||
|
||||
private LocalDateTime craeteTime;
|
||||
|
||||
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 Double getLevel1() {
|
||||
return Level1;
|
||||
}
|
||||
|
||||
public void setLevel1(Double level1) {
|
||||
Level1 = level1;
|
||||
}
|
||||
|
||||
public Double getLevel2() {
|
||||
return Level2;
|
||||
}
|
||||
|
||||
public void setLevel2(Double level2) {
|
||||
Level2 = level2;
|
||||
}
|
||||
|
||||
public Double getLevel3() {
|
||||
return Level3;
|
||||
}
|
||||
|
||||
public void setLevel3(Double level3) {
|
||||
Level3 = level3;
|
||||
}
|
||||
|
||||
public Double getLevel4() {
|
||||
return Level4;
|
||||
}
|
||||
|
||||
public void setLevel4(Double level4) {
|
||||
Level4 = level4;
|
||||
}
|
||||
|
||||
public Double getLevel5() {
|
||||
return Level5;
|
||||
}
|
||||
|
||||
public void setLevel5(Double level5) {
|
||||
Level5 = level5;
|
||||
}
|
||||
|
||||
public String getImageDate() {
|
||||
return imageDate;
|
||||
}
|
||||
|
||||
public void setImageDate(String imageDate) {
|
||||
this.imageDate = imageDate;
|
||||
}
|
||||
|
||||
public String getProductCode1() {
|
||||
return productCode1;
|
||||
}
|
||||
|
||||
public void setProductCode1(String productCode1) {
|
||||
this.productCode1 = productCode1;
|
||||
}
|
||||
|
||||
public String getProductCode2() {
|
||||
return productCode2;
|
||||
}
|
||||
|
||||
public void setProductCode2(String productCode2) {
|
||||
this.productCode2 = productCode2;
|
||||
}
|
||||
|
||||
|
||||
|
||||
public String getCreatedBy() {
|
||||
return createdBy;
|
||||
}
|
||||
|
||||
public void setCreatedBy(String createdBy) {
|
||||
this.createdBy = createdBy;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "Altitude{" +
|
||||
"id=" + id +
|
||||
", zone='" + zone + '\'' +
|
||||
", Level1=" + Level1 +
|
||||
", Level2=" + Level2 +
|
||||
", Level3=" + Level3 +
|
||||
", Level4=" + Level4 +
|
||||
", Level5=" + Level5 +
|
||||
", imageDate=" + imageDate +
|
||||
", productCode1='" + productCode1 + '\'' +
|
||||
", productCode2='" + productCode2 + '\'' +
|
||||
", createdBy='" + createdBy + '\'' +
|
||||
'}';
|
||||
}
|
||||
|
||||
public LocalDateTime getCraeteTime() {
|
||||
return craeteTime;
|
||||
}
|
||||
|
||||
public void setCraeteTime(LocalDateTime craeteTime) {
|
||||
this.craeteTime = craeteTime;
|
||||
}
|
||||
|
||||
public String getYear() {
|
||||
return year;
|
||||
}
|
||||
|
||||
public void setYear(String year) {
|
||||
this.year = year;
|
||||
}
|
||||
}
|
@ -0,0 +1,169 @@
|
||||
package com.ruoyi.system.domain_shate;
|
||||
|
||||
|
||||
import java.time.LocalDateTime;
|
||||
|
||||
/**
|
||||
* @Author: JinSheng Song
|
||||
* @Date: 2022/7/7 9:36
|
||||
*/
|
||||
|
||||
public class SoilSalinization extends SysSTEntity
|
||||
{
|
||||
/**
|
||||
* 指定主键,建立自增序列,主键值取自序列
|
||||
*/
|
||||
private Integer id;
|
||||
|
||||
private String year;
|
||||
|
||||
private String zone;
|
||||
|
||||
private Double Level1;
|
||||
|
||||
private Double Level2;
|
||||
|
||||
private Double Level3;
|
||||
private Double Level4;
|
||||
|
||||
private Double Level5;
|
||||
|
||||
|
||||
private String imageDate;
|
||||
|
||||
private String year1;
|
||||
|
||||
private String productCode1;
|
||||
|
||||
|
||||
private String productCode2;
|
||||
|
||||
|
||||
private String createdBy;
|
||||
|
||||
private LocalDateTime craeteTime;
|
||||
|
||||
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 Double getLevel1() {
|
||||
return Level1;
|
||||
}
|
||||
|
||||
public void setLevel1(Double level1) {
|
||||
Level1 = level1;
|
||||
}
|
||||
|
||||
public Double getLevel2() {
|
||||
return Level2;
|
||||
}
|
||||
|
||||
public void setLevel2(Double level2) {
|
||||
Level2 = level2;
|
||||
}
|
||||
|
||||
public Double getLevel3() {
|
||||
return Level3;
|
||||
}
|
||||
|
||||
public void setLevel3(Double level3) {
|
||||
Level3 = level3;
|
||||
}
|
||||
|
||||
public Double getLevel4() {
|
||||
return Level4;
|
||||
}
|
||||
|
||||
public void setLevel4(Double level4) {
|
||||
Level4 = level4;
|
||||
}
|
||||
|
||||
public Double getLevel5() {
|
||||
return Level5;
|
||||
}
|
||||
|
||||
public void setLevel5(Double level5) {
|
||||
Level5 = level5;
|
||||
}
|
||||
|
||||
public String getImageDate() {
|
||||
return imageDate;
|
||||
}
|
||||
|
||||
public void setImageDate(String imageDate) {
|
||||
this.imageDate = imageDate;
|
||||
}
|
||||
|
||||
public String getProductCode1() {
|
||||
return productCode1;
|
||||
}
|
||||
|
||||
public void setProductCode1(String productCode1) {
|
||||
this.productCode1 = productCode1;
|
||||
}
|
||||
|
||||
public String getProductCode2() {
|
||||
return productCode2;
|
||||
}
|
||||
|
||||
public void setProductCode2(String productCode2) {
|
||||
this.productCode2 = productCode2;
|
||||
}
|
||||
|
||||
|
||||
|
||||
public String getCreatedBy() {
|
||||
return createdBy;
|
||||
}
|
||||
|
||||
public void setCreatedBy(String createdBy) {
|
||||
this.createdBy = createdBy;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "Altitude{" +
|
||||
"id=" + id +
|
||||
", zone='" + zone + '\'' +
|
||||
", Level1=" + Level1 +
|
||||
", Level2=" + Level2 +
|
||||
", Level3=" + Level3 +
|
||||
", Level4=" + Level4 +
|
||||
", Level5=" + Level5 +
|
||||
", imageDate=" + imageDate +
|
||||
", productCode1='" + productCode1 + '\'' +
|
||||
", productCode2='" + productCode2 + '\'' +
|
||||
", createdBy='" + createdBy + '\'' +
|
||||
'}';
|
||||
}
|
||||
|
||||
public LocalDateTime getCraeteTime() {
|
||||
return craeteTime;
|
||||
}
|
||||
|
||||
public void setCraeteTime(LocalDateTime craeteTime) {
|
||||
this.craeteTime = craeteTime;
|
||||
}
|
||||
|
||||
public String getYear() {
|
||||
return year;
|
||||
}
|
||||
|
||||
public void setYear(String year) {
|
||||
this.year = year;
|
||||
}
|
||||
|
||||
}
|
@ -0,0 +1,95 @@
|
||||
package com.ruoyi.system.domain_shate;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.time.LocalDateTime;
|
||||
import java.util.HashMap;
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* Entity基类
|
||||
*
|
||||
* @author ruoyi
|
||||
*/
|
||||
public class SysBaseEntity implements Serializable
|
||||
{
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/** 创建者 */
|
||||
private String createBy;
|
||||
|
||||
/** 创建时间 */
|
||||
private LocalDateTime createTime;
|
||||
|
||||
/** 更新者 */
|
||||
private String updateBy;
|
||||
|
||||
/** 更新时间 */
|
||||
private LocalDateTime updateTime;
|
||||
|
||||
/** 备注 */
|
||||
private String remark;
|
||||
|
||||
/** 请求参数 */
|
||||
private Map<String, Object> params;
|
||||
|
||||
public String getCreateBy()
|
||||
{
|
||||
return createBy;
|
||||
}
|
||||
|
||||
public void setCreateBy(String createBy)
|
||||
{
|
||||
this.createBy = createBy;
|
||||
}
|
||||
|
||||
public LocalDateTime getCreateTime() {
|
||||
return createTime;
|
||||
}
|
||||
|
||||
public void setCreateTime(LocalDateTime createTime) {
|
||||
this.createTime = createTime;
|
||||
}
|
||||
|
||||
public String getUpdateBy()
|
||||
{
|
||||
return updateBy;
|
||||
}
|
||||
|
||||
public void setUpdateBy(String updateBy)
|
||||
{
|
||||
this.updateBy = updateBy;
|
||||
}
|
||||
|
||||
public LocalDateTime getUpdateTime() {
|
||||
return updateTime;
|
||||
}
|
||||
|
||||
public void setUpdateTime(LocalDateTime updateTime) {
|
||||
this.updateTime = updateTime;
|
||||
}
|
||||
|
||||
public String getRemark()
|
||||
{
|
||||
return remark;
|
||||
}
|
||||
|
||||
public void setRemark(String remark)
|
||||
{
|
||||
this.remark = remark;
|
||||
}
|
||||
|
||||
public Map<String, Object> getParams()
|
||||
{
|
||||
if (params == null)
|
||||
{
|
||||
params = new HashMap<>();
|
||||
}
|
||||
return params;
|
||||
}
|
||||
|
||||
public void setParams(Map<String, Object> params)
|
||||
{
|
||||
this.params = params;
|
||||
}
|
||||
|
||||
}
|
@ -0,0 +1,17 @@
|
||||
package com.ruoyi.system.domain_shate;
|
||||
|
||||
/**
|
||||
* @Author: JinSheng Song
|
||||
* @Date: 2022/7/11 10:02
|
||||
*/
|
||||
public class SysSTEntity {
|
||||
private String link;
|
||||
|
||||
public String getLink() {
|
||||
return link;
|
||||
}
|
||||
|
||||
public void setLink(String link) {
|
||||
this.link = link;
|
||||
}
|
||||
}
|
@ -0,0 +1,220 @@
|
||||
package com.ruoyi.system.domain_shate;
|
||||
|
||||
import com.ruoyi.system.service_shate.impl.PlantingSuitabilityServiceIpml;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @Author: JinSheng Song
|
||||
* @Date: 2022/7/11 11:03
|
||||
*/
|
||||
public class UplodFile
|
||||
{
|
||||
|
||||
/**
|
||||
* 名称
|
||||
*/
|
||||
private String name;
|
||||
|
||||
/**
|
||||
* 播种成功率
|
||||
*/
|
||||
private List<SeedingSuccessRate> information;
|
||||
|
||||
/**
|
||||
* 土地利用类型
|
||||
*/
|
||||
private List<LandUse> landUses;
|
||||
|
||||
/**
|
||||
* 种植适宜性
|
||||
*/
|
||||
private List<PlantingSuitability> plantingSuitabilities;
|
||||
|
||||
/**
|
||||
* 植被健康状况
|
||||
*/
|
||||
private List<VegetationHealth> vegetationHealths;
|
||||
/**
|
||||
* 地域因子-水分因素
|
||||
*/
|
||||
private List<WaterFactor> waterFactors;
|
||||
/**
|
||||
* 地域因子-地域指数
|
||||
*/
|
||||
private List<RegionIndex> regionIndexs;
|
||||
/**
|
||||
* 地域因子-道路指数
|
||||
*/
|
||||
private List<RoadFactor> roadFactors;
|
||||
|
||||
private List<Integer> id;
|
||||
|
||||
public List<RegionIndex> getRegionIndexs() {
|
||||
return regionIndexs;
|
||||
}
|
||||
|
||||
public void setRegionIndexs(List<RegionIndex> regionIndexs) {
|
||||
this.regionIndexs = regionIndexs;
|
||||
}
|
||||
|
||||
public List<RoadFactor> getRoadFactors() {
|
||||
return roadFactors;
|
||||
}
|
||||
|
||||
public void setRoadFactors(List<RoadFactor> roadFactors) {
|
||||
this.roadFactors = roadFactors;
|
||||
}
|
||||
|
||||
/**
|
||||
* 土壤因子-土壤沙化指数
|
||||
*/
|
||||
private List<SoilDesertification> soilDesertifications;
|
||||
/**
|
||||
* 土壤因子-土壤湿度指数
|
||||
*/
|
||||
private List<SoilMoisture> soilMoistures;
|
||||
/**
|
||||
* 土壤因子-土壤盐渍化指数
|
||||
*/
|
||||
private List<SoilSalinization> soilSalinizations;
|
||||
|
||||
/**
|
||||
* 地形因子-海拔
|
||||
*/
|
||||
private List<Altitude> altitudes;
|
||||
/**
|
||||
* 地形因子-坡向
|
||||
*/
|
||||
private List<Aspect> aspects;
|
||||
/**
|
||||
* 地形因子-坡度
|
||||
*/
|
||||
private List<Slope> slopes;
|
||||
|
||||
private List<Climate> Climate;
|
||||
|
||||
|
||||
private List<DateUpload> dateUploads;
|
||||
|
||||
public List<LandUse> getLandUses() {
|
||||
return landUses;
|
||||
}
|
||||
|
||||
public void setLandUses(List<LandUse> landUses) {
|
||||
this.landUses = landUses;
|
||||
}
|
||||
|
||||
public List<PlantingSuitability> getPlantingSuitabilities() {
|
||||
return plantingSuitabilities;
|
||||
}
|
||||
|
||||
public void setPlantingSuitabilities(List<PlantingSuitability> plantingSuitabilities) {
|
||||
this.plantingSuitabilities = plantingSuitabilities;
|
||||
}
|
||||
|
||||
public List<VegetationHealth> getVegetationHealths() {
|
||||
return vegetationHealths;
|
||||
}
|
||||
|
||||
public void setVegetationHealths(List<VegetationHealth> vegetationHealths) {
|
||||
this.vegetationHealths = vegetationHealths;
|
||||
}
|
||||
|
||||
public List<WaterFactor> getWaterFactors() {
|
||||
return waterFactors;
|
||||
}
|
||||
|
||||
public void setWaterFactors(List<WaterFactor> waterFactors) {
|
||||
this.waterFactors = waterFactors;
|
||||
}
|
||||
|
||||
|
||||
public List<SoilDesertification> getSoilDesertifications() {
|
||||
return soilDesertifications;
|
||||
}
|
||||
|
||||
public void setSoilDesertifications(List<SoilDesertification> soilDesertifications) {
|
||||
this.soilDesertifications = soilDesertifications;
|
||||
}
|
||||
|
||||
public List<SoilMoisture> getSoilMoistures() {
|
||||
return soilMoistures;
|
||||
}
|
||||
|
||||
public void setSoilMoistures(List<SoilMoisture> soilMoistures) {
|
||||
this.soilMoistures = soilMoistures;
|
||||
}
|
||||
|
||||
public List<SoilSalinization> getSoilSalinizations() {
|
||||
return soilSalinizations;
|
||||
}
|
||||
|
||||
public void setSoilSalinizations(List<SoilSalinization> soilSalinizations) {
|
||||
this.soilSalinizations = soilSalinizations;
|
||||
}
|
||||
|
||||
public List<Altitude> getAltitudes() {
|
||||
return altitudes;
|
||||
}
|
||||
|
||||
public void setAltitudes(List<Altitude> altitudes) {
|
||||
this.altitudes = altitudes;
|
||||
}
|
||||
|
||||
public List<Aspect> getAspects() {
|
||||
return aspects;
|
||||
}
|
||||
|
||||
public void setAspects(List<Aspect> aspects) {
|
||||
this.aspects = aspects;
|
||||
}
|
||||
|
||||
public List<Slope> getSlopes() {
|
||||
return slopes;
|
||||
}
|
||||
|
||||
public void setSlopes(List<Slope> slopes) {
|
||||
this.slopes = slopes;
|
||||
}
|
||||
|
||||
public String getName() {
|
||||
return name;
|
||||
}
|
||||
|
||||
public void setName(String name) {
|
||||
this.name = name;
|
||||
}
|
||||
|
||||
public List<SeedingSuccessRate> getInformation() {
|
||||
return information;
|
||||
}
|
||||
|
||||
public void setInformation(List<SeedingSuccessRate> information) {
|
||||
this.information = information;
|
||||
}
|
||||
|
||||
public List<DateUpload> getDateUploads() {
|
||||
return dateUploads;
|
||||
}
|
||||
|
||||
public void setDateUploads(List<DateUpload> dateUploads) {
|
||||
this.dateUploads = dateUploads;
|
||||
}
|
||||
|
||||
public List<Integer> getId() {
|
||||
return id;
|
||||
}
|
||||
|
||||
public void setId(List<Integer> id) {
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
public List<com.ruoyi.system.domain_shate.Climate> getClimate() {
|
||||
return Climate;
|
||||
}
|
||||
|
||||
public void setClimate(List<com.ruoyi.system.domain_shate.Climate> climate) {
|
||||
Climate = climate;
|
||||
}
|
||||
}
|
@ -0,0 +1,178 @@
|
||||
package com.ruoyi.system.domain_shate;
|
||||
|
||||
import java.time.LocalDateTime;
|
||||
|
||||
/**
|
||||
* @Author: JinSheng Song
|
||||
* @Date: 2022/7/8 8:41
|
||||
*/
|
||||
public class VegetationHealth extends SysSTEntity
|
||||
{
|
||||
private Integer id;
|
||||
|
||||
private String zone;
|
||||
|
||||
private Double healthy;
|
||||
|
||||
private Double normal;
|
||||
|
||||
private Double notHealthy;
|
||||
|
||||
private Double totalArea;
|
||||
|
||||
private String resolution;
|
||||
|
||||
private Double max;
|
||||
|
||||
private String imageDate;
|
||||
|
||||
private String productCode1;
|
||||
|
||||
private String productCode2;
|
||||
|
||||
private String productCode3;
|
||||
|
||||
private String year;
|
||||
|
||||
private String createdBy;
|
||||
|
||||
private LocalDateTime craeteTime;
|
||||
|
||||
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 Double getHealthy() {
|
||||
return healthy;
|
||||
}
|
||||
|
||||
public void setHealthy(Double healthy) {
|
||||
this.healthy = healthy;
|
||||
}
|
||||
|
||||
public Double getNormal() {
|
||||
return normal;
|
||||
}
|
||||
|
||||
public void setNormal(Double normal) {
|
||||
this.normal = normal;
|
||||
}
|
||||
|
||||
public Double getNotHealthy() {
|
||||
return notHealthy;
|
||||
}
|
||||
|
||||
public void setNotHealthy(Double notHealthy) {
|
||||
this.notHealthy = notHealthy;
|
||||
}
|
||||
|
||||
public Double getTotalArea() {
|
||||
return totalArea;
|
||||
}
|
||||
|
||||
public void setTotalArea(Double totalArea) {
|
||||
this.totalArea = totalArea;
|
||||
}
|
||||
|
||||
public String getImageDate() {
|
||||
return imageDate;
|
||||
}
|
||||
|
||||
public void setImageDate(String imageDate) {
|
||||
this.imageDate = imageDate;
|
||||
}
|
||||
|
||||
public String getProductCode1() {
|
||||
return productCode1;
|
||||
}
|
||||
|
||||
public void setProductCode1(String productCode1) {
|
||||
this.productCode1 = productCode1;
|
||||
}
|
||||
|
||||
public String getProductCode2() {
|
||||
return productCode2;
|
||||
}
|
||||
|
||||
public void setProductCode2(String productCode2) {
|
||||
this.productCode2 = productCode2;
|
||||
}
|
||||
|
||||
public String getProductCode3() {
|
||||
return productCode3;
|
||||
}
|
||||
|
||||
public void setProductCode3(String productCode3) {
|
||||
this.productCode3 = productCode3;
|
||||
}
|
||||
|
||||
public String getCreatedBy() {
|
||||
return createdBy;
|
||||
}
|
||||
|
||||
public void setCreatedBy(String createdBy) {
|
||||
this.createdBy = createdBy;
|
||||
}
|
||||
|
||||
public LocalDateTime getCraeteTime() {
|
||||
return craeteTime;
|
||||
}
|
||||
|
||||
public void setCraeteTime(LocalDateTime craeteTime) {
|
||||
this.craeteTime = craeteTime;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "VegetationHealth{" +
|
||||
"id=" + id +
|
||||
", zone='" + zone + '\'' +
|
||||
", healthy=" + healthy +
|
||||
", normal=" + normal +
|
||||
", notHealthy=" + notHealthy +
|
||||
", totalArea=" + totalArea +
|
||||
", imageDate=" + imageDate +
|
||||
", productCode1='" + productCode1 + '\'' +
|
||||
", productCode2='" + productCode2 + '\'' +
|
||||
", productCode3='" + productCode3 + '\'' +
|
||||
", createdBy='" + createdBy + '\'' +
|
||||
", craeteTime=" + craeteTime +
|
||||
'}';
|
||||
}
|
||||
|
||||
public String getYear() {
|
||||
return year;
|
||||
}
|
||||
|
||||
public void setYear(String year) {
|
||||
this.year = year;
|
||||
}
|
||||
|
||||
public String getResolution() {
|
||||
return resolution;
|
||||
}
|
||||
|
||||
public void setResolution(String resolution) {
|
||||
this.resolution = resolution;
|
||||
}
|
||||
|
||||
public Double getMax() {
|
||||
return max;
|
||||
}
|
||||
|
||||
public void setMax(Double max) {
|
||||
this.max = max;
|
||||
}
|
||||
}
|
@ -0,0 +1,179 @@
|
||||
package com.ruoyi.system.domain_shate;
|
||||
|
||||
|
||||
import java.time.LocalDateTime;
|
||||
|
||||
/**
|
||||
* @Author: JinSheng Song
|
||||
* @Date: 2022/7/7 9:36
|
||||
*/
|
||||
|
||||
public class WaterFactor extends SysSTEntity
|
||||
{
|
||||
/**
|
||||
* 指定主键,建立自增序列,主键值取自序列
|
||||
*/
|
||||
private Integer id;
|
||||
|
||||
private String year;
|
||||
|
||||
private String zone;
|
||||
|
||||
private Double max;
|
||||
|
||||
private Double level1;
|
||||
|
||||
private Double level2;
|
||||
|
||||
private Double level3;
|
||||
|
||||
private Double level4;
|
||||
|
||||
private Double level5;
|
||||
|
||||
|
||||
private String imageDate;
|
||||
|
||||
|
||||
|
||||
private String productCode1;
|
||||
|
||||
|
||||
private String productCode2;
|
||||
|
||||
|
||||
|
||||
private String createdBy;
|
||||
|
||||
private LocalDateTime craeteTime;
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "WaterFactor{" +
|
||||
"id=" + id +
|
||||
", zone='" + zone + '\'' +
|
||||
", level1=" + level1 +
|
||||
", level2=" + level2 +
|
||||
", level3=" + level3 +
|
||||
", level4=" + level4 +
|
||||
", level5=" + level5 +
|
||||
", imageDate=" + imageDate +
|
||||
", productCode1='" + productCode1 + '\'' +
|
||||
", productCode2='" + productCode2 + '\'' +
|
||||
", createdBy='" + createdBy + '\'' +
|
||||
", craeteTime=" + craeteTime +
|
||||
'}';
|
||||
}
|
||||
|
||||
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 Double getLevel1() {
|
||||
return level1;
|
||||
}
|
||||
|
||||
public void setLevel1(Double level1) {
|
||||
this.level1 = level1;
|
||||
}
|
||||
|
||||
public Double getLevel2() {
|
||||
return level2;
|
||||
}
|
||||
|
||||
public void setLevel2(Double level2) {
|
||||
this.level2 = level2;
|
||||
}
|
||||
|
||||
public Double getLevel3() {
|
||||
return level3;
|
||||
}
|
||||
|
||||
public void setLevel3(Double level3) {
|
||||
this.level3 = level3;
|
||||
}
|
||||
|
||||
public Double getLevel4() {
|
||||
return level4;
|
||||
}
|
||||
|
||||
public void setLevel4(Double level4) {
|
||||
this.level4 = level4;
|
||||
}
|
||||
|
||||
public Double getLevel5() {
|
||||
return level5;
|
||||
}
|
||||
|
||||
public void setLevel5(Double level5) {
|
||||
this.level5 = level5;
|
||||
}
|
||||
|
||||
public String getImageDate() {
|
||||
return imageDate;
|
||||
}
|
||||
|
||||
public void setImageDate(String imageDate) {
|
||||
this.imageDate = imageDate;
|
||||
}
|
||||
|
||||
public String getProductCode1() {
|
||||
return productCode1;
|
||||
}
|
||||
|
||||
public void setProductCode1(String productCode1) {
|
||||
this.productCode1 = productCode1;
|
||||
}
|
||||
|
||||
public String getProductCode2() {
|
||||
return productCode2;
|
||||
}
|
||||
|
||||
public void setProductCode2(String productCode2) {
|
||||
this.productCode2 = productCode2;
|
||||
}
|
||||
|
||||
public String getCreatedBy() {
|
||||
return createdBy;
|
||||
}
|
||||
|
||||
public void setCreatedBy(String createdBy) {
|
||||
this.createdBy = createdBy;
|
||||
}
|
||||
|
||||
public LocalDateTime getCraeteTime() {
|
||||
return craeteTime;
|
||||
}
|
||||
|
||||
public void setCraeteTime(LocalDateTime craeteTime) {
|
||||
this.craeteTime = craeteTime;
|
||||
}
|
||||
|
||||
public String getYear() {
|
||||
return year;
|
||||
}
|
||||
|
||||
public void setYear(String year) {
|
||||
this.year = year;
|
||||
}
|
||||
|
||||
public Double getMax() {
|
||||
return max;
|
||||
}
|
||||
|
||||
public void setMax(Double max) {
|
||||
this.max = max;
|
||||
}
|
||||
}
|
@ -0,0 +1,220 @@
|
||||
package com.ruoyi.system.domain_shate;
|
||||
|
||||
/**
|
||||
* @Author: JinSheng Song
|
||||
* @Date: 2022/7/23 16:38
|
||||
*/
|
||||
public class lanUseNew
|
||||
{
|
||||
private Integer id;
|
||||
|
||||
private String zone;
|
||||
|
||||
private Double area;
|
||||
|
||||
private Double percent;
|
||||
|
||||
private Double total;
|
||||
|
||||
private String imageDate;
|
||||
|
||||
private String productCode1;
|
||||
|
||||
private String productCode2;
|
||||
|
||||
private String productCode3;
|
||||
|
||||
private String year;
|
||||
|
||||
private String createdBy;
|
||||
|
||||
private Double Fields;
|
||||
|
||||
private Double Buildings;
|
||||
|
||||
private Double Roads;
|
||||
|
||||
private Double Water;
|
||||
|
||||
private Double Grass;
|
||||
|
||||
private Double Forest;
|
||||
|
||||
private Double Soil;
|
||||
|
||||
private Double Desert;
|
||||
|
||||
private Double Rocks;
|
||||
|
||||
private Double Other;
|
||||
|
||||
public Double getFields() {
|
||||
return Fields;
|
||||
}
|
||||
|
||||
public void setFields(Double fields) {
|
||||
Fields = fields;
|
||||
}
|
||||
|
||||
public Double getBuildings() {
|
||||
return Buildings;
|
||||
}
|
||||
|
||||
public void setBuildings(Double buildings) {
|
||||
Buildings = buildings;
|
||||
}
|
||||
|
||||
public Double getRoads() {
|
||||
return Roads;
|
||||
}
|
||||
|
||||
public void setRoads(Double roads) {
|
||||
Roads = roads;
|
||||
}
|
||||
|
||||
public Double getWater() {
|
||||
return Water;
|
||||
}
|
||||
|
||||
public void setWater(Double water) {
|
||||
Water = water;
|
||||
}
|
||||
|
||||
public Double getGrass() {
|
||||
return Grass;
|
||||
}
|
||||
|
||||
public void setGrass(Double grass) {
|
||||
Grass = grass;
|
||||
}
|
||||
|
||||
public Double getForest() {
|
||||
return Forest;
|
||||
}
|
||||
|
||||
public void setForest(Double forest) {
|
||||
Forest = forest;
|
||||
}
|
||||
|
||||
public Double getSoil() {
|
||||
return Soil;
|
||||
}
|
||||
|
||||
public void setSoil(Double soil) {
|
||||
Soil = soil;
|
||||
}
|
||||
|
||||
public Double getDesert() {
|
||||
return Desert;
|
||||
}
|
||||
|
||||
public void setDesert(Double desert) {
|
||||
Desert = desert;
|
||||
}
|
||||
|
||||
public Double getRocks() {
|
||||
return Rocks;
|
||||
}
|
||||
|
||||
public void setRocks(Double rocks) {
|
||||
Rocks = rocks;
|
||||
}
|
||||
|
||||
public Double getOther() {
|
||||
return Other;
|
||||
}
|
||||
|
||||
public void setOther(Double other) {
|
||||
Other = other;
|
||||
}
|
||||
|
||||
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 Double getArea() {
|
||||
return area;
|
||||
}
|
||||
|
||||
public void setArea(Double area) {
|
||||
this.area = area;
|
||||
}
|
||||
|
||||
public Double getPercent() {
|
||||
return percent;
|
||||
}
|
||||
|
||||
public void setPercent(Double percent) {
|
||||
this.percent = percent;
|
||||
}
|
||||
|
||||
public Double getTotal() {
|
||||
return total;
|
||||
}
|
||||
|
||||
public void setTotal(Double total) {
|
||||
this.total = total;
|
||||
}
|
||||
|
||||
public String getImageDate() {
|
||||
return imageDate;
|
||||
}
|
||||
|
||||
public void setImageDate(String imageDate) {
|
||||
this.imageDate = imageDate;
|
||||
}
|
||||
|
||||
public String getProductCode1() {
|
||||
return productCode1;
|
||||
}
|
||||
|
||||
public void setProductCode1(String productCode1) {
|
||||
this.productCode1 = productCode1;
|
||||
}
|
||||
|
||||
public String getProductCode2() {
|
||||
return productCode2;
|
||||
}
|
||||
|
||||
public void setProductCode2(String productCode2) {
|
||||
this.productCode2 = productCode2;
|
||||
}
|
||||
|
||||
public String getProductCode3() {
|
||||
return productCode3;
|
||||
}
|
||||
|
||||
public void setProductCode3(String productCode3) {
|
||||
this.productCode3 = productCode3;
|
||||
}
|
||||
|
||||
public String getYear() {
|
||||
return year;
|
||||
}
|
||||
|
||||
public void setYear(String year) {
|
||||
this.year = year;
|
||||
}
|
||||
|
||||
public String getCreatedBy() {
|
||||
return createdBy;
|
||||
}
|
||||
|
||||
public void setCreatedBy(String createdBy) {
|
||||
this.createdBy = createdBy;
|
||||
}
|
||||
|
||||
|
||||
}
|
@ -0,0 +1,32 @@
|
||||
package com.ruoyi.system.domain_shate;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @Author: JinSheng Song
|
||||
* @Date: 2022/7/13 13:55
|
||||
*/
|
||||
public class pageVO
|
||||
{
|
||||
|
||||
private int total;
|
||||
|
||||
private List<?> value;
|
||||
|
||||
public int getTotal() {
|
||||
return total;
|
||||
}
|
||||
|
||||
public void setTotal(int total) {
|
||||
this.total = total;
|
||||
}
|
||||
|
||||
public List<?> getValue() {
|
||||
return value;
|
||||
}
|
||||
|
||||
public void setValue(List<?> value) {
|
||||
this.value = value;
|
||||
}
|
||||
|
||||
}
|
@ -0,0 +1,121 @@
|
||||
package com.ruoyi.system.domain_shate;
|
||||
|
||||
import java.time.LocalDate;
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @Author: JinSheng Song
|
||||
* @Date: 2022/7/13 14:38
|
||||
*/
|
||||
public class paging {
|
||||
|
||||
private Integer pageNum;
|
||||
|
||||
private Integer pageSize;
|
||||
|
||||
private String zone;//区域
|
||||
private String type;//类型1
|
||||
private String type1;//类型2
|
||||
private String type2;
|
||||
|
||||
private String type3;
|
||||
|
||||
private String year;
|
||||
|
||||
private String uploadTime;
|
||||
|
||||
private String dateTime;
|
||||
|
||||
|
||||
private List<Integer> ids;
|
||||
|
||||
public String getZone() {
|
||||
return zone;
|
||||
}
|
||||
|
||||
public void setZone(String zone) {
|
||||
this.zone = zone;
|
||||
}
|
||||
|
||||
public String getType() {
|
||||
return type;
|
||||
}
|
||||
|
||||
public void setType(String type) {
|
||||
this.type = type;
|
||||
}
|
||||
|
||||
public String getType1() {
|
||||
return type1;
|
||||
}
|
||||
|
||||
public void setType1(String type1) {
|
||||
this.type1 = type1;
|
||||
}
|
||||
|
||||
public String getType2() {
|
||||
return type2;
|
||||
}
|
||||
|
||||
public void setType2(String type2) {
|
||||
this.type2 = type2;
|
||||
}
|
||||
|
||||
|
||||
public Integer getPageNum() {
|
||||
return pageNum;
|
||||
}
|
||||
|
||||
public void setPageNum(Integer pageNum) {
|
||||
this.pageNum = pageNum;
|
||||
}
|
||||
|
||||
public Integer getPageSize() {
|
||||
return pageSize;
|
||||
}
|
||||
|
||||
public void setPageSize(Integer pageSize) {
|
||||
this.pageSize = pageSize;
|
||||
}
|
||||
|
||||
public String getUploadTime() {
|
||||
return uploadTime;
|
||||
}
|
||||
|
||||
public void setUploadTime(String uploadTime) {
|
||||
this.uploadTime = uploadTime;
|
||||
}
|
||||
|
||||
public String getType3() {
|
||||
return type3;
|
||||
}
|
||||
|
||||
public void setType3(String type3) {
|
||||
this.type3 = type3;
|
||||
}
|
||||
|
||||
public List<Integer> getIds() {
|
||||
return ids;
|
||||
}
|
||||
|
||||
public void setIds(List<Integer> ids) {
|
||||
this.ids = ids;
|
||||
}
|
||||
|
||||
public String getYear() {
|
||||
return year;
|
||||
}
|
||||
|
||||
public void setYear(String year) {
|
||||
this.year = year;
|
||||
}
|
||||
|
||||
public String getDateTime() {
|
||||
return dateTime;
|
||||
}
|
||||
|
||||
public void setDateTime(String dateTime) {
|
||||
this.dateTime = dateTime;
|
||||
}
|
||||
}
|
@ -0,0 +1,68 @@
|
||||
package com.ruoyi.system.mapper;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.system.domain.SysConfig;
|
||||
|
||||
/**
|
||||
* 参数配置 数据层
|
||||
*
|
||||
* @author ruoyi
|
||||
*/
|
||||
public interface SysConfigMapper
|
||||
{
|
||||
/**
|
||||
* 查询参数配置信息
|
||||
*
|
||||
* @param config 参数配置信息
|
||||
* @return 参数配置信息
|
||||
*/
|
||||
public SysConfig selectConfig(SysConfig config);
|
||||
|
||||
/**
|
||||
* 查询参数配置列表
|
||||
*
|
||||
* @param config 参数配置信息
|
||||
* @return 参数配置集合
|
||||
*/
|
||||
public List<SysConfig> selectConfigList(SysConfig config);
|
||||
|
||||
/**
|
||||
* 根据键名查询参数配置信息
|
||||
*
|
||||
* @param configKey 参数键名
|
||||
* @return 参数配置信息
|
||||
*/
|
||||
public SysConfig checkConfigKeyUnique(String configKey);
|
||||
|
||||
/**
|
||||
* 新增参数配置
|
||||
*
|
||||
* @param config 参数配置信息
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertConfig(SysConfig config);
|
||||
|
||||
/**
|
||||
* 修改参数配置
|
||||
*
|
||||
* @param config 参数配置信息
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateConfig(SysConfig config);
|
||||
|
||||
/**
|
||||
* 删除参数配置
|
||||
*
|
||||
* @param configId 参数ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteConfigById(Long configId);
|
||||
|
||||
/**
|
||||
* 批量删除参数信息
|
||||
*
|
||||
* @param configIds 需要删除的参数ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteConfigByIds(Long[] configIds);
|
||||
}
|
@ -0,0 +1,118 @@
|
||||
package com.ruoyi.system.mapper;
|
||||
|
||||
import java.util.List;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
import com.ruoyi.common.core.domain.entity.SysDept;
|
||||
|
||||
/**
|
||||
* 部门管理 数据层
|
||||
*
|
||||
* @author ruoyi
|
||||
*/
|
||||
public interface SysDeptMapper
|
||||
{
|
||||
/**
|
||||
* 查询部门管理数据
|
||||
*
|
||||
* @param dept 部门信息
|
||||
* @return 部门信息集合
|
||||
*/
|
||||
public List<SysDept> selectDeptList(SysDept dept);
|
||||
|
||||
/**
|
||||
* 根据角色ID查询部门树信息
|
||||
*
|
||||
* @param roleId 角色ID
|
||||
* @param deptCheckStrictly 部门树选择项是否关联显示
|
||||
* @return 选中部门列表
|
||||
*/
|
||||
public List<Long> selectDeptListByRoleId(@Param("roleId") Long roleId, @Param("deptCheckStrictly") boolean deptCheckStrictly);
|
||||
|
||||
/**
|
||||
* 根据部门ID查询信息
|
||||
*
|
||||
* @param deptId 部门ID
|
||||
* @return 部门信息
|
||||
*/
|
||||
public SysDept selectDeptById(Long deptId);
|
||||
|
||||
/**
|
||||
* 根据ID查询所有子部门
|
||||
*
|
||||
* @param deptId 部门ID
|
||||
* @return 部门列表
|
||||
*/
|
||||
public List<SysDept> selectChildrenDeptById(Long deptId);
|
||||
|
||||
/**
|
||||
* 根据ID查询所有子部门(正常状态)
|
||||
*
|
||||
* @param deptId 部门ID
|
||||
* @return 子部门数
|
||||
*/
|
||||
public int selectNormalChildrenDeptById(Long deptId);
|
||||
|
||||
/**
|
||||
* 是否存在子节点
|
||||
*
|
||||
* @param deptId 部门ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int hasChildByDeptId(Long deptId);
|
||||
|
||||
/**
|
||||
* 查询部门是否存在用户
|
||||
*
|
||||
* @param deptId 部门ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int checkDeptExistUser(Long deptId);
|
||||
|
||||
/**
|
||||
* 校验部门名称是否唯一
|
||||
*
|
||||
* @param deptName 部门名称
|
||||
* @param parentId 父部门ID
|
||||
* @return 结果
|
||||
*/
|
||||
public SysDept checkDeptNameUnique(@Param("deptName") String deptName, @Param("parentId") Long parentId);
|
||||
|
||||
/**
|
||||
* 新增部门信息
|
||||
*
|
||||
* @param dept 部门信息
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertDept(SysDept dept);
|
||||
|
||||
/**
|
||||
* 修改部门信息
|
||||
*
|
||||
* @param dept 部门信息
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateDept(SysDept dept);
|
||||
|
||||
/**
|
||||
* 修改所在部门正常状态
|
||||
*
|
||||
* @param deptIds 部门ID组
|
||||
*/
|
||||
public void updateDeptStatusNormal(Long[] deptIds);
|
||||
|
||||
/**
|
||||
* 修改子元素关系
|
||||
*
|
||||
* @param depts 子元素
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateDeptChildren(@Param("depts") List<SysDept> depts);
|
||||
|
||||
/**
|
||||
* 删除部门管理信息
|
||||
*
|
||||
* @param deptId 部门ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteDeptById(Long deptId);
|
||||
}
|
@ -0,0 +1,95 @@
|
||||
package com.ruoyi.system.mapper;
|
||||
|
||||
import java.util.List;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
import com.ruoyi.common.core.domain.entity.SysDictData;
|
||||
|
||||
/**
|
||||
* 字典表 数据层
|
||||
*
|
||||
* @author ruoyi
|
||||
*/
|
||||
public interface SysDictDataMapper
|
||||
{
|
||||
/**
|
||||
* 根据条件分页查询字典数据
|
||||
*
|
||||
* @param dictData 字典数据信息
|
||||
* @return 字典数据集合信息
|
||||
*/
|
||||
public List<SysDictData> selectDictDataList(SysDictData dictData);
|
||||
|
||||
/**
|
||||
* 根据字典类型查询字典数据
|
||||
*
|
||||
* @param dictType 字典类型
|
||||
* @return 字典数据集合信息
|
||||
*/
|
||||
public List<SysDictData> selectDictDataByType(String dictType);
|
||||
|
||||
/**
|
||||
* 根据字典类型和字典键值查询字典数据信息
|
||||
*
|
||||
* @param dictType 字典类型
|
||||
* @param dictValue 字典键值
|
||||
* @return 字典标签
|
||||
*/
|
||||
public String selectDictLabel(@Param("dictType") String dictType, @Param("dictValue") String dictValue);
|
||||
|
||||
/**
|
||||
* 根据字典数据ID查询信息
|
||||
*
|
||||
* @param dictCode 字典数据ID
|
||||
* @return 字典数据
|
||||
*/
|
||||
public SysDictData selectDictDataById(Long dictCode);
|
||||
|
||||
/**
|
||||
* 查询字典数据
|
||||
*
|
||||
* @param dictType 字典类型
|
||||
* @return 字典数据
|
||||
*/
|
||||
public int countDictDataByType(String dictType);
|
||||
|
||||
/**
|
||||
* 通过字典ID删除字典数据信息
|
||||
*
|
||||
* @param dictCode 字典数据ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteDictDataById(Long dictCode);
|
||||
|
||||
/**
|
||||
* 批量删除字典数据信息
|
||||
*
|
||||
* @param dictCodes 需要删除的字典数据ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteDictDataByIds(Long[] dictCodes);
|
||||
|
||||
/**
|
||||
* 新增字典数据信息
|
||||
*
|
||||
* @param dictData 字典数据信息
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertDictData(SysDictData dictData);
|
||||
|
||||
/**
|
||||
* 修改字典数据信息
|
||||
*
|
||||
* @param dictData 字典数据信息
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateDictData(SysDictData dictData);
|
||||
|
||||
/**
|
||||
* 同步修改字典类型
|
||||
*
|
||||
* @param oldDictType 旧字典类型
|
||||
* @param newDictType 新旧字典类型
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateDictDataType(@Param("oldDictType") String oldDictType, @Param("newDictType") String newDictType);
|
||||
}
|
@ -0,0 +1,85 @@
|
||||
package com.ruoyi.system.mapper;
|
||||
|
||||
import java.util.List;
|
||||
import org.apache.ibatis.annotations.Mapper;
|
||||
import com.ruoyi.common.core.domain.entity.SysDictType;
|
||||
|
||||
/**
|
||||
* 字典表 数据层
|
||||
*
|
||||
* @author ruoyi
|
||||
*/
|
||||
@Mapper
|
||||
public interface SysDictTypeMapper
|
||||
{
|
||||
/**
|
||||
* 根据条件分页查询字典类型
|
||||
*
|
||||
* @param dictType 字典类型信息
|
||||
* @return 字典类型集合信息
|
||||
*/
|
||||
public List<SysDictType> selectDictTypeList(SysDictType dictType);
|
||||
|
||||
/**
|
||||
* 根据所有字典类型
|
||||
*
|
||||
* @return 字典类型集合信息
|
||||
*/
|
||||
public List<SysDictType> selectDictTypeAll();
|
||||
|
||||
/**
|
||||
* 根据字典类型ID查询信息
|
||||
*
|
||||
* @param dictId 字典类型ID
|
||||
* @return 字典类型
|
||||
*/
|
||||
public SysDictType selectDictTypeById(Long dictId);
|
||||
|
||||
/**
|
||||
* 根据字典类型查询信息
|
||||
*
|
||||
* @param dictType 字典类型
|
||||
* @return 字典类型
|
||||
*/
|
||||
public SysDictType selectDictTypeByType(String dictType);
|
||||
|
||||
/**
|
||||
* 通过字典ID删除字典信息
|
||||
*
|
||||
* @param dictId 字典ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteDictTypeById(Long dictId);
|
||||
|
||||
/**
|
||||
* 批量删除字典类型信息
|
||||
*
|
||||
* @param dictIds 需要删除的字典ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteDictTypeByIds(Long[] dictIds);
|
||||
|
||||
/**
|
||||
* 新增字典类型信息
|
||||
*
|
||||
* @param dictType 字典类型信息
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertDictType(SysDictType dictType);
|
||||
|
||||
/**
|
||||
* 修改字典类型信息
|
||||
*
|
||||
* @param dictType 字典类型信息
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateDictType(SysDictType dictType);
|
||||
|
||||
/**
|
||||
* 校验字典类型称是否唯一
|
||||
*
|
||||
* @param dictType 字典类型
|
||||
* @return 结果
|
||||
*/
|
||||
public SysDictType checkDictTypeUnique(String dictType);
|
||||
}
|
@ -0,0 +1,42 @@
|
||||
package com.ruoyi.system.mapper;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.system.domain.SysLogininfor;
|
||||
|
||||
/**
|
||||
* 系统访问日志情况信息 数据层
|
||||
*
|
||||
* @author ruoyi
|
||||
*/
|
||||
public interface SysLogininforMapper
|
||||
{
|
||||
/**
|
||||
* 新增系统登录日志
|
||||
*
|
||||
* @param logininfor 访问日志对象
|
||||
*/
|
||||
public void insertLogininfor(SysLogininfor logininfor);
|
||||
|
||||
/**
|
||||
* 查询系统登录日志集合
|
||||
*
|
||||
* @param logininfor 访问日志对象
|
||||
* @return 登录记录集合
|
||||
*/
|
||||
public List<SysLogininfor> selectLogininforList(SysLogininfor logininfor);
|
||||
|
||||
/**
|
||||
* 批量删除系统登录日志
|
||||
*
|
||||
* @param infoIds 需要删除的登录日志ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteLogininforByIds(Long[] infoIds);
|
||||
|
||||
/**
|
||||
* 清空系统登录日志
|
||||
*
|
||||
* @return 结果
|
||||
*/
|
||||
public int cleanLogininfor();
|
||||
}
|
@ -0,0 +1,117 @@
|
||||
package com.ruoyi.system.mapper;
|
||||
|
||||
import java.util.List;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
import com.ruoyi.common.core.domain.entity.SysMenu;
|
||||
|
||||
/**
|
||||
* 菜单表 数据层
|
||||
*
|
||||
* @author ruoyi
|
||||
*/
|
||||
public interface SysMenuMapper
|
||||
{
|
||||
/**
|
||||
* 查询系统菜单列表
|
||||
*
|
||||
* @param menu 菜单信息
|
||||
* @return 菜单列表
|
||||
*/
|
||||
public List<SysMenu> selectMenuList(SysMenu menu);
|
||||
|
||||
/**
|
||||
* 根据用户所有权限
|
||||
*
|
||||
* @return 权限列表
|
||||
*/
|
||||
public List<String> selectMenuPerms();
|
||||
|
||||
/**
|
||||
* 根据用户查询系统菜单列表
|
||||
*
|
||||
* @param menu 菜单信息
|
||||
* @return 菜单列表
|
||||
*/
|
||||
public List<SysMenu> selectMenuListByUserId(SysMenu menu);
|
||||
|
||||
/**
|
||||
* 根据用户ID查询权限
|
||||
*
|
||||
* @param userId 用户ID
|
||||
* @return 权限列表
|
||||
*/
|
||||
public List<String> selectMenuPermsByUserId(Long userId);
|
||||
|
||||
/**
|
||||
* 根据用户ID查询菜单
|
||||
*
|
||||
* @return 菜单列表
|
||||
*/
|
||||
public List<SysMenu> selectMenuTreeAll();
|
||||
|
||||
/**
|
||||
* 根据用户ID查询菜单
|
||||
*
|
||||
* @param userId 用户ID
|
||||
* @return 菜单列表
|
||||
*/
|
||||
public List<SysMenu> selectMenuTreeByUserId(Long userId);
|
||||
|
||||
/**
|
||||
* 根据角色ID查询菜单树信息
|
||||
*
|
||||
* @param roleId 角色ID
|
||||
* @param menuCheckStrictly 菜单树选择项是否关联显示
|
||||
* @return 选中菜单列表
|
||||
*/
|
||||
public List<Long> selectMenuListByRoleId(@Param("roleId") Long roleId, @Param("menuCheckStrictly") boolean menuCheckStrictly);
|
||||
|
||||
/**
|
||||
* 根据菜单ID查询信息
|
||||
*
|
||||
* @param menuId 菜单ID
|
||||
* @return 菜单信息
|
||||
*/
|
||||
public SysMenu selectMenuById(Long menuId);
|
||||
|
||||
/**
|
||||
* 是否存在菜单子节点
|
||||
*
|
||||
* @param menuId 菜单ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int hasChildByMenuId(Long menuId);
|
||||
|
||||
/**
|
||||
* 新增菜单信息
|
||||
*
|
||||
* @param menu 菜单信息
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertMenu(SysMenu menu);
|
||||
|
||||
/**
|
||||
* 修改菜单信息
|
||||
*
|
||||
* @param menu 菜单信息
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateMenu(SysMenu menu);
|
||||
|
||||
/**
|
||||
* 删除菜单管理信息
|
||||
*
|
||||
* @param menuId 菜单ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteMenuById(Long menuId);
|
||||
|
||||
/**
|
||||
* 校验菜单名称是否唯一
|
||||
*
|
||||
* @param menuName 菜单名称
|
||||
* @param parentId 父菜单ID
|
||||
* @return 结果
|
||||
*/
|
||||
public SysMenu checkMenuNameUnique(@Param("menuName") String menuName, @Param("parentId") Long parentId);
|
||||
}
|
@ -0,0 +1,60 @@
|
||||
package com.ruoyi.system.mapper;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.system.domain.SysNotice;
|
||||
|
||||
/**
|
||||
* 通知公告表 数据层
|
||||
*
|
||||
* @author ruoyi
|
||||
*/
|
||||
public interface SysNoticeMapper
|
||||
{
|
||||
/**
|
||||
* 查询公告信息
|
||||
*
|
||||
* @param noticeId 公告ID
|
||||
* @return 公告信息
|
||||
*/
|
||||
public SysNotice selectNoticeById(Long noticeId);
|
||||
|
||||
/**
|
||||
* 查询公告列表
|
||||
*
|
||||
* @param notice 公告信息
|
||||
* @return 公告集合
|
||||
*/
|
||||
public List<SysNotice> selectNoticeList(SysNotice notice);
|
||||
|
||||
/**
|
||||
* 新增公告
|
||||
*
|
||||
* @param notice 公告信息
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertNotice(SysNotice notice);
|
||||
|
||||
/**
|
||||
* 修改公告
|
||||
*
|
||||
* @param notice 公告信息
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateNotice(SysNotice notice);
|
||||
|
||||
/**
|
||||
* 批量删除公告
|
||||
*
|
||||
* @param noticeId 公告ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteNoticeById(Long noticeId);
|
||||
|
||||
/**
|
||||
* 批量删除公告信息
|
||||
*
|
||||
* @param noticeIds 需要删除的公告ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteNoticeByIds(Long[] noticeIds);
|
||||
}
|
@ -0,0 +1,48 @@
|
||||
package com.ruoyi.system.mapper;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.system.domain.SysOperLog;
|
||||
|
||||
/**
|
||||
* 操作日志 数据层
|
||||
*
|
||||
* @author ruoyi
|
||||
*/
|
||||
public interface SysOperLogMapper
|
||||
{
|
||||
/**
|
||||
* 新增操作日志
|
||||
*
|
||||
* @param operLog 操作日志对象
|
||||
*/
|
||||
public void insertOperlog(SysOperLog operLog);
|
||||
|
||||
/**
|
||||
* 查询系统操作日志集合
|
||||
*
|
||||
* @param operLog 操作日志对象
|
||||
* @return 操作日志集合
|
||||
*/
|
||||
public List<SysOperLog> selectOperLogList(SysOperLog operLog);
|
||||
|
||||
/**
|
||||
* 批量删除系统操作日志
|
||||
*
|
||||
* @param operIds 需要删除的操作日志ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteOperLogByIds(Long[] operIds);
|
||||
|
||||
/**
|
||||
* 查询操作日志详细
|
||||
*
|
||||
* @param operId 操作ID
|
||||
* @return 操作日志对象
|
||||
*/
|
||||
public SysOperLog selectOperLogById(Long operId);
|
||||
|
||||
/**
|
||||
* 清空操作日志
|
||||
*/
|
||||
public void cleanOperLog();
|
||||
}
|
@ -0,0 +1,99 @@
|
||||
package com.ruoyi.system.mapper;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.system.domain.SysPost;
|
||||
|
||||
/**
|
||||
* 岗位信息 数据层
|
||||
*
|
||||
* @author ruoyi
|
||||
*/
|
||||
public interface SysPostMapper
|
||||
{
|
||||
/**
|
||||
* 查询岗位数据集合
|
||||
*
|
||||
* @param post 岗位信息
|
||||
* @return 岗位数据集合
|
||||
*/
|
||||
public List<SysPost> selectPostList(SysPost post);
|
||||
|
||||
/**
|
||||
* 查询所有岗位
|
||||
*
|
||||
* @return 岗位列表
|
||||
*/
|
||||
public List<SysPost> selectPostAll();
|
||||
|
||||
/**
|
||||
* 通过岗位ID查询岗位信息
|
||||
*
|
||||
* @param postId 岗位ID
|
||||
* @return 角色对象信息
|
||||
*/
|
||||
public SysPost selectPostById(Long postId);
|
||||
|
||||
/**
|
||||
* 根据用户ID获取岗位选择框列表
|
||||
*
|
||||
* @param userId 用户ID
|
||||
* @return 选中岗位ID列表
|
||||
*/
|
||||
public List<Long> selectPostListByUserId(Long userId);
|
||||
|
||||
/**
|
||||
* 查询用户所属岗位组
|
||||
*
|
||||
* @param userName 用户名
|
||||
* @return 结果
|
||||
*/
|
||||
public List<SysPost> selectPostsByUserName(String userName);
|
||||
|
||||
/**
|
||||
* 删除岗位信息
|
||||
*
|
||||
* @param postId 岗位ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deletePostById(Long postId);
|
||||
|
||||
/**
|
||||
* 批量删除岗位信息
|
||||
*
|
||||
* @param postIds 需要删除的岗位ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deletePostByIds(Long[] postIds);
|
||||
|
||||
/**
|
||||
* 修改岗位信息
|
||||
*
|
||||
* @param post 岗位信息
|
||||
* @return 结果
|
||||
*/
|
||||
public int updatePost(SysPost post);
|
||||
|
||||
/**
|
||||
* 新增岗位信息
|
||||
*
|
||||
* @param post 岗位信息
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertPost(SysPost post);
|
||||
|
||||
/**
|
||||
* 校验岗位名称
|
||||
*
|
||||
* @param postName 岗位名称
|
||||
* @return 结果
|
||||
*/
|
||||
public SysPost checkPostNameUnique(String postName);
|
||||
|
||||
/**
|
||||
* 校验岗位编码
|
||||
*
|
||||
* @param postCode 岗位编码
|
||||
* @return 结果
|
||||
*/
|
||||
public SysPost checkPostCodeUnique(String postCode);
|
||||
}
|
@ -0,0 +1,44 @@
|
||||
package com.ruoyi.system.mapper;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.system.domain.SysRoleDept;
|
||||
|
||||
/**
|
||||
* 角色与部门关联表 数据层
|
||||
*
|
||||
* @author ruoyi
|
||||
*/
|
||||
public interface SysRoleDeptMapper
|
||||
{
|
||||
/**
|
||||
* 通过角色ID删除角色和部门关联
|
||||
*
|
||||
* @param roleId 角色ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteRoleDeptByRoleId(Long roleId);
|
||||
|
||||
/**
|
||||
* 批量删除角色部门关联信息
|
||||
*
|
||||
* @param ids 需要删除的数据ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteRoleDept(Long[] ids);
|
||||
|
||||
/**
|
||||
* 查询部门使用数量
|
||||
*
|
||||
* @param deptId 部门ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int selectCountRoleDeptByDeptId(Long deptId);
|
||||
|
||||
/**
|
||||
* 批量新增角色部门信息
|
||||
*
|
||||
* @param roleDeptList 角色部门列表
|
||||
* @return 结果
|
||||
*/
|
||||
public int batchRoleDept(List<SysRoleDept> roleDeptList);
|
||||
}
|
@ -0,0 +1,107 @@
|
||||
package com.ruoyi.system.mapper;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.common.core.domain.entity.SysRole;
|
||||
|
||||
/**
|
||||
* 角色表 数据层
|
||||
*
|
||||
* @author ruoyi
|
||||
*/
|
||||
public interface SysRoleMapper
|
||||
{
|
||||
/**
|
||||
* 根据条件分页查询角色数据
|
||||
*
|
||||
* @param role 角色信息
|
||||
* @return 角色数据集合信息
|
||||
*/
|
||||
public List<SysRole> selectRoleList(SysRole role);
|
||||
|
||||
/**
|
||||
* 根据用户ID查询角色
|
||||
*
|
||||
* @param userId 用户ID
|
||||
* @return 角色列表
|
||||
*/
|
||||
public List<SysRole> selectRolePermissionByUserId(Long userId);
|
||||
|
||||
/**
|
||||
* 查询所有角色
|
||||
*
|
||||
* @return 角色列表
|
||||
*/
|
||||
public List<SysRole> selectRoleAll();
|
||||
|
||||
/**
|
||||
* 根据用户ID获取角色选择框列表
|
||||
*
|
||||
* @param userId 用户ID
|
||||
* @return 选中角色ID列表
|
||||
*/
|
||||
public List<Long> selectRoleListByUserId(Long userId);
|
||||
|
||||
/**
|
||||
* 通过角色ID查询角色
|
||||
*
|
||||
* @param roleId 角色ID
|
||||
* @return 角色对象信息
|
||||
*/
|
||||
public SysRole selectRoleById(Long roleId);
|
||||
|
||||
/**
|
||||
* 根据用户ID查询角色
|
||||
*
|
||||
* @param userName 用户名
|
||||
* @return 角色列表
|
||||
*/
|
||||
public List<SysRole> selectRolesByUserName(String userName);
|
||||
|
||||
/**
|
||||
* 校验角色名称是否唯一
|
||||
*
|
||||
* @param roleName 角色名称
|
||||
* @return 角色信息
|
||||
*/
|
||||
public SysRole checkRoleNameUnique(String roleName);
|
||||
|
||||
/**
|
||||
* 校验角色权限是否唯一
|
||||
*
|
||||
* @param roleKey 角色权限
|
||||
* @return 角色信息
|
||||
*/
|
||||
public SysRole checkRoleKeyUnique(String roleKey);
|
||||
|
||||
/**
|
||||
* 修改角色信息
|
||||
*
|
||||
* @param role 角色信息
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateRole(SysRole role);
|
||||
|
||||
/**
|
||||
* 新增角色信息
|
||||
*
|
||||
* @param role 角色信息
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertRole(SysRole role);
|
||||
|
||||
/**
|
||||
* 通过角色ID删除角色
|
||||
*
|
||||
* @param roleId 角色ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteRoleById(Long roleId);
|
||||
|
||||
/**
|
||||
* 批量删除角色信息
|
||||
*
|
||||
* @param roleIds 需要删除的角色ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteRoleByIds(Long[] roleIds);
|
||||
}
|
@ -0,0 +1,44 @@
|
||||
package com.ruoyi.system.mapper;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.system.domain.SysRoleMenu;
|
||||
|
||||
/**
|
||||
* 角色与菜单关联表 数据层
|
||||
*
|
||||
* @author ruoyi
|
||||
*/
|
||||
public interface SysRoleMenuMapper
|
||||
{
|
||||
/**
|
||||
* 查询菜单使用数量
|
||||
*
|
||||
* @param menuId 菜单ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int checkMenuExistRole(Long menuId);
|
||||
|
||||
/**
|
||||
* 通过角色ID删除角色和菜单关联
|
||||
*
|
||||
* @param roleId 角色ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteRoleMenuByRoleId(Long roleId);
|
||||
|
||||
/**
|
||||
* 批量删除角色菜单关联信息
|
||||
*
|
||||
* @param ids 需要删除的数据ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteRoleMenu(Long[] ids);
|
||||
|
||||
/**
|
||||
* 批量新增角色菜单信息
|
||||
*
|
||||
* @param roleMenuList 角色菜单列表
|
||||
* @return 结果
|
||||
*/
|
||||
public int batchRoleMenu(List<SysRoleMenu> roleMenuList);
|
||||
}
|
@ -0,0 +1,127 @@
|
||||
package com.ruoyi.system.mapper;
|
||||
|
||||
import java.util.List;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
import com.ruoyi.common.core.domain.entity.SysUser;
|
||||
|
||||
/**
|
||||
* 用户表 数据层
|
||||
*
|
||||
* @author ruoyi
|
||||
*/
|
||||
public interface SysUserMapper
|
||||
{
|
||||
/**
|
||||
* 根据条件分页查询用户列表
|
||||
*
|
||||
* @param sysUser 用户信息
|
||||
* @return 用户信息集合信息
|
||||
*/
|
||||
public List<SysUser> selectUserList(SysUser sysUser);
|
||||
|
||||
/**
|
||||
* 根据条件分页查询已配用户角色列表
|
||||
*
|
||||
* @param user 用户信息
|
||||
* @return 用户信息集合信息
|
||||
*/
|
||||
public List<SysUser> selectAllocatedList(SysUser user);
|
||||
|
||||
/**
|
||||
* 根据条件分页查询未分配用户角色列表
|
||||
*
|
||||
* @param user 用户信息
|
||||
* @return 用户信息集合信息
|
||||
*/
|
||||
public List<SysUser> selectUnallocatedList(SysUser user);
|
||||
|
||||
/**
|
||||
* 通过用户名查询用户
|
||||
*
|
||||
* @param userName 用户名
|
||||
* @return 用户对象信息
|
||||
*/
|
||||
public SysUser selectUserByUserName(String userName);
|
||||
|
||||
/**
|
||||
* 通过用户ID查询用户
|
||||
*
|
||||
* @param userId 用户ID
|
||||
* @return 用户对象信息
|
||||
*/
|
||||
public SysUser selectUserById(Long userId);
|
||||
|
||||
/**
|
||||
* 新增用户信息
|
||||
*
|
||||
* @param user 用户信息
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertUser(SysUser user);
|
||||
|
||||
/**
|
||||
* 修改用户信息
|
||||
*
|
||||
* @param user 用户信息
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateUser(SysUser user);
|
||||
|
||||
/**
|
||||
* 修改用户头像
|
||||
*
|
||||
* @param userName 用户名
|
||||
* @param avatar 头像地址
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateUserAvatar(@Param("userName") String userName, @Param("avatar") String avatar);
|
||||
|
||||
/**
|
||||
* 重置用户密码
|
||||
*
|
||||
* @param userName 用户名
|
||||
* @param password 密码
|
||||
* @return 结果
|
||||
*/
|
||||
public int resetUserPwd(@Param("userName") String userName, @Param("password") String password);
|
||||
|
||||
/**
|
||||
* 通过用户ID删除用户
|
||||
*
|
||||
* @param userId 用户ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteUserById(Long userId);
|
||||
|
||||
/**
|
||||
* 批量删除用户信息
|
||||
*
|
||||
* @param userIds 需要删除的用户ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteUserByIds(Long[] userIds);
|
||||
|
||||
/**
|
||||
* 校验用户名称是否唯一
|
||||
*
|
||||
* @param userName 用户名称
|
||||
* @return 结果
|
||||
*/
|
||||
public int checkUserNameUnique(String userName);
|
||||
|
||||
/**
|
||||
* 校验手机号码是否唯一
|
||||
*
|
||||
* @param phonenumber 手机号码
|
||||
* @return 结果
|
||||
*/
|
||||
public SysUser checkPhoneUnique(String phonenumber);
|
||||
|
||||
/**
|
||||
* 校验email是否唯一
|
||||
*
|
||||
* @param email 用户邮箱
|
||||
* @return 结果
|
||||
*/
|
||||
public SysUser checkEmailUnique(String email);
|
||||
}
|
@ -0,0 +1,44 @@
|
||||
package com.ruoyi.system.mapper;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.system.domain.SysUserPost;
|
||||
|
||||
/**
|
||||
* 用户与岗位关联表 数据层
|
||||
*
|
||||
* @author ruoyi
|
||||
*/
|
||||
public interface SysUserPostMapper
|
||||
{
|
||||
/**
|
||||
* 通过用户ID删除用户和岗位关联
|
||||
*
|
||||
* @param userId 用户ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteUserPostByUserId(Long userId);
|
||||
|
||||
/**
|
||||
* 通过岗位ID查询岗位使用数量
|
||||
*
|
||||
* @param postId 岗位ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int countUserPostById(Long postId);
|
||||
|
||||
/**
|
||||
* 批量删除用户和岗位关联
|
||||
*
|
||||
* @param ids 需要删除的数据ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteUserPost(Long[] ids);
|
||||
|
||||
/**
|
||||
* 批量新增用户岗位信息
|
||||
*
|
||||
* @param userPostList 用户角色列表
|
||||
* @return 结果
|
||||
*/
|
||||
public int batchUserPost(List<SysUserPost> userPostList);
|
||||
}
|
@ -0,0 +1,62 @@
|
||||
package com.ruoyi.system.mapper;
|
||||
|
||||
import java.util.List;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
import com.ruoyi.system.domain.SysUserRole;
|
||||
|
||||
/**
|
||||
* 用户与角色关联表 数据层
|
||||
*
|
||||
* @author ruoyi
|
||||
*/
|
||||
public interface SysUserRoleMapper
|
||||
{
|
||||
/**
|
||||
* 通过用户ID删除用户和角色关联
|
||||
*
|
||||
* @param userId 用户ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteUserRoleByUserId(Long userId);
|
||||
|
||||
/**
|
||||
* 批量删除用户和角色关联
|
||||
*
|
||||
* @param ids 需要删除的数据ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteUserRole(Long[] ids);
|
||||
|
||||
/**
|
||||
* 通过角色ID查询角色使用数量
|
||||
*
|
||||
* @param roleId 角色ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int countUserRoleByRoleId(Long roleId);
|
||||
|
||||
/**
|
||||
* 批量新增用户角色信息
|
||||
*
|
||||
* @param userRoleList 用户角色列表
|
||||
* @return 结果
|
||||
*/
|
||||
public int batchUserRole(List<SysUserRole> userRoleList);
|
||||
|
||||
/**
|
||||
* 删除用户和角色关联信息
|
||||
*
|
||||
* @param userRole 用户和角色关联信息
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteUserRoleInfo(SysUserRole userRole);
|
||||
|
||||
/**
|
||||
* 批量取消授权用户角色
|
||||
*
|
||||
* @param roleId 角色ID
|
||||
* @param userIds 需要删除的用户数据ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteUserRoleInfos(@Param("roleId") Long roleId, @Param("userIds") Long[] userIds);
|
||||
}
|
@ -0,0 +1,22 @@
|
||||
package com.ruoyi.system.mapper_shate;
|
||||
|
||||
import com.ruoyi.system.domain_shate.AustraliaMiddleEastVO;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 澳大利亚中东部地区
|
||||
* @Author: JinSheng Song
|
||||
* @Date: 2022/5/11 15:17
|
||||
*/
|
||||
public interface AustraliaMiddleEastMapper {
|
||||
|
||||
List<AustraliaMiddleEastVO> selectAustralia(@Param("yearMonth") String yearMonth,
|
||||
@Param("month") String month);
|
||||
|
||||
Integer DelAustralia(@Param("id") String id);
|
||||
|
||||
Integer IntoAustralia(AustraliaMiddleEastVO eastVO);
|
||||
}
|
@ -0,0 +1,92 @@
|
||||
package com.ruoyi.system.mapper_shate;
|
||||
|
||||
import com.ruoyi.system.domain_shate.DateUpload;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
|
||||
import java.time.LocalDate;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @Author: JinSheng Song
|
||||
* @Date: 2022/7/11 15:40
|
||||
*/
|
||||
public interface DateUploadMapper {
|
||||
|
||||
Integer altitude(@Param("zone") String zone,
|
||||
@Param("imageDate") String imageDate);
|
||||
|
||||
Integer aspect(@Param("zone") String zone,
|
||||
@Param("imageDate") String imageDate);
|
||||
|
||||
Integer landuse(@Param("zone") String zone,
|
||||
@Param("imageDate") String imageDate);
|
||||
|
||||
Integer suitability(@Param("zone") String zone,
|
||||
@Param("imageDate") String imageDate);
|
||||
|
||||
Integer road(@Param("zone") String zone,
|
||||
@Param("imageDate") String imageDate);
|
||||
|
||||
Integer seedSuccess(@Param("zone") String zone,
|
||||
@Param("imageDate") String imageDate);
|
||||
|
||||
Integer vegetationDistribution(@Param("zone") String zone,
|
||||
@Param("imageDate") String imageDate);
|
||||
|
||||
Integer slope(@Param("zone") String zone,
|
||||
@Param("imageDate") String imageDate);
|
||||
|
||||
Integer desertification(@Param("zone") String zone,
|
||||
@Param("imageDate") String imageDate);
|
||||
|
||||
Integer moisture(@Param("zone") String zone,
|
||||
@Param("imageDate") String imageDate);
|
||||
|
||||
Integer salinization(@Param("zone") String zone,
|
||||
@Param("imageDate") String imageDate);
|
||||
|
||||
Integer healthy(@Param("zone") String zone,
|
||||
@Param("imageDate") String imageDate,
|
||||
@Param("resolution") String resolution);
|
||||
|
||||
Integer water(@Param("zone") String zone,
|
||||
@Param("imageDate") String imageDate);
|
||||
|
||||
Integer waterArea(@Param("zone") String zone,
|
||||
@Param("imageDate") String imageDate);
|
||||
|
||||
Integer roadLength(@Param("zone") String zone,
|
||||
@Param("imageDate") String imageDate);
|
||||
|
||||
Integer climateIndex(@Param("zone") String zone,
|
||||
@Param("imageDate") String imageDate);
|
||||
|
||||
List<DateUpload> selectUpload(@Param("zone") String zone,
|
||||
@Param("type") String type,
|
||||
@Param("type1") String type1,
|
||||
@Param("type2") String type2,
|
||||
@Param("year") String year,
|
||||
@Param("dateWithSway") String dateWithSway,
|
||||
@Param("name") String name,
|
||||
@Param("dateTime") String dateTime);
|
||||
|
||||
DateUpload selectShpfile(@Param("zone") String zone,
|
||||
@Param("type") String type,
|
||||
@Param("dateTime") String dateTime,
|
||||
@Param("year") String year);
|
||||
|
||||
DateUpload selectShp(@Param("zone") String zone,
|
||||
@Param("type") String type,
|
||||
@Param("dateTime") String dateTime);
|
||||
|
||||
|
||||
Integer DelUpload(@Param("id") Integer id);
|
||||
|
||||
DateUpload selectDel(@Param("id") Integer id);
|
||||
|
||||
Integer DelShp(@Param("id") Integer id);
|
||||
|
||||
Integer IntoUpload(DateUpload upload);
|
||||
|
||||
Integer IntoShp(DateUpload upload);
|
||||
}
|
@ -0,0 +1,27 @@
|
||||
package com.ruoyi.system.mapper_shate;
|
||||
|
||||
import com.ruoyi.system.domain_shate.LandUse;
|
||||
import com.ruoyi.system.domain_shate.VegetationHealth;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Set;
|
||||
|
||||
/**
|
||||
* @Author: JinSheng Song
|
||||
* @Date: 2022/7/8 11:19
|
||||
*/
|
||||
|
||||
public interface LandUseMapper {
|
||||
|
||||
List<LandUse> sqlSeeding(@Param("zone") String zone,
|
||||
@Param("landUses") String[]landUses,
|
||||
@Param("year") String year);
|
||||
|
||||
List<LandUse> sqlSeeding1(@Param("zone") String zone,
|
||||
@Param("year") String year);
|
||||
|
||||
List<LandUse> sqlYear();
|
||||
|
||||
Integer insertSeeding(LandUse use);
|
||||
}
|
@ -0,0 +1,21 @@
|
||||
package com.ruoyi.system.mapper_shate;
|
||||
|
||||
import com.ruoyi.system.domain_shate.LandUse;
|
||||
import com.ruoyi.system.domain_shate.PlantingSuitability;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @Author: JinSheng Song
|
||||
* @Date: 2022/7/8 11:27
|
||||
*/
|
||||
public interface PlantingSuitabilityMapper
|
||||
{
|
||||
List<PlantingSuitability> sqlSeeding(@Param("zone") String zone);
|
||||
|
||||
Integer InsertSeeding(PlantingSuitability suitability);
|
||||
|
||||
List<PlantingSuitability> sqlYear();
|
||||
|
||||
}
|
@ -0,0 +1,39 @@
|
||||
package com.ruoyi.system.mapper_shate;
|
||||
|
||||
import com.ruoyi.system.domain_shate.*;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
import org.hibernate.validator.constraints.NotBlank;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @Author: JinSheng Song
|
||||
* @Date: 2022/7/8 11:22
|
||||
*/
|
||||
public interface RegionalFactorMapper {
|
||||
|
||||
List<WaterFactor> sqlWater(@Param("zone") String zone,
|
||||
@Param("year") String year);
|
||||
|
||||
List<WaterFactor> sqlYear();
|
||||
|
||||
List<RegionIndex> sqlRegion(@Param("zone") String zone,
|
||||
@Param("year") String year);
|
||||
|
||||
List<RegionIndex> sqlYear1();
|
||||
|
||||
List<RoadFactor> sqlRoad(@Param("zone") String zone,
|
||||
@Param("year") String year);
|
||||
|
||||
List<RoadFactor> sqlYear2();
|
||||
|
||||
List<Climate> sqlClimate(@Param("zone") String zone);
|
||||
|
||||
Integer InsertWater(WaterFactor factor);
|
||||
|
||||
Integer InsertWaterArea(RegionIndex index);
|
||||
|
||||
Integer InsertRoadLength(RegionIndex index);
|
||||
|
||||
Integer InsertRoad(RoadFactor factor);
|
||||
}
|
@ -0,0 +1,27 @@
|
||||
package com.ruoyi.system.mapper_shate;
|
||||
|
||||
import com.ruoyi.system.domain_shate.AustraliaMiddleEastVO;
|
||||
import com.ruoyi.system.domain_shate.SeedingSuccessRate;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @Author: JinSheng Song
|
||||
* @Date: 2022/7/8 9:43
|
||||
*/
|
||||
public interface SeedingSuccessMapper
|
||||
{
|
||||
List<SeedingSuccessRate> sqlSeeding(@Param("zone") String zone,
|
||||
@Param("year") String year);
|
||||
|
||||
Integer InsertSeeding1(SeedingSuccessRate eastVO);
|
||||
|
||||
Integer InsertSeeding2(SeedingSuccessRate eastVO);
|
||||
|
||||
List<SeedingSuccessRate> sqlYear();
|
||||
|
||||
Integer Delete(@Param("name") String name,
|
||||
@Param("zone") String zone,
|
||||
@Param("zone") String imageDate);
|
||||
}
|
@ -0,0 +1,34 @@
|
||||
package com.ruoyi.system.mapper_shate;
|
||||
|
||||
import com.ruoyi.system.domain_shate.*;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @Author: JinSheng Song
|
||||
* @Date: 2022/7/8 11:24
|
||||
*/
|
||||
public interface SoilFactorMapper {
|
||||
|
||||
List<SoilDesertification> sqlDesert(@Param("zone") String zone,
|
||||
@Param("year") String year);
|
||||
|
||||
List<SoilDesertification> sqlYear();
|
||||
|
||||
List<SoilMoisture> sqlMoisture(@Param("zone") String zone,
|
||||
@Param("year") String year);
|
||||
|
||||
List<SoilMoisture> sqlYear1();
|
||||
|
||||
List<SoilSalinization> sqlSalin(@Param("zone") String zone,
|
||||
@Param("year") String year);
|
||||
|
||||
List<SoilSalinization> sqlYear2();
|
||||
|
||||
Integer InsertSalin(SoilSalinization soil);
|
||||
|
||||
Integer InsertDesert(SoilDesertification desertification);
|
||||
|
||||
Integer InsertMoisture(SoilMoisture moisture);
|
||||
}
|
@ -0,0 +1,34 @@
|
||||
package com.ruoyi.system.mapper_shate;
|
||||
|
||||
import com.ruoyi.system.domain_shate.*;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @Author: JinSheng Song
|
||||
* @Date: 2022/7/8 11:30
|
||||
*/
|
||||
public interface TopographicFactorMapper
|
||||
{
|
||||
List<Altitude> sqlAltitude(@Param("zone") String zone,
|
||||
@Param("year") String year);
|
||||
|
||||
List<Altitude> sqlYear();
|
||||
|
||||
List<Slope> sqlSlope(@Param("zone") String zone,
|
||||
@Param("year") String year);
|
||||
|
||||
List<Slope> sqlYear1();
|
||||
|
||||
List<Aspect> sqlAspect(@Param("zone") String zone,
|
||||
@Param("year") String year);
|
||||
|
||||
List<Aspect> sqlYear2();
|
||||
|
||||
Integer InsertSlope(Slope slope);
|
||||
|
||||
Integer InsertAltitude(Altitude altitude);
|
||||
|
||||
Integer InsertAspect(Aspect aspect);
|
||||
}
|
@ -0,0 +1,24 @@
|
||||
package com.ruoyi.system.mapper_shate;
|
||||
|
||||
import com.ruoyi.system.domain_shate.Altitude;
|
||||
import com.ruoyi.system.domain_shate.SeedingSuccessRate;
|
||||
import com.ruoyi.system.domain_shate.VegetationHealth;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @Author: JinSheng Song
|
||||
* @Date: 2022/7/8 10:51
|
||||
*/
|
||||
public interface VegetationHealthMapper
|
||||
{
|
||||
|
||||
List<VegetationHealth> sqlSeeding(@Param("zone") String zone,
|
||||
@Param("name") String name,
|
||||
@Param("year") String year);
|
||||
|
||||
List<VegetationHealth> sqlYear();
|
||||
|
||||
Integer insertSeeding(VegetationHealth health);
|
||||
}
|
@ -0,0 +1,92 @@
|
||||
package com.ruoyi.system.service;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.system.domain.SysConfig;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
/**
|
||||
* 参数配置 服务层
|
||||
*
|
||||
* @author ruoyi
|
||||
*/
|
||||
|
||||
|
||||
public interface ISysConfigService
|
||||
{
|
||||
/**
|
||||
* 查询参数配置信息
|
||||
*
|
||||
* @param configId 参数配置ID
|
||||
* @return 参数配置信息
|
||||
*/
|
||||
public SysConfig selectConfigById(Long configId);
|
||||
|
||||
/**
|
||||
* 根据键名查询参数配置信息
|
||||
*
|
||||
* @param configKey 参数键名
|
||||
* @return 参数键值
|
||||
*/
|
||||
public String selectConfigByKey(String configKey);
|
||||
|
||||
/**
|
||||
* 获取验证码开关
|
||||
*
|
||||
* @return true开启,false关闭
|
||||
*/
|
||||
public boolean selectCaptchaOnOff();
|
||||
|
||||
/**
|
||||
* 查询参数配置列表
|
||||
*
|
||||
* @param config 参数配置信息
|
||||
* @return 参数配置集合
|
||||
*/
|
||||
public List<SysConfig> selectConfigList(SysConfig config);
|
||||
|
||||
/**
|
||||
* 新增参数配置
|
||||
*
|
||||
* @param config 参数配置信息
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertConfig(SysConfig config);
|
||||
|
||||
/**
|
||||
* 修改参数配置
|
||||
*
|
||||
* @param config 参数配置信息
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateConfig(SysConfig config);
|
||||
|
||||
/**
|
||||
* 批量删除参数信息
|
||||
*
|
||||
* @param configIds 需要删除的参数ID
|
||||
*/
|
||||
public void deleteConfigByIds(Long[] configIds);
|
||||
|
||||
/**
|
||||
* 加载参数缓存数据
|
||||
*/
|
||||
public void loadingConfigCache();
|
||||
|
||||
/**
|
||||
* 清空参数缓存数据
|
||||
*/
|
||||
public void clearConfigCache();
|
||||
|
||||
/**
|
||||
* 重置参数缓存数据
|
||||
*/
|
||||
public void resetConfigCache();
|
||||
|
||||
/**
|
||||
* 校验参数键名是否唯一
|
||||
*
|
||||
* @param config 参数信息
|
||||
* @return 结果
|
||||
*/
|
||||
public String checkConfigKeyUnique(SysConfig config);
|
||||
}
|
@ -0,0 +1,116 @@
|
||||
package com.ruoyi.system.service;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.common.core.domain.TreeSelect;
|
||||
import com.ruoyi.common.core.domain.entity.SysDept;
|
||||
|
||||
/**
|
||||
* 部门管理 服务层
|
||||
*
|
||||
* @author ruoyi
|
||||
*/
|
||||
public interface ISysDeptService
|
||||
{
|
||||
/**
|
||||
* 查询部门管理数据
|
||||
*
|
||||
* @param dept 部门信息
|
||||
* @return 部门信息集合
|
||||
*/
|
||||
public List<SysDept> selectDeptList(SysDept dept);
|
||||
|
||||
/**
|
||||
* 构建前端所需要树结构
|
||||
*
|
||||
* @param depts 部门列表
|
||||
* @return 树结构列表
|
||||
*/
|
||||
public List<SysDept> buildDeptTree(List<SysDept> depts);
|
||||
|
||||
/**
|
||||
* 构建前端所需要下拉树结构
|
||||
*
|
||||
* @param depts 部门列表
|
||||
* @return 下拉树结构列表
|
||||
*/
|
||||
public List<TreeSelect> buildDeptTreeSelect(List<SysDept> depts);
|
||||
|
||||
/**
|
||||
* 根据角色ID查询部门树信息
|
||||
*
|
||||
* @param roleId 角色ID
|
||||
* @return 选中部门列表
|
||||
*/
|
||||
public List<Long> selectDeptListByRoleId(Long roleId);
|
||||
|
||||
/**
|
||||
* 根据部门ID查询信息
|
||||
*
|
||||
* @param deptId 部门ID
|
||||
* @return 部门信息
|
||||
*/
|
||||
public SysDept selectDeptById(Long deptId);
|
||||
|
||||
/**
|
||||
* 根据ID查询所有子部门(正常状态)
|
||||
*
|
||||
* @param deptId 部门ID
|
||||
* @return 子部门数
|
||||
*/
|
||||
public int selectNormalChildrenDeptById(Long deptId);
|
||||
|
||||
/**
|
||||
* 是否存在部门子节点
|
||||
*
|
||||
* @param deptId 部门ID
|
||||
* @return 结果
|
||||
*/
|
||||
public boolean hasChildByDeptId(Long deptId);
|
||||
|
||||
/**
|
||||
* 查询部门是否存在用户
|
||||
*
|
||||
* @param deptId 部门ID
|
||||
* @return 结果 true 存在 false 不存在
|
||||
*/
|
||||
public boolean checkDeptExistUser(Long deptId);
|
||||
|
||||
/**
|
||||
* 校验部门名称是否唯一
|
||||
*
|
||||
* @param dept 部门信息
|
||||
* @return 结果
|
||||
*/
|
||||
public String checkDeptNameUnique(SysDept dept);
|
||||
|
||||
/**
|
||||
* 校验部门是否有数据权限
|
||||
*
|
||||
* @param deptId 部门id
|
||||
*/
|
||||
public void checkDeptDataScope(Long deptId);
|
||||
|
||||
/**
|
||||
* 新增保存部门信息
|
||||
*
|
||||
* @param dept 部门信息
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertDept(SysDept dept);
|
||||
|
||||
/**
|
||||
* 修改保存部门信息
|
||||
*
|
||||
* @param dept 部门信息
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateDept(SysDept dept);
|
||||
|
||||
/**
|
||||
* 删除部门管理信息
|
||||
*
|
||||
* @param deptId 部门ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteDeptById(Long deptId);
|
||||
}
|
@ -0,0 +1,60 @@
|
||||
package com.ruoyi.system.service;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.common.core.domain.entity.SysDictData;
|
||||
|
||||
/**
|
||||
* 字典 业务层
|
||||
*
|
||||
* @author ruoyi
|
||||
*/
|
||||
public interface ISysDictDataService
|
||||
{
|
||||
/**
|
||||
* 根据条件分页查询字典数据
|
||||
*
|
||||
* @param dictData 字典数据信息
|
||||
* @return 字典数据集合信息
|
||||
*/
|
||||
public List<SysDictData> selectDictDataList(SysDictData dictData);
|
||||
|
||||
/**
|
||||
* 根据字典类型和字典键值查询字典数据信息
|
||||
*
|
||||
* @param dictType 字典类型
|
||||
* @param dictValue 字典键值
|
||||
* @return 字典标签
|
||||
*/
|
||||
public String selectDictLabel(String dictType, String dictValue);
|
||||
|
||||
/**
|
||||
* 根据字典数据ID查询信息
|
||||
*
|
||||
* @param dictCode 字典数据ID
|
||||
* @return 字典数据
|
||||
*/
|
||||
public SysDictData selectDictDataById(Long dictCode);
|
||||
|
||||
/**
|
||||
* 批量删除字典数据信息
|
||||
*
|
||||
* @param dictCodes 需要删除的字典数据ID
|
||||
*/
|
||||
public void deleteDictDataByIds(Long[] dictCodes);
|
||||
|
||||
/**
|
||||
* 新增保存字典数据信息
|
||||
*
|
||||
* @param dictData 字典数据信息
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertDictData(SysDictData dictData);
|
||||
|
||||
/**
|
||||
* 修改保存字典数据信息
|
||||
*
|
||||
* @param dictData 字典数据信息
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateDictData(SysDictData dictData);
|
||||
}
|
@ -0,0 +1,98 @@
|
||||
package com.ruoyi.system.service;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.common.core.domain.entity.SysDictData;
|
||||
import com.ruoyi.common.core.domain.entity.SysDictType;
|
||||
|
||||
/**
|
||||
* 字典 业务层
|
||||
*
|
||||
* @author ruoyi
|
||||
*/
|
||||
public interface ISysDictTypeService
|
||||
{
|
||||
/**
|
||||
* 根据条件分页查询字典类型
|
||||
*
|
||||
* @param dictType 字典类型信息
|
||||
* @return 字典类型集合信息
|
||||
*/
|
||||
public List<SysDictType> selectDictTypeList(SysDictType dictType);
|
||||
|
||||
/**
|
||||
* 根据所有字典类型
|
||||
*
|
||||
* @return 字典类型集合信息
|
||||
*/
|
||||
public List<SysDictType> selectDictTypeAll();
|
||||
|
||||
/**
|
||||
* 根据字典类型查询字典数据
|
||||
*
|
||||
* @param dictType 字典类型
|
||||
* @return 字典数据集合信息
|
||||
*/
|
||||
public List<SysDictData> selectDictDataByType(String dictType);
|
||||
|
||||
/**
|
||||
* 根据字典类型ID查询信息
|
||||
*
|
||||
* @param dictId 字典类型ID
|
||||
* @return 字典类型
|
||||
*/
|
||||
public SysDictType selectDictTypeById(Long dictId);
|
||||
|
||||
/**
|
||||
* 根据字典类型查询信息
|
||||
*
|
||||
* @param dictType 字典类型
|
||||
* @return 字典类型
|
||||
*/
|
||||
public SysDictType selectDictTypeByType(String dictType);
|
||||
|
||||
/**
|
||||
* 批量删除字典信息
|
||||
*
|
||||
* @param dictIds 需要删除的字典ID
|
||||
*/
|
||||
public void deleteDictTypeByIds(Long[] dictIds);
|
||||
|
||||
/**
|
||||
* 加载字典缓存数据
|
||||
*/
|
||||
public void loadingDictCache();
|
||||
|
||||
/**
|
||||
* 清空字典缓存数据
|
||||
*/
|
||||
public void clearDictCache();
|
||||
|
||||
/**
|
||||
* 重置字典缓存数据
|
||||
*/
|
||||
public void resetDictCache();
|
||||
|
||||
/**
|
||||
* 新增保存字典类型信息
|
||||
*
|
||||
* @param dictType 字典类型信息
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertDictType(SysDictType dictType);
|
||||
|
||||
/**
|
||||
* 修改保存字典类型信息
|
||||
*
|
||||
* @param dictType 字典类型信息
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateDictType(SysDictType dictType);
|
||||
|
||||
/**
|
||||
* 校验字典类型称是否唯一
|
||||
*
|
||||
* @param dictType 字典类型
|
||||
* @return 结果
|
||||
*/
|
||||
public String checkDictTypeUnique(SysDictType dictType);
|
||||
}
|
@ -0,0 +1,40 @@
|
||||
package com.ruoyi.system.service;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.system.domain.SysLogininfor;
|
||||
|
||||
/**
|
||||
* 系统访问日志情况信息 服务层
|
||||
*
|
||||
* @author ruoyi
|
||||
*/
|
||||
public interface ISysLogininforService
|
||||
{
|
||||
/**
|
||||
* 新增系统登录日志
|
||||
*
|
||||
* @param logininfor 访问日志对象
|
||||
*/
|
||||
public void insertLogininfor(SysLogininfor logininfor);
|
||||
|
||||
/**
|
||||
* 查询系统登录日志集合
|
||||
*
|
||||
* @param logininfor 访问日志对象
|
||||
* @return 登录记录集合
|
||||
*/
|
||||
public List<SysLogininfor> selectLogininforList(SysLogininfor logininfor);
|
||||
|
||||
/**
|
||||
* 批量删除系统登录日志
|
||||
*
|
||||
* @param infoIds 需要删除的登录日志ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteLogininforByIds(Long[] infoIds);
|
||||
|
||||
/**
|
||||
* 清空系统登录日志
|
||||
*/
|
||||
public void cleanLogininfor();
|
||||
}
|
@ -0,0 +1,136 @@
|
||||
package com.ruoyi.system.service;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Set;
|
||||
import com.ruoyi.common.core.domain.TreeSelect;
|
||||
import com.ruoyi.common.core.domain.entity.SysMenu;
|
||||
import com.ruoyi.system.domain.vo.RouterVo;
|
||||
|
||||
/**
|
||||
* 菜单 业务层
|
||||
*
|
||||
* @author ruoyi
|
||||
*/
|
||||
public interface ISysMenuService
|
||||
{
|
||||
/**
|
||||
* 根据用户查询系统菜单列表
|
||||
*
|
||||
* @param userId 用户ID
|
||||
* @return 菜单列表
|
||||
*/
|
||||
public List<SysMenu> selectMenuList(Long userId);
|
||||
|
||||
/**
|
||||
* 根据用户查询系统菜单列表
|
||||
*
|
||||
* @param menu 菜单信息
|
||||
* @param userId 用户ID
|
||||
* @return 菜单列表
|
||||
*/
|
||||
public List<SysMenu> selectMenuList(SysMenu menu, Long userId);
|
||||
|
||||
/**
|
||||
* 根据用户ID查询权限
|
||||
*
|
||||
* @param userId 用户ID
|
||||
* @return 权限列表
|
||||
*/
|
||||
public Set<String> selectMenuPermsByUserId(Long userId);
|
||||
|
||||
/**
|
||||
* 根据用户ID查询菜单树信息
|
||||
*
|
||||
* @param userId 用户ID
|
||||
* @return 菜单列表
|
||||
*/
|
||||
public List<SysMenu> selectMenuTreeByUserId(Long userId);
|
||||
|
||||
/**
|
||||
* 根据角色ID查询菜单树信息
|
||||
*
|
||||
* @param roleId 角色ID
|
||||
* @return 选中菜单列表
|
||||
*/
|
||||
public List<Long> selectMenuListByRoleId(Long roleId);
|
||||
|
||||
/**
|
||||
* 构建前端路由所需要的菜单
|
||||
*
|
||||
* @param menus 菜单列表
|
||||
* @return 路由列表
|
||||
*/
|
||||
public List<RouterVo> buildMenus(List<SysMenu> menus);
|
||||
|
||||
/**
|
||||
* 构建前端所需要树结构
|
||||
*
|
||||
* @param menus 菜单列表
|
||||
* @return 树结构列表
|
||||
*/
|
||||
public List<SysMenu> buildMenuTree(List<SysMenu> menus);
|
||||
|
||||
/**
|
||||
* 构建前端所需要下拉树结构
|
||||
*
|
||||
* @param menus 菜单列表
|
||||
* @return 下拉树结构列表
|
||||
*/
|
||||
public List<TreeSelect> buildMenuTreeSelect(List<SysMenu> menus);
|
||||
|
||||
/**
|
||||
* 根据菜单ID查询信息
|
||||
*
|
||||
* @param menuId 菜单ID
|
||||
* @return 菜单信息
|
||||
*/
|
||||
public SysMenu selectMenuById(Long menuId);
|
||||
|
||||
/**
|
||||
* 是否存在菜单子节点
|
||||
*
|
||||
* @param menuId 菜单ID
|
||||
* @return 结果 true 存在 false 不存在
|
||||
*/
|
||||
public boolean hasChildByMenuId(Long menuId);
|
||||
|
||||
/**
|
||||
* 查询菜单是否存在角色
|
||||
*
|
||||
* @param menuId 菜单ID
|
||||
* @return 结果 true 存在 false 不存在
|
||||
*/
|
||||
public boolean checkMenuExistRole(Long menuId);
|
||||
|
||||
/**
|
||||
* 新增保存菜单信息
|
||||
*
|
||||
* @param menu 菜单信息
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertMenu(SysMenu menu);
|
||||
|
||||
/**
|
||||
* 修改保存菜单信息
|
||||
*
|
||||
* @param menu 菜单信息
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateMenu(SysMenu menu);
|
||||
|
||||
/**
|
||||
* 删除菜单管理信息
|
||||
*
|
||||
* @param menuId 菜单ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteMenuById(Long menuId);
|
||||
|
||||
/**
|
||||
* 校验菜单名称是否唯一
|
||||
*
|
||||
* @param menu 菜单信息
|
||||
* @return 结果
|
||||
*/
|
||||
public String checkMenuNameUnique(SysMenu menu);
|
||||
}
|
@ -0,0 +1,60 @@
|
||||
package com.ruoyi.system.service;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.system.domain.SysNotice;
|
||||
|
||||
/**
|
||||
* 公告 服务层
|
||||
*
|
||||
* @author ruoyi
|
||||
*/
|
||||
public interface ISysNoticeService
|
||||
{
|
||||
/**
|
||||
* 查询公告信息
|
||||
*
|
||||
* @param noticeId 公告ID
|
||||
* @return 公告信息
|
||||
*/
|
||||
public SysNotice selectNoticeById(Long noticeId);
|
||||
|
||||
/**
|
||||
* 查询公告列表
|
||||
*
|
||||
* @param notice 公告信息
|
||||
* @return 公告集合
|
||||
*/
|
||||
public List<SysNotice> selectNoticeList(SysNotice notice);
|
||||
|
||||
/**
|
||||
* 新增公告
|
||||
*
|
||||
* @param notice 公告信息
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertNotice(SysNotice notice);
|
||||
|
||||
/**
|
||||
* 修改公告
|
||||
*
|
||||
* @param notice 公告信息
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateNotice(SysNotice notice);
|
||||
|
||||
/**
|
||||
* 删除公告信息
|
||||
*
|
||||
* @param noticeId 公告ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteNoticeById(Long noticeId);
|
||||
|
||||
/**
|
||||
* 批量删除公告信息
|
||||
*
|
||||
* @param noticeIds 需要删除的公告ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteNoticeByIds(Long[] noticeIds);
|
||||
}
|
@ -0,0 +1,48 @@
|
||||
package com.ruoyi.system.service;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.system.domain.SysOperLog;
|
||||
|
||||
/**
|
||||
* 操作日志 服务层
|
||||
*
|
||||
* @author ruoyi
|
||||
*/
|
||||
public interface ISysOperLogService
|
||||
{
|
||||
/**
|
||||
* 新增操作日志
|
||||
*
|
||||
* @param operLog 操作日志对象
|
||||
*/
|
||||
public void insertOperlog(SysOperLog operLog);
|
||||
|
||||
/**
|
||||
* 查询系统操作日志集合
|
||||
*
|
||||
* @param operLog 操作日志对象
|
||||
* @return 操作日志集合
|
||||
*/
|
||||
public List<SysOperLog> selectOperLogList(SysOperLog operLog);
|
||||
|
||||
/**
|
||||
* 批量删除系统操作日志
|
||||
*
|
||||
* @param operIds 需要删除的操作日志ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteOperLogByIds(Long[] operIds);
|
||||
|
||||
/**
|
||||
* 查询操作日志详细
|
||||
*
|
||||
* @param operId 操作ID
|
||||
* @return 操作日志对象
|
||||
*/
|
||||
public SysOperLog selectOperLogById(Long operId);
|
||||
|
||||
/**
|
||||
* 清空操作日志
|
||||
*/
|
||||
public void cleanOperLog();
|
||||
}
|
@ -0,0 +1,99 @@
|
||||
package com.ruoyi.system.service;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.system.domain.SysPost;
|
||||
|
||||
/**
|
||||
* 岗位信息 服务层
|
||||
*
|
||||
* @author ruoyi
|
||||
*/
|
||||
public interface ISysPostService
|
||||
{
|
||||
/**
|
||||
* 查询岗位信息集合
|
||||
*
|
||||
* @param post 岗位信息
|
||||
* @return 岗位列表
|
||||
*/
|
||||
public List<SysPost> selectPostList(SysPost post);
|
||||
|
||||
/**
|
||||
* 查询所有岗位
|
||||
*
|
||||
* @return 岗位列表
|
||||
*/
|
||||
public List<SysPost> selectPostAll();
|
||||
|
||||
/**
|
||||
* 通过岗位ID查询岗位信息
|
||||
*
|
||||
* @param postId 岗位ID
|
||||
* @return 角色对象信息
|
||||
*/
|
||||
public SysPost selectPostById(Long postId);
|
||||
|
||||
/**
|
||||
* 根据用户ID获取岗位选择框列表
|
||||
*
|
||||
* @param userId 用户ID
|
||||
* @return 选中岗位ID列表
|
||||
*/
|
||||
public List<Long> selectPostListByUserId(Long userId);
|
||||
|
||||
/**
|
||||
* 校验岗位名称
|
||||
*
|
||||
* @param post 岗位信息
|
||||
* @return 结果
|
||||
*/
|
||||
public String checkPostNameUnique(SysPost post);
|
||||
|
||||
/**
|
||||
* 校验岗位编码
|
||||
*
|
||||
* @param post 岗位信息
|
||||
* @return 结果
|
||||
*/
|
||||
public String checkPostCodeUnique(SysPost post);
|
||||
|
||||
/**
|
||||
* 通过岗位ID查询岗位使用数量
|
||||
*
|
||||
* @param postId 岗位ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int countUserPostById(Long postId);
|
||||
|
||||
/**
|
||||
* 删除岗位信息
|
||||
*
|
||||
* @param postId 岗位ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deletePostById(Long postId);
|
||||
|
||||
/**
|
||||
* 批量删除岗位信息
|
||||
*
|
||||
* @param postIds 需要删除的岗位ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deletePostByIds(Long[] postIds);
|
||||
|
||||
/**
|
||||
* 新增保存岗位信息
|
||||
*
|
||||
* @param post 岗位信息
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertPost(SysPost post);
|
||||
|
||||
/**
|
||||
* 修改保存岗位信息
|
||||
*
|
||||
* @param post 岗位信息
|
||||
* @return 结果
|
||||
*/
|
||||
public int updatePost(SysPost post);
|
||||
}
|
@ -0,0 +1,173 @@
|
||||
package com.ruoyi.system.service;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Set;
|
||||
import com.ruoyi.common.core.domain.entity.SysRole;
|
||||
import com.ruoyi.system.domain.SysUserRole;
|
||||
|
||||
/**
|
||||
* 角色业务层
|
||||
*
|
||||
* @author ruoyi
|
||||
*/
|
||||
public interface ISysRoleService
|
||||
{
|
||||
/**
|
||||
* 根据条件分页查询角色数据
|
||||
*
|
||||
* @param role 角色信息
|
||||
* @return 角色数据集合信息
|
||||
*/
|
||||
public List<SysRole> selectRoleList(SysRole role);
|
||||
|
||||
/**
|
||||
* 根据用户ID查询角色列表
|
||||
*
|
||||
* @param userId 用户ID
|
||||
* @return 角色列表
|
||||
*/
|
||||
public List<SysRole> selectRolesByUserId(Long userId);
|
||||
|
||||
/**
|
||||
* 根据用户ID查询角色权限
|
||||
*
|
||||
* @param userId 用户ID
|
||||
* @return 权限列表
|
||||
*/
|
||||
public Set<String> selectRolePermissionByUserId(Long userId);
|
||||
|
||||
/**
|
||||
* 查询所有角色
|
||||
*
|
||||
* @return 角色列表
|
||||
*/
|
||||
public List<SysRole> selectRoleAll();
|
||||
|
||||
/**
|
||||
* 根据用户ID获取角色选择框列表
|
||||
*
|
||||
* @param userId 用户ID
|
||||
* @return 选中角色ID列表
|
||||
*/
|
||||
public List<Long> selectRoleListByUserId(Long userId);
|
||||
|
||||
/**
|
||||
* 通过角色ID查询角色
|
||||
*
|
||||
* @param roleId 角色ID
|
||||
* @return 角色对象信息
|
||||
*/
|
||||
public SysRole selectRoleById(Long roleId);
|
||||
|
||||
/**
|
||||
* 校验角色名称是否唯一
|
||||
*
|
||||
* @param role 角色信息
|
||||
* @return 结果
|
||||
*/
|
||||
public String checkRoleNameUnique(SysRole role);
|
||||
|
||||
/**
|
||||
* 校验角色权限是否唯一
|
||||
*
|
||||
* @param role 角色信息
|
||||
* @return 结果
|
||||
*/
|
||||
public String checkRoleKeyUnique(SysRole role);
|
||||
|
||||
/**
|
||||
* 校验角色是否允许操作
|
||||
*
|
||||
* @param role 角色信息
|
||||
*/
|
||||
public void checkRoleAllowed(SysRole role);
|
||||
|
||||
/**
|
||||
* 校验角色是否有数据权限
|
||||
*
|
||||
* @param roleId 角色id
|
||||
*/
|
||||
public void checkRoleDataScope(Long roleId);
|
||||
|
||||
/**
|
||||
* 通过角色ID查询角色使用数量
|
||||
*
|
||||
* @param roleId 角色ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int countUserRoleByRoleId(Long roleId);
|
||||
|
||||
/**
|
||||
* 新增保存角色信息
|
||||
*
|
||||
* @param role 角色信息
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertRole(SysRole role);
|
||||
|
||||
/**
|
||||
* 修改保存角色信息
|
||||
*
|
||||
* @param role 角色信息
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateRole(SysRole role);
|
||||
|
||||
/**
|
||||
* 修改角色状态
|
||||
*
|
||||
* @param role 角色信息
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateRoleStatus(SysRole role);
|
||||
|
||||
/**
|
||||
* 修改数据权限信息
|
||||
*
|
||||
* @param role 角色信息
|
||||
* @return 结果
|
||||
*/
|
||||
public int authDataScope(SysRole role);
|
||||
|
||||
/**
|
||||
* 通过角色ID删除角色
|
||||
*
|
||||
* @param roleId 角色ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteRoleById(Long roleId);
|
||||
|
||||
/**
|
||||
* 批量删除角色信息
|
||||
*
|
||||
* @param roleIds 需要删除的角色ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteRoleByIds(Long[] roleIds);
|
||||
|
||||
/**
|
||||
* 取消授权用户角色
|
||||
*
|
||||
* @param userRole 用户和角色关联信息
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteAuthUser(SysUserRole userRole);
|
||||
|
||||
/**
|
||||
* 批量取消授权用户角色
|
||||
*
|
||||
* @param roleId 角色ID
|
||||
* @param userIds 需要取消授权的用户数据ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteAuthUsers(Long roleId, Long[] userIds);
|
||||
|
||||
/**
|
||||
* 批量选择授权用户角色
|
||||
*
|
||||
* @param roleId 角色ID
|
||||
* @param userIds 需要删除的用户数据ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertAuthUsers(Long roleId, Long[] userIds);
|
||||
}
|
@ -0,0 +1,48 @@
|
||||
package com.ruoyi.system.service;
|
||||
|
||||
import com.ruoyi.common.core.domain.model.LoginUser;
|
||||
import com.ruoyi.system.domain.SysUserOnline;
|
||||
|
||||
/**
|
||||
* 在线用户 服务层
|
||||
*
|
||||
* @author ruoyi
|
||||
*/
|
||||
public interface ISysUserOnlineService
|
||||
{
|
||||
/**
|
||||
* 通过登录地址查询信息
|
||||
*
|
||||
* @param ipaddr 登录地址
|
||||
* @param user 用户信息
|
||||
* @return 在线用户信息
|
||||
*/
|
||||
public SysUserOnline selectOnlineByIpaddr(String ipaddr, LoginUser user);
|
||||
|
||||
/**
|
||||
* 通过用户名称查询信息
|
||||
*
|
||||
* @param userName 用户名称
|
||||
* @param user 用户信息
|
||||
* @return 在线用户信息
|
||||
*/
|
||||
public SysUserOnline selectOnlineByUserName(String userName, LoginUser user);
|
||||
|
||||
/**
|
||||
* 通过登录地址/用户名称查询信息
|
||||
*
|
||||
* @param ipaddr 登录地址
|
||||
* @param userName 用户名称
|
||||
* @param user 用户信息
|
||||
* @return 在线用户信息
|
||||
*/
|
||||
public SysUserOnline selectOnlineByInfo(String ipaddr, String userName, LoginUser user);
|
||||
|
||||
/**
|
||||
* 设置在线用户信息
|
||||
*
|
||||
* @param user 用户信息
|
||||
* @return 在线用户
|
||||
*/
|
||||
public SysUserOnline loginUserToUserOnline(LoginUser user);
|
||||
}
|
@ -0,0 +1,206 @@
|
||||
package com.ruoyi.system.service;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.common.core.domain.entity.SysUser;
|
||||
|
||||
/**
|
||||
* 用户 业务层
|
||||
*
|
||||
* @author ruoyi
|
||||
*/
|
||||
public interface ISysUserService
|
||||
{
|
||||
/**
|
||||
* 根据条件分页查询用户列表
|
||||
*
|
||||
* @param user 用户信息
|
||||
* @return 用户信息集合信息
|
||||
*/
|
||||
public List<SysUser> selectUserList(SysUser user);
|
||||
|
||||
/**
|
||||
* 根据条件分页查询已分配用户角色列表
|
||||
*
|
||||
* @param user 用户信息
|
||||
* @return 用户信息集合信息
|
||||
*/
|
||||
public List<SysUser> selectAllocatedList(SysUser user);
|
||||
|
||||
/**
|
||||
* 根据条件分页查询未分配用户角色列表
|
||||
*
|
||||
* @param user 用户信息
|
||||
* @return 用户信息集合信息
|
||||
*/
|
||||
public List<SysUser> selectUnallocatedList(SysUser user);
|
||||
|
||||
/**
|
||||
* 通过用户名查询用户
|
||||
*
|
||||
* @param userName 用户名
|
||||
* @return 用户对象信息
|
||||
*/
|
||||
public SysUser selectUserByUserName(String userName);
|
||||
|
||||
/**
|
||||
* 通过用户ID查询用户
|
||||
*
|
||||
* @param userId 用户ID
|
||||
* @return 用户对象信息
|
||||
*/
|
||||
public SysUser selectUserById(Long userId);
|
||||
|
||||
/**
|
||||
* 根据用户ID查询用户所属角色组
|
||||
*
|
||||
* @param userName 用户名
|
||||
* @return 结果
|
||||
*/
|
||||
public String selectUserRoleGroup(String userName);
|
||||
|
||||
/**
|
||||
* 根据用户ID查询用户所属岗位组
|
||||
*
|
||||
* @param userName 用户名
|
||||
* @return 结果
|
||||
*/
|
||||
public String selectUserPostGroup(String userName);
|
||||
|
||||
/**
|
||||
* 校验用户名称是否唯一
|
||||
*
|
||||
* @param userName 用户名称
|
||||
* @return 结果
|
||||
*/
|
||||
public String checkUserNameUnique(String userName);
|
||||
|
||||
/**
|
||||
* 校验手机号码是否唯一
|
||||
*
|
||||
* @param user 用户信息
|
||||
* @return 结果
|
||||
*/
|
||||
public String checkPhoneUnique(SysUser user);
|
||||
|
||||
/**
|
||||
* 校验email是否唯一
|
||||
*
|
||||
* @param user 用户信息
|
||||
* @return 结果
|
||||
*/
|
||||
public String checkEmailUnique(SysUser user);
|
||||
|
||||
/**
|
||||
* 校验用户是否允许操作
|
||||
*
|
||||
* @param user 用户信息
|
||||
*/
|
||||
public void checkUserAllowed(SysUser user);
|
||||
|
||||
/**
|
||||
* 校验用户是否有数据权限
|
||||
*
|
||||
* @param userId 用户id
|
||||
*/
|
||||
public void checkUserDataScope(Long userId);
|
||||
|
||||
/**
|
||||
* 新增用户信息
|
||||
*
|
||||
* @param user 用户信息
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertUser(SysUser user);
|
||||
|
||||
/**
|
||||
* 注册用户信息
|
||||
*
|
||||
* @param user 用户信息
|
||||
* @return 结果
|
||||
*/
|
||||
public boolean registerUser(SysUser user);
|
||||
|
||||
/**
|
||||
* 修改用户信息
|
||||
*
|
||||
* @param user 用户信息
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateUser(SysUser user);
|
||||
|
||||
/**
|
||||
* 用户授权角色
|
||||
*
|
||||
* @param userId 用户ID
|
||||
* @param roleIds 角色组
|
||||
*/
|
||||
public void insertUserAuth(Long userId, Long[] roleIds);
|
||||
|
||||
/**
|
||||
* 修改用户状态
|
||||
*
|
||||
* @param user 用户信息
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateUserStatus(SysUser user);
|
||||
|
||||
/**
|
||||
* 修改用户基本信息
|
||||
*
|
||||
* @param user 用户信息
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateUserProfile(SysUser user);
|
||||
|
||||
/**
|
||||
* 修改用户头像
|
||||
*
|
||||
* @param userName 用户名
|
||||
* @param avatar 头像地址
|
||||
* @return 结果
|
||||
*/
|
||||
public boolean updateUserAvatar(String userName, String avatar);
|
||||
|
||||
/**
|
||||
* 重置用户密码
|
||||
*
|
||||
* @param user 用户信息
|
||||
* @return 结果
|
||||
*/
|
||||
public int resetPwd(SysUser user);
|
||||
|
||||
/**
|
||||
* 重置用户密码
|
||||
*
|
||||
* @param userName 用户名
|
||||
* @param password 密码
|
||||
* @return 结果
|
||||
*/
|
||||
public int resetUserPwd(String userName, String password);
|
||||
|
||||
/**
|
||||
* 通过用户ID删除用户
|
||||
*
|
||||
* @param userId 用户ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteUserById(Long userId);
|
||||
|
||||
/**
|
||||
* 批量删除用户信息
|
||||
*
|
||||
* @param userIds 需要删除的用户ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteUserByIds(Long[] userIds);
|
||||
|
||||
/**
|
||||
* 导入用户数据
|
||||
*
|
||||
* @param userList 用户数据列表
|
||||
* @param isUpdateSupport 是否更新支持,如果已存在,则进行更新数据
|
||||
* @param operName 操作用户
|
||||
* @return 结果
|
||||
*/
|
||||
public String importUser(List<SysUser> userList, Boolean isUpdateSupport, String operName);
|
||||
}
|
@ -0,0 +1,227 @@
|
||||
package com.ruoyi.system.service.impl;
|
||||
|
||||
import com.ruoyi.common.annotation.DataSource;
|
||||
import com.ruoyi.common.constant.Constants;
|
||||
import com.ruoyi.common.constant.UserConstants;
|
||||
import com.ruoyi.common.core.redis.RedisCache;
|
||||
import com.ruoyi.common.core.text.Convert;
|
||||
import com.ruoyi.common.enums.DataSourceType;
|
||||
import com.ruoyi.common.exception.ServiceException;
|
||||
import com.ruoyi.common.utils.StringUtils;
|
||||
import com.ruoyi.system.domain.SysConfig;
|
||||
import com.ruoyi.system.mapper.SysConfigMapper;
|
||||
import com.ruoyi.system.service.ISysConfigService;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import javax.annotation.PostConstruct;
|
||||
import javax.annotation.Resource;
|
||||
import java.util.Collection;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 参数配置 服务层实现
|
||||
*
|
||||
* @author ruoyi
|
||||
*/
|
||||
@Service
|
||||
public class SysConfigServiceImpl implements ISysConfigService
|
||||
{
|
||||
@Resource
|
||||
private SysConfigMapper configMapper;
|
||||
|
||||
@Resource
|
||||
private RedisCache redisCache;
|
||||
|
||||
/**
|
||||
* 项目启动时,初始化参数到缓存
|
||||
*/
|
||||
@PostConstruct
|
||||
public void init()
|
||||
{
|
||||
loadingConfigCache();
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询参数配置信息
|
||||
*
|
||||
* @param configId 参数配置ID
|
||||
* @return 参数配置信息
|
||||
*/
|
||||
@Override
|
||||
@DataSource(DataSourceType.MASTER)
|
||||
public SysConfig selectConfigById(Long configId)
|
||||
{
|
||||
SysConfig config = new SysConfig();
|
||||
config.setConfigId(configId);
|
||||
return configMapper.selectConfig(config);
|
||||
}
|
||||
|
||||
/**
|
||||
* 根据键名查询参数配置信息
|
||||
*
|
||||
* @param configKey 参数key
|
||||
* @return 参数键值
|
||||
*/
|
||||
@Override
|
||||
public String selectConfigByKey(String configKey)
|
||||
{
|
||||
String configValue = Convert.toStr(redisCache.getCacheObject(getCacheKey(configKey)));
|
||||
if (StringUtils.isNotEmpty(configValue))
|
||||
{
|
||||
return configValue;
|
||||
}
|
||||
SysConfig config = new SysConfig();
|
||||
config.setConfigKey(configKey);
|
||||
SysConfig retConfig = configMapper.selectConfig(config);
|
||||
if (StringUtils.isNotNull(retConfig))
|
||||
{
|
||||
redisCache.setCacheObject(getCacheKey(configKey), retConfig.getConfigValue());
|
||||
return retConfig.getConfigValue();
|
||||
}
|
||||
return StringUtils.EMPTY;
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取验证码开关
|
||||
*
|
||||
* @return true开启,false关闭
|
||||
*/
|
||||
@Override
|
||||
public boolean selectCaptchaOnOff()
|
||||
{
|
||||
String captchaOnOff = selectConfigByKey("sys.account.captchaOnOff");
|
||||
if (StringUtils.isEmpty(captchaOnOff))
|
||||
{
|
||||
return true;
|
||||
}
|
||||
return Convert.toBool(captchaOnOff);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询参数配置列表
|
||||
*
|
||||
* @param config 参数配置信息
|
||||
* @return 参数配置集合
|
||||
*/
|
||||
@Override
|
||||
public List<SysConfig> selectConfigList(SysConfig config)
|
||||
{
|
||||
return configMapper.selectConfigList(config);
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增参数配置
|
||||
*
|
||||
* @param config 参数配置信息
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int insertConfig(SysConfig config)
|
||||
{
|
||||
int row = configMapper.insertConfig(config);
|
||||
if (row > 0)
|
||||
{
|
||||
redisCache.setCacheObject(getCacheKey(config.getConfigKey()), config.getConfigValue());
|
||||
}
|
||||
return row;
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改参数配置
|
||||
*
|
||||
* @param config 参数配置信息
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int updateConfig(SysConfig config)
|
||||
{
|
||||
int row = configMapper.updateConfig(config);
|
||||
if (row > 0)
|
||||
{
|
||||
redisCache.setCacheObject(getCacheKey(config.getConfigKey()), config.getConfigValue());
|
||||
}
|
||||
return row;
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除参数信息
|
||||
*
|
||||
* @param configIds 需要删除的参数ID
|
||||
*/
|
||||
@Override
|
||||
public void deleteConfigByIds(Long[] configIds)
|
||||
{
|
||||
for (Long configId : configIds)
|
||||
{
|
||||
SysConfig config = selectConfigById(configId);
|
||||
if (StringUtils.equals(UserConstants.YES, config.getConfigType()))
|
||||
{
|
||||
throw new ServiceException(String.format("内置参数【%1$s】不能删除 ", config.getConfigKey()));
|
||||
}
|
||||
configMapper.deleteConfigById(configId);
|
||||
redisCache.deleteObject(getCacheKey(config.getConfigKey()));
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 加载参数缓存数据
|
||||
*/
|
||||
@Override
|
||||
public void loadingConfigCache()
|
||||
{
|
||||
List<SysConfig> configsList = configMapper.selectConfigList(new SysConfig());
|
||||
for (SysConfig config : configsList)
|
||||
{
|
||||
redisCache.setCacheObject(getCacheKey(config.getConfigKey()), config.getConfigValue());
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 清空参数缓存数据
|
||||
*/
|
||||
@Override
|
||||
public void clearConfigCache()
|
||||
{
|
||||
Collection<String> keys = redisCache.keys(Constants.SYS_CONFIG_KEY + "*");
|
||||
redisCache.deleteObject(keys);
|
||||
}
|
||||
|
||||
/**
|
||||
* 重置参数缓存数据
|
||||
*/
|
||||
@Override
|
||||
public void resetConfigCache()
|
||||
{
|
||||
clearConfigCache();
|
||||
loadingConfigCache();
|
||||
}
|
||||
|
||||
/**
|
||||
* 校验参数键名是否唯一
|
||||
*
|
||||
* @param config 参数配置信息
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public String checkConfigKeyUnique(SysConfig config)
|
||||
{
|
||||
Long configId = StringUtils.isNull(config.getConfigId()) ? -1L : config.getConfigId();
|
||||
SysConfig info = configMapper.checkConfigKeyUnique(config.getConfigKey());
|
||||
if (StringUtils.isNotNull(info) && info.getConfigId().longValue() != configId.longValue())
|
||||
{
|
||||
return UserConstants.NOT_UNIQUE;
|
||||
}
|
||||
return UserConstants.UNIQUE;
|
||||
}
|
||||
|
||||
/**
|
||||
* 设置cache key
|
||||
*
|
||||
* @param configKey 参数键
|
||||
* @return 缓存键key
|
||||
*/
|
||||
private String getCacheKey(String configKey)
|
||||
{
|
||||
return Constants.SYS_CONFIG_KEY + configKey;
|
||||
}
|
||||
}
|
@ -0,0 +1,329 @@
|
||||
package com.ruoyi.system.service.impl;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.Iterator;
|
||||
import java.util.List;
|
||||
import java.util.stream.Collectors;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import com.ruoyi.common.annotation.DataScope;
|
||||
import com.ruoyi.common.constant.UserConstants;
|
||||
import com.ruoyi.common.core.domain.TreeSelect;
|
||||
import com.ruoyi.common.core.domain.entity.SysDept;
|
||||
import com.ruoyi.common.core.domain.entity.SysRole;
|
||||
import com.ruoyi.common.core.domain.entity.SysUser;
|
||||
import com.ruoyi.common.core.text.Convert;
|
||||
import com.ruoyi.common.exception.ServiceException;
|
||||
import com.ruoyi.common.utils.SecurityUtils;
|
||||
import com.ruoyi.common.utils.StringUtils;
|
||||
import com.ruoyi.common.utils.spring.SpringUtils;
|
||||
import com.ruoyi.system.mapper.SysDeptMapper;
|
||||
import com.ruoyi.system.mapper.SysRoleMapper;
|
||||
import com.ruoyi.system.service.ISysDeptService;
|
||||
|
||||
/**
|
||||
* 部门管理 服务实现
|
||||
*
|
||||
* @author ruoyi
|
||||
*/
|
||||
@Service
|
||||
public class SysDeptServiceImpl implements ISysDeptService
|
||||
{
|
||||
@Autowired
|
||||
private SysDeptMapper deptMapper;
|
||||
|
||||
@Autowired
|
||||
private SysRoleMapper roleMapper;
|
||||
|
||||
/**
|
||||
* 查询部门管理数据
|
||||
*
|
||||
* @param dept 部门信息
|
||||
* @return 部门信息集合
|
||||
*/
|
||||
@Override
|
||||
@DataScope(deptAlias = "d")
|
||||
public List<SysDept> selectDeptList(SysDept dept)
|
||||
{
|
||||
return deptMapper.selectDeptList(dept);
|
||||
}
|
||||
|
||||
/**
|
||||
* 构建前端所需要树结构
|
||||
*
|
||||
* @param depts 部门列表
|
||||
* @return 树结构列表
|
||||
*/
|
||||
@Override
|
||||
public List<SysDept> buildDeptTree(List<SysDept> depts)
|
||||
{
|
||||
List<SysDept> returnList = new ArrayList<SysDept>();
|
||||
List<Long> tempList = new ArrayList<Long>();
|
||||
for (SysDept dept : depts)
|
||||
{
|
||||
tempList.add(dept.getDeptId());
|
||||
}
|
||||
for (SysDept dept : depts)
|
||||
{
|
||||
// 如果是顶级节点, 遍历该父节点的所有子节点
|
||||
if (!tempList.contains(dept.getParentId()))
|
||||
{
|
||||
recursionFn(depts, dept);
|
||||
returnList.add(dept);
|
||||
}
|
||||
}
|
||||
if (returnList.isEmpty())
|
||||
{
|
||||
returnList = depts;
|
||||
}
|
||||
return returnList;
|
||||
}
|
||||
|
||||
/**
|
||||
* 构建前端所需要下拉树结构
|
||||
*
|
||||
* @param depts 部门列表
|
||||
* @return 下拉树结构列表
|
||||
*/
|
||||
@Override
|
||||
public List<TreeSelect> buildDeptTreeSelect(List<SysDept> depts)
|
||||
{
|
||||
List<SysDept> deptTrees = buildDeptTree(depts);
|
||||
return deptTrees.stream().map(TreeSelect::new).collect(Collectors.toList());
|
||||
}
|
||||
|
||||
/**
|
||||
* 根据角色ID查询部门树信息
|
||||
*
|
||||
* @param roleId 角色ID
|
||||
* @return 选中部门列表
|
||||
*/
|
||||
@Override
|
||||
public List<Long> selectDeptListByRoleId(Long roleId)
|
||||
{
|
||||
SysRole role = roleMapper.selectRoleById(roleId);
|
||||
return deptMapper.selectDeptListByRoleId(roleId, role.isDeptCheckStrictly());
|
||||
}
|
||||
|
||||
/**
|
||||
* 根据部门ID查询信息
|
||||
*
|
||||
* @param deptId 部门ID
|
||||
* @return 部门信息
|
||||
*/
|
||||
@Override
|
||||
public SysDept selectDeptById(Long deptId)
|
||||
{
|
||||
return deptMapper.selectDeptById(deptId);
|
||||
}
|
||||
|
||||
/**
|
||||
* 根据ID查询所有子部门(正常状态)
|
||||
*
|
||||
* @param deptId 部门ID
|
||||
* @return 子部门数
|
||||
*/
|
||||
@Override
|
||||
public int selectNormalChildrenDeptById(Long deptId)
|
||||
{
|
||||
return deptMapper.selectNormalChildrenDeptById(deptId);
|
||||
}
|
||||
|
||||
/**
|
||||
* 是否存在子节点
|
||||
*
|
||||
* @param deptId 部门ID
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public boolean hasChildByDeptId(Long deptId)
|
||||
{
|
||||
int result = deptMapper.hasChildByDeptId(deptId);
|
||||
return result > 0;
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询部门是否存在用户
|
||||
*
|
||||
* @param deptId 部门ID
|
||||
* @return 结果 true 存在 false 不存在
|
||||
*/
|
||||
@Override
|
||||
public boolean checkDeptExistUser(Long deptId)
|
||||
{
|
||||
int result = deptMapper.checkDeptExistUser(deptId);
|
||||
return result > 0;
|
||||
}
|
||||
|
||||
/**
|
||||
* 校验部门名称是否唯一
|
||||
*
|
||||
* @param dept 部门信息
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public String checkDeptNameUnique(SysDept dept)
|
||||
{
|
||||
Long deptId = StringUtils.isNull(dept.getDeptId()) ? -1L : dept.getDeptId();
|
||||
SysDept info = deptMapper.checkDeptNameUnique(dept.getDeptName(), dept.getParentId());
|
||||
if (StringUtils.isNotNull(info) && info.getDeptId().longValue() != deptId.longValue())
|
||||
{
|
||||
return UserConstants.NOT_UNIQUE;
|
||||
}
|
||||
return UserConstants.UNIQUE;
|
||||
}
|
||||
|
||||
/**
|
||||
* 校验部门是否有数据权限
|
||||
*
|
||||
* @param deptId 部门id
|
||||
*/
|
||||
@Override
|
||||
public void checkDeptDataScope(Long deptId)
|
||||
{
|
||||
if (!SysUser.isAdmin(SecurityUtils.getUserId()))
|
||||
{
|
||||
SysDept dept = new SysDept();
|
||||
dept.setDeptId(deptId);
|
||||
List<SysDept> depts = SpringUtils.getAopProxy(this).selectDeptList(dept);
|
||||
if (StringUtils.isEmpty(depts))
|
||||
{
|
||||
throw new ServiceException("没有权限访问部门数据!");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增保存部门信息
|
||||
*
|
||||
* @param dept 部门信息
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int insertDept(SysDept dept)
|
||||
{
|
||||
SysDept info = deptMapper.selectDeptById(dept.getParentId());
|
||||
// 如果父节点不为正常状态,则不允许新增子节点
|
||||
if (!UserConstants.DEPT_NORMAL.equals(info.getStatus()))
|
||||
{
|
||||
throw new ServiceException("部门停用,不允许新增");
|
||||
}
|
||||
dept.setAncestors(info.getAncestors() + "," + dept.getParentId());
|
||||
return deptMapper.insertDept(dept);
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改保存部门信息
|
||||
*
|
||||
* @param dept 部门信息
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int updateDept(SysDept dept)
|
||||
{
|
||||
SysDept newParentDept = deptMapper.selectDeptById(dept.getParentId());
|
||||
SysDept oldDept = deptMapper.selectDeptById(dept.getDeptId());
|
||||
if (StringUtils.isNotNull(newParentDept) && StringUtils.isNotNull(oldDept))
|
||||
{
|
||||
String newAncestors = newParentDept.getAncestors() + "," + newParentDept.getDeptId();
|
||||
String oldAncestors = oldDept.getAncestors();
|
||||
dept.setAncestors(newAncestors);
|
||||
updateDeptChildren(dept.getDeptId(), newAncestors, oldAncestors);
|
||||
}
|
||||
int result = deptMapper.updateDept(dept);
|
||||
if (UserConstants.DEPT_NORMAL.equals(dept.getStatus()) && StringUtils.isNotEmpty(dept.getAncestors())
|
||||
&& !StringUtils.equals("0", dept.getAncestors()))
|
||||
{
|
||||
// 如果该部门是启用状态,则启用该部门的所有上级部门
|
||||
updateParentDeptStatusNormal(dept);
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改该部门的父级部门状态
|
||||
*
|
||||
* @param dept 当前部门
|
||||
*/
|
||||
private void updateParentDeptStatusNormal(SysDept dept)
|
||||
{
|
||||
String ancestors = dept.getAncestors();
|
||||
Long[] deptIds = Convert.toLongArray(ancestors);
|
||||
deptMapper.updateDeptStatusNormal(deptIds);
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改子元素关系
|
||||
*
|
||||
* @param deptId 被修改的部门ID
|
||||
* @param newAncestors 新的父ID集合
|
||||
* @param oldAncestors 旧的父ID集合
|
||||
*/
|
||||
public void updateDeptChildren(Long deptId, String newAncestors, String oldAncestors)
|
||||
{
|
||||
List<SysDept> children = deptMapper.selectChildrenDeptById(deptId);
|
||||
for (SysDept child : children)
|
||||
{
|
||||
child.setAncestors(child.getAncestors().replaceFirst(oldAncestors, newAncestors));
|
||||
}
|
||||
if (children.size() > 0)
|
||||
{
|
||||
deptMapper.updateDeptChildren(children);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除部门管理信息
|
||||
*
|
||||
* @param deptId 部门ID
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deleteDeptById(Long deptId)
|
||||
{
|
||||
return deptMapper.deleteDeptById(deptId);
|
||||
}
|
||||
|
||||
/**
|
||||
* 递归列表
|
||||
*/
|
||||
private void recursionFn(List<SysDept> list, SysDept t)
|
||||
{
|
||||
// 得到子节点列表
|
||||
List<SysDept> childList = getChildList(list, t);
|
||||
t.setChildren(childList);
|
||||
for (SysDept tChild : childList)
|
||||
{
|
||||
if (hasChild(list, tChild))
|
||||
{
|
||||
recursionFn(list, tChild);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 得到子节点列表
|
||||
*/
|
||||
private List<SysDept> getChildList(List<SysDept> list, SysDept t)
|
||||
{
|
||||
List<SysDept> tlist = new ArrayList<SysDept>();
|
||||
Iterator<SysDept> it = list.iterator();
|
||||
while (it.hasNext())
|
||||
{
|
||||
SysDept n = (SysDept) it.next();
|
||||
if (StringUtils.isNotNull(n.getParentId()) && n.getParentId().longValue() == t.getDeptId().longValue())
|
||||
{
|
||||
tlist.add(n);
|
||||
}
|
||||
}
|
||||
return tlist;
|
||||
}
|
||||
|
||||
/**
|
||||
* 判断是否有子节点
|
||||
*/
|
||||
private boolean hasChild(List<SysDept> list, SysDept t)
|
||||
{
|
||||
return getChildList(list, t).size() > 0;
|
||||
}
|
||||
}
|
@ -0,0 +1,111 @@
|
||||
package com.ruoyi.system.service.impl;
|
||||
|
||||
import java.util.List;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import com.ruoyi.common.core.domain.entity.SysDictData;
|
||||
import com.ruoyi.common.utils.DictUtils;
|
||||
import com.ruoyi.system.mapper.SysDictDataMapper;
|
||||
import com.ruoyi.system.service.ISysDictDataService;
|
||||
|
||||
/**
|
||||
* 字典 业务层处理
|
||||
*
|
||||
* @author ruoyi
|
||||
*/
|
||||
@Service
|
||||
public class SysDictDataServiceImpl implements ISysDictDataService
|
||||
{
|
||||
@Autowired
|
||||
private SysDictDataMapper dictDataMapper;
|
||||
|
||||
/**
|
||||
* 根据条件分页查询字典数据
|
||||
*
|
||||
* @param dictData 字典数据信息
|
||||
* @return 字典数据集合信息
|
||||
*/
|
||||
@Override
|
||||
public List<SysDictData> selectDictDataList(SysDictData dictData)
|
||||
{
|
||||
return dictDataMapper.selectDictDataList(dictData);
|
||||
}
|
||||
|
||||
/**
|
||||
* 根据字典类型和字典键值查询字典数据信息
|
||||
*
|
||||
* @param dictType 字典类型
|
||||
* @param dictValue 字典键值
|
||||
* @return 字典标签
|
||||
*/
|
||||
@Override
|
||||
public String selectDictLabel(String dictType, String dictValue)
|
||||
{
|
||||
return dictDataMapper.selectDictLabel(dictType, dictValue);
|
||||
}
|
||||
|
||||
/**
|
||||
* 根据字典数据ID查询信息
|
||||
*
|
||||
* @param dictCode 字典数据ID
|
||||
* @return 字典数据
|
||||
*/
|
||||
@Override
|
||||
public SysDictData selectDictDataById(Long dictCode)
|
||||
{
|
||||
return dictDataMapper.selectDictDataById(dictCode);
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除字典数据信息
|
||||
*
|
||||
* @param dictCodes 需要删除的字典数据ID
|
||||
*/
|
||||
@Override
|
||||
public void deleteDictDataByIds(Long[] dictCodes)
|
||||
{
|
||||
for (Long dictCode : dictCodes)
|
||||
{
|
||||
SysDictData data = selectDictDataById(dictCode);
|
||||
dictDataMapper.deleteDictDataById(dictCode);
|
||||
List<SysDictData> dictDatas = dictDataMapper.selectDictDataByType(data.getDictType());
|
||||
DictUtils.setDictCache(data.getDictType(), dictDatas);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增保存字典数据信息
|
||||
*
|
||||
* @param data 字典数据信息
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int insertDictData(SysDictData data)
|
||||
{
|
||||
int row = dictDataMapper.insertDictData(data);
|
||||
if (row > 0)
|
||||
{
|
||||
List<SysDictData> dictDatas = dictDataMapper.selectDictDataByType(data.getDictType());
|
||||
DictUtils.setDictCache(data.getDictType(), dictDatas);
|
||||
}
|
||||
return row;
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改保存字典数据信息
|
||||
*
|
||||
* @param data 字典数据信息
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int updateDictData(SysDictData data)
|
||||
{
|
||||
int row = dictDataMapper.updateDictData(data);
|
||||
if (row > 0)
|
||||
{
|
||||
List<SysDictData> dictDatas = dictDataMapper.selectDictDataByType(data.getDictType());
|
||||
DictUtils.setDictCache(data.getDictType(), dictDatas);
|
||||
}
|
||||
return row;
|
||||
}
|
||||
}
|
@ -0,0 +1,223 @@
|
||||
package com.ruoyi.system.service.impl;
|
||||
|
||||
import java.util.Comparator;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.stream.Collectors;
|
||||
import javax.annotation.PostConstruct;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
import com.ruoyi.common.constant.UserConstants;
|
||||
import com.ruoyi.common.core.domain.entity.SysDictData;
|
||||
import com.ruoyi.common.core.domain.entity.SysDictType;
|
||||
import com.ruoyi.common.exception.ServiceException;
|
||||
import com.ruoyi.common.utils.DictUtils;
|
||||
import com.ruoyi.common.utils.StringUtils;
|
||||
import com.ruoyi.system.mapper.SysDictDataMapper;
|
||||
import com.ruoyi.system.mapper.SysDictTypeMapper;
|
||||
import com.ruoyi.system.service.ISysDictTypeService;
|
||||
|
||||
/**
|
||||
* 字典 业务层处理
|
||||
*
|
||||
* @author ruoyi
|
||||
*/
|
||||
@Service
|
||||
public class SysDictTypeServiceImpl implements ISysDictTypeService
|
||||
{
|
||||
@Autowired
|
||||
private SysDictTypeMapper dictTypeMapper;
|
||||
|
||||
@Autowired
|
||||
private SysDictDataMapper dictDataMapper;
|
||||
|
||||
/**
|
||||
* 项目启动时,初始化字典到缓存
|
||||
*/
|
||||
@PostConstruct
|
||||
public void init()
|
||||
{
|
||||
loadingDictCache();
|
||||
}
|
||||
|
||||
/**
|
||||
* 根据条件分页查询字典类型
|
||||
*
|
||||
* @param dictType 字典类型信息
|
||||
* @return 字典类型集合信息
|
||||
*/
|
||||
@Override
|
||||
public List<SysDictType> selectDictTypeList(SysDictType dictType)
|
||||
{
|
||||
return dictTypeMapper.selectDictTypeList(dictType);
|
||||
}
|
||||
|
||||
/**
|
||||
* 根据所有字典类型
|
||||
*
|
||||
* @return 字典类型集合信息
|
||||
*/
|
||||
@Override
|
||||
public List<SysDictType> selectDictTypeAll()
|
||||
{
|
||||
return dictTypeMapper.selectDictTypeAll();
|
||||
}
|
||||
|
||||
/**
|
||||
* 根据字典类型查询字典数据
|
||||
*
|
||||
* @param dictType 字典类型
|
||||
* @return 字典数据集合信息
|
||||
*/
|
||||
@Override
|
||||
public List<SysDictData> selectDictDataByType(String dictType)
|
||||
{
|
||||
List<SysDictData> dictDatas = DictUtils.getDictCache(dictType);
|
||||
if (StringUtils.isNotEmpty(dictDatas))
|
||||
{
|
||||
return dictDatas;
|
||||
}
|
||||
dictDatas = dictDataMapper.selectDictDataByType(dictType);
|
||||
if (StringUtils.isNotEmpty(dictDatas))
|
||||
{
|
||||
DictUtils.setDictCache(dictType, dictDatas);
|
||||
return dictDatas;
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
* 根据字典类型ID查询信息
|
||||
*
|
||||
* @param dictId 字典类型ID
|
||||
* @return 字典类型
|
||||
*/
|
||||
@Override
|
||||
public SysDictType selectDictTypeById(Long dictId)
|
||||
{
|
||||
return dictTypeMapper.selectDictTypeById(dictId);
|
||||
}
|
||||
|
||||
/**
|
||||
* 根据字典类型查询信息
|
||||
*
|
||||
* @param dictType 字典类型
|
||||
* @return 字典类型
|
||||
*/
|
||||
@Override
|
||||
public SysDictType selectDictTypeByType(String dictType)
|
||||
{
|
||||
return dictTypeMapper.selectDictTypeByType(dictType);
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除字典类型信息
|
||||
*
|
||||
* @param dictIds 需要删除的字典ID
|
||||
*/
|
||||
@Override
|
||||
public void deleteDictTypeByIds(Long[] dictIds)
|
||||
{
|
||||
for (Long dictId : dictIds)
|
||||
{
|
||||
SysDictType dictType = selectDictTypeById(dictId);
|
||||
if (dictDataMapper.countDictDataByType(dictType.getDictType()) > 0)
|
||||
{
|
||||
throw new ServiceException(String.format("%1$s已分配,不能删除", dictType.getDictName()));
|
||||
}
|
||||
dictTypeMapper.deleteDictTypeById(dictId);
|
||||
DictUtils.removeDictCache(dictType.getDictType());
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 加载字典缓存数据
|
||||
*/
|
||||
@Override
|
||||
public void loadingDictCache()
|
||||
{
|
||||
SysDictData dictData = new SysDictData();
|
||||
dictData.setStatus("0");
|
||||
Map<String, List<SysDictData>> dictDataMap = dictDataMapper.selectDictDataList(dictData).stream().collect(Collectors.groupingBy(SysDictData::getDictType));
|
||||
for (Map.Entry<String, List<SysDictData>> entry : dictDataMap.entrySet())
|
||||
{
|
||||
DictUtils.setDictCache(entry.getKey(), entry.getValue().stream().sorted(Comparator.comparing(SysDictData::getDictSort)).collect(Collectors.toList()));
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 清空字典缓存数据
|
||||
*/
|
||||
@Override
|
||||
public void clearDictCache()
|
||||
{
|
||||
DictUtils.clearDictCache();
|
||||
}
|
||||
|
||||
/**
|
||||
* 重置字典缓存数据
|
||||
*/
|
||||
@Override
|
||||
public void resetDictCache()
|
||||
{
|
||||
clearDictCache();
|
||||
loadingDictCache();
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增保存字典类型信息
|
||||
*
|
||||
* @param dict 字典类型信息
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int insertDictType(SysDictType dict)
|
||||
{
|
||||
int row = dictTypeMapper.insertDictType(dict);
|
||||
if (row > 0)
|
||||
{
|
||||
DictUtils.setDictCache(dict.getDictType(), null);
|
||||
}
|
||||
return row;
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改保存字典类型信息
|
||||
*
|
||||
* @param dict 字典类型信息
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
@Transactional
|
||||
public int updateDictType(SysDictType dict)
|
||||
{
|
||||
SysDictType oldDict = dictTypeMapper.selectDictTypeById(dict.getDictId());
|
||||
dictDataMapper.updateDictDataType(oldDict.getDictType(), dict.getDictType());
|
||||
int row = dictTypeMapper.updateDictType(dict);
|
||||
if (row > 0)
|
||||
{
|
||||
List<SysDictData> dictDatas = dictDataMapper.selectDictDataByType(dict.getDictType());
|
||||
DictUtils.setDictCache(dict.getDictType(), dictDatas);
|
||||
}
|
||||
return row;
|
||||
}
|
||||
|
||||
/**
|
||||
* 校验字典类型称是否唯一
|
||||
*
|
||||
* @param dict 字典类型
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public String checkDictTypeUnique(SysDictType dict)
|
||||
{
|
||||
Long dictId = StringUtils.isNull(dict.getDictId()) ? -1L : dict.getDictId();
|
||||
SysDictType dictType = dictTypeMapper.checkDictTypeUnique(dict.getDictType());
|
||||
if (StringUtils.isNotNull(dictType) && dictType.getDictId().longValue() != dictId.longValue())
|
||||
{
|
||||
return UserConstants.NOT_UNIQUE;
|
||||
}
|
||||
return UserConstants.UNIQUE;
|
||||
}
|
||||
}
|
@ -0,0 +1,65 @@
|
||||
package com.ruoyi.system.service.impl;
|
||||
|
||||
import java.util.List;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import com.ruoyi.system.domain.SysLogininfor;
|
||||
import com.ruoyi.system.mapper.SysLogininforMapper;
|
||||
import com.ruoyi.system.service.ISysLogininforService;
|
||||
|
||||
/**
|
||||
* 系统访问日志情况信息 服务层处理
|
||||
*
|
||||
* @author ruoyi
|
||||
*/
|
||||
@Service
|
||||
public class SysLogininforServiceImpl implements ISysLogininforService
|
||||
{
|
||||
|
||||
@Autowired
|
||||
private SysLogininforMapper logininforMapper;
|
||||
|
||||
/**
|
||||
* 新增系统登录日志
|
||||
*
|
||||
* @param logininfor 访问日志对象
|
||||
*/
|
||||
@Override
|
||||
public void insertLogininfor(SysLogininfor logininfor)
|
||||
{
|
||||
logininforMapper.insertLogininfor(logininfor);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询系统登录日志集合
|
||||
*
|
||||
* @param logininfor 访问日志对象
|
||||
* @return 登录记录集合
|
||||
*/
|
||||
@Override
|
||||
public List<SysLogininfor> selectLogininforList(SysLogininfor logininfor)
|
||||
{
|
||||
return logininforMapper.selectLogininforList(logininfor);
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除系统登录日志
|
||||
*
|
||||
* @param infoIds 需要删除的登录日志ID
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deleteLogininforByIds(Long[] infoIds)
|
||||
{
|
||||
return logininforMapper.deleteLogininforByIds(infoIds);
|
||||
}
|
||||
|
||||
/**
|
||||
* 清空系统登录日志
|
||||
*/
|
||||
@Override
|
||||
public void cleanLogininfor()
|
||||
{
|
||||
logininforMapper.cleanLogininfor();
|
||||
}
|
||||
}
|
@ -0,0 +1,514 @@
|
||||
package com.ruoyi.system.service.impl;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.Arrays;
|
||||
import java.util.HashSet;
|
||||
import java.util.Iterator;
|
||||
import java.util.LinkedList;
|
||||
import java.util.List;
|
||||
import java.util.Set;
|
||||
import java.util.stream.Collectors;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import com.ruoyi.common.constant.Constants;
|
||||
import com.ruoyi.common.constant.UserConstants;
|
||||
import com.ruoyi.common.core.domain.TreeSelect;
|
||||
import com.ruoyi.common.core.domain.entity.SysMenu;
|
||||
import com.ruoyi.common.core.domain.entity.SysRole;
|
||||
import com.ruoyi.common.core.domain.entity.SysUser;
|
||||
import com.ruoyi.common.utils.SecurityUtils;
|
||||
import com.ruoyi.common.utils.StringUtils;
|
||||
import com.ruoyi.system.domain.vo.MetaVo;
|
||||
import com.ruoyi.system.domain.vo.RouterVo;
|
||||
import com.ruoyi.system.mapper.SysMenuMapper;
|
||||
import com.ruoyi.system.mapper.SysRoleMapper;
|
||||
import com.ruoyi.system.mapper.SysRoleMenuMapper;
|
||||
import com.ruoyi.system.service.ISysMenuService;
|
||||
|
||||
/**
|
||||
* 菜单 业务层处理
|
||||
*
|
||||
* @author ruoyi
|
||||
*/
|
||||
@Service
|
||||
public class SysMenuServiceImpl implements ISysMenuService
|
||||
{
|
||||
public static final String PREMISSION_STRING = "perms[\"{0}\"]";
|
||||
|
||||
@Autowired
|
||||
private SysMenuMapper menuMapper;
|
||||
|
||||
@Autowired
|
||||
private SysRoleMapper roleMapper;
|
||||
|
||||
@Autowired
|
||||
private SysRoleMenuMapper roleMenuMapper;
|
||||
|
||||
/**
|
||||
* 根据用户查询系统菜单列表
|
||||
*
|
||||
* @param userId 用户ID
|
||||
* @return 菜单列表
|
||||
*/
|
||||
@Override
|
||||
public List<SysMenu> selectMenuList(Long userId)
|
||||
{
|
||||
return selectMenuList(new SysMenu(), userId);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询系统菜单列表
|
||||
*
|
||||
* @param menu 菜单信息
|
||||
* @return 菜单列表
|
||||
*/
|
||||
@Override
|
||||
public List<SysMenu> selectMenuList(SysMenu menu, Long userId)
|
||||
{
|
||||
List<SysMenu> menuList = null;
|
||||
// 管理员显示所有菜单信息
|
||||
if (SysUser.isAdmin(userId))
|
||||
{
|
||||
menuList = menuMapper.selectMenuList(menu);
|
||||
}
|
||||
else
|
||||
{
|
||||
menu.getParams().put("userId", userId);
|
||||
menuList = menuMapper.selectMenuListByUserId(menu);
|
||||
}
|
||||
return menuList;
|
||||
}
|
||||
|
||||
/**
|
||||
* 根据用户ID查询权限
|
||||
*
|
||||
* @param userId 用户ID
|
||||
* @return 权限列表
|
||||
*/
|
||||
@Override
|
||||
public Set<String> selectMenuPermsByUserId(Long userId)
|
||||
{
|
||||
List<String> perms = menuMapper.selectMenuPermsByUserId(userId);
|
||||
Set<String> permsSet = new HashSet<>();
|
||||
for (String perm : perms)
|
||||
{
|
||||
if (StringUtils.isNotEmpty(perm))
|
||||
{
|
||||
permsSet.addAll(Arrays.asList(perm.trim().split(",")));
|
||||
}
|
||||
}
|
||||
return permsSet;
|
||||
}
|
||||
|
||||
/**
|
||||
* 根据用户ID查询菜单
|
||||
*
|
||||
* @param userId 用户名称
|
||||
* @return 菜单列表
|
||||
*/
|
||||
@Override
|
||||
public List<SysMenu> selectMenuTreeByUserId(Long userId)
|
||||
{
|
||||
List<SysMenu> menus = null;
|
||||
if (SecurityUtils.isAdmin(userId))
|
||||
{
|
||||
menus = menuMapper.selectMenuTreeAll();
|
||||
}
|
||||
else
|
||||
{
|
||||
menus = menuMapper.selectMenuTreeByUserId(userId);
|
||||
}
|
||||
return getChildPerms(menus, 0);
|
||||
}
|
||||
|
||||
/**
|
||||
* 根据角色ID查询菜单树信息
|
||||
*
|
||||
* @param roleId 角色ID
|
||||
* @return 选中菜单列表
|
||||
*/
|
||||
@Override
|
||||
public List<Long> selectMenuListByRoleId(Long roleId)
|
||||
{
|
||||
SysRole role = roleMapper.selectRoleById(roleId);
|
||||
return menuMapper.selectMenuListByRoleId(roleId, role.isMenuCheckStrictly());
|
||||
}
|
||||
|
||||
/**
|
||||
* 构建前端路由所需要的菜单
|
||||
*
|
||||
* @param menus 菜单列表
|
||||
* @return 路由列表
|
||||
*/
|
||||
@Override
|
||||
public List<RouterVo> buildMenus(List<SysMenu> menus)
|
||||
{
|
||||
List<RouterVo> routers = new LinkedList<RouterVo>();
|
||||
for (SysMenu menu : menus)
|
||||
{
|
||||
RouterVo router = new RouterVo();
|
||||
router.setHidden("1".equals(menu.getVisible()));
|
||||
router.setName(getRouteName(menu));
|
||||
router.setPath(getRouterPath(menu));
|
||||
router.setComponent(getComponent(menu));
|
||||
router.setQuery(menu.getQuery());
|
||||
router.setMeta(new MetaVo(menu.getMenuName(), menu.getIcon(), StringUtils.equals("1", menu.getIsCache()), menu.getPath()));
|
||||
List<SysMenu> cMenus = menu.getChildren();
|
||||
if (!cMenus.isEmpty() && cMenus.size() > 0 && UserConstants.TYPE_DIR.equals(menu.getMenuType()))
|
||||
{
|
||||
router.setAlwaysShow(true);
|
||||
router.setRedirect("noRedirect");
|
||||
router.setChildren(buildMenus(cMenus));
|
||||
}
|
||||
else if (isMenuFrame(menu))
|
||||
{
|
||||
router.setMeta(null);
|
||||
List<RouterVo> childrenList = new ArrayList<RouterVo>();
|
||||
RouterVo children = new RouterVo();
|
||||
children.setPath(menu.getPath());
|
||||
children.setComponent(menu.getComponent());
|
||||
children.setName(StringUtils.capitalize(menu.getPath()));
|
||||
children.setMeta(new MetaVo(menu.getMenuName(), menu.getIcon(), StringUtils.equals("1", menu.getIsCache()), menu.getPath()));
|
||||
children.setQuery(menu.getQuery());
|
||||
childrenList.add(children);
|
||||
router.setChildren(childrenList);
|
||||
}
|
||||
else if (menu.getParentId().intValue() == 0 && isInnerLink(menu))
|
||||
{
|
||||
router.setMeta(new MetaVo(menu.getMenuName(), menu.getIcon()));
|
||||
router.setPath("/");
|
||||
List<RouterVo> childrenList = new ArrayList<RouterVo>();
|
||||
RouterVo children = new RouterVo();
|
||||
String routerPath = innerLinkReplaceEach(menu.getPath());
|
||||
children.setPath(routerPath);
|
||||
children.setComponent(UserConstants.INNER_LINK);
|
||||
children.setName(StringUtils.capitalize(routerPath));
|
||||
children.setMeta(new MetaVo(menu.getMenuName(), menu.getIcon(), menu.getPath()));
|
||||
childrenList.add(children);
|
||||
router.setChildren(childrenList);
|
||||
}
|
||||
routers.add(router);
|
||||
}
|
||||
return routers;
|
||||
}
|
||||
|
||||
/**
|
||||
* 构建前端所需要树结构
|
||||
*
|
||||
* @param menus 菜单列表
|
||||
* @return 树结构列表
|
||||
*/
|
||||
@Override
|
||||
public List<SysMenu> buildMenuTree(List<SysMenu> menus)
|
||||
{
|
||||
List<SysMenu> returnList = new ArrayList<SysMenu>();
|
||||
List<Long> tempList = new ArrayList<Long>();
|
||||
for (SysMenu dept : menus)
|
||||
{
|
||||
tempList.add(dept.getMenuId());
|
||||
}
|
||||
for (Iterator<SysMenu> iterator = menus.iterator(); iterator.hasNext();)
|
||||
{
|
||||
SysMenu menu = (SysMenu) iterator.next();
|
||||
// 如果是顶级节点, 遍历该父节点的所有子节点
|
||||
if (!tempList.contains(menu.getParentId()))
|
||||
{
|
||||
recursionFn(menus, menu);
|
||||
returnList.add(menu);
|
||||
}
|
||||
}
|
||||
if (returnList.isEmpty())
|
||||
{
|
||||
returnList = menus;
|
||||
}
|
||||
return returnList;
|
||||
}
|
||||
|
||||
/**
|
||||
* 构建前端所需要下拉树结构
|
||||
*
|
||||
* @param menus 菜单列表
|
||||
* @return 下拉树结构列表
|
||||
*/
|
||||
@Override
|
||||
public List<TreeSelect> buildMenuTreeSelect(List<SysMenu> menus)
|
||||
{
|
||||
List<SysMenu> menuTrees = buildMenuTree(menus);
|
||||
return menuTrees.stream().map(TreeSelect::new).collect(Collectors.toList());
|
||||
}
|
||||
|
||||
/**
|
||||
* 根据菜单ID查询信息
|
||||
*
|
||||
* @param menuId 菜单ID
|
||||
* @return 菜单信息
|
||||
*/
|
||||
@Override
|
||||
public SysMenu selectMenuById(Long menuId)
|
||||
{
|
||||
return menuMapper.selectMenuById(menuId);
|
||||
}
|
||||
|
||||
/**
|
||||
* 是否存在菜单子节点
|
||||
*
|
||||
* @param menuId 菜单ID
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public boolean hasChildByMenuId(Long menuId)
|
||||
{
|
||||
int result = menuMapper.hasChildByMenuId(menuId);
|
||||
return result > 0 ? true : false;
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询菜单使用数量
|
||||
*
|
||||
* @param menuId 菜单ID
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public boolean checkMenuExistRole(Long menuId)
|
||||
{
|
||||
int result = roleMenuMapper.checkMenuExistRole(menuId);
|
||||
return result > 0 ? true : false;
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增保存菜单信息
|
||||
*
|
||||
* @param menu 菜单信息
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int insertMenu(SysMenu menu)
|
||||
{
|
||||
return menuMapper.insertMenu(menu);
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改保存菜单信息
|
||||
*
|
||||
* @param menu 菜单信息
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int updateMenu(SysMenu menu)
|
||||
{
|
||||
return menuMapper.updateMenu(menu);
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除菜单管理信息
|
||||
*
|
||||
* @param menuId 菜单ID
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deleteMenuById(Long menuId)
|
||||
{
|
||||
return menuMapper.deleteMenuById(menuId);
|
||||
}
|
||||
|
||||
/**
|
||||
* 校验菜单名称是否唯一
|
||||
*
|
||||
* @param menu 菜单信息
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public String checkMenuNameUnique(SysMenu menu)
|
||||
{
|
||||
Long menuId = StringUtils.isNull(menu.getMenuId()) ? -1L : menu.getMenuId();
|
||||
SysMenu info = menuMapper.checkMenuNameUnique(menu.getMenuName(), menu.getParentId());
|
||||
if (StringUtils.isNotNull(info) && info.getMenuId().longValue() != menuId.longValue())
|
||||
{
|
||||
return UserConstants.NOT_UNIQUE;
|
||||
}
|
||||
return UserConstants.UNIQUE;
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取路由名称
|
||||
*
|
||||
* @param menu 菜单信息
|
||||
* @return 路由名称
|
||||
*/
|
||||
public String getRouteName(SysMenu menu)
|
||||
{
|
||||
String routerName = StringUtils.capitalize(menu.getPath());
|
||||
// 非外链并且是一级目录(类型为目录)
|
||||
if (isMenuFrame(menu))
|
||||
{
|
||||
routerName = StringUtils.EMPTY;
|
||||
}
|
||||
return routerName;
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取路由地址
|
||||
*
|
||||
* @param menu 菜单信息
|
||||
* @return 路由地址
|
||||
*/
|
||||
public String getRouterPath(SysMenu menu)
|
||||
{
|
||||
String routerPath = menu.getPath();
|
||||
// 内链打开外网方式
|
||||
if (menu.getParentId().intValue() != 0 && isInnerLink(menu))
|
||||
{
|
||||
routerPath = innerLinkReplaceEach(routerPath);
|
||||
}
|
||||
// 非外链并且是一级目录(类型为目录)
|
||||
if (0 == menu.getParentId().intValue() && UserConstants.TYPE_DIR.equals(menu.getMenuType())
|
||||
&& UserConstants.NO_FRAME.equals(menu.getIsFrame()))
|
||||
{
|
||||
routerPath = "/" + menu.getPath();
|
||||
}
|
||||
// 非外链并且是一级目录(类型为菜单)
|
||||
else if (isMenuFrame(menu))
|
||||
{
|
||||
routerPath = "/";
|
||||
}
|
||||
return routerPath;
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取组件信息
|
||||
*
|
||||
* @param menu 菜单信息
|
||||
* @return 组件信息
|
||||
*/
|
||||
public String getComponent(SysMenu menu)
|
||||
{
|
||||
String component = UserConstants.LAYOUT;
|
||||
if (StringUtils.isNotEmpty(menu.getComponent()) && !isMenuFrame(menu))
|
||||
{
|
||||
component = menu.getComponent();
|
||||
}
|
||||
else if (StringUtils.isEmpty(menu.getComponent()) && menu.getParentId().intValue() != 0 && isInnerLink(menu))
|
||||
{
|
||||
component = UserConstants.INNER_LINK;
|
||||
}
|
||||
else if (StringUtils.isEmpty(menu.getComponent()) && isParentView(menu))
|
||||
{
|
||||
component = UserConstants.PARENT_VIEW;
|
||||
}
|
||||
return component;
|
||||
}
|
||||
|
||||
/**
|
||||
* 是否为菜单内部跳转
|
||||
*
|
||||
* @param menu 菜单信息
|
||||
* @return 结果
|
||||
*/
|
||||
public boolean isMenuFrame(SysMenu menu)
|
||||
{
|
||||
return menu.getParentId().intValue() == 0 && UserConstants.TYPE_MENU.equals(menu.getMenuType())
|
||||
&& menu.getIsFrame().equals(UserConstants.NO_FRAME);
|
||||
}
|
||||
|
||||
/**
|
||||
* 是否为内链组件
|
||||
*
|
||||
* @param menu 菜单信息
|
||||
* @return 结果
|
||||
*/
|
||||
public boolean isInnerLink(SysMenu menu)
|
||||
{
|
||||
return menu.getIsFrame().equals(UserConstants.NO_FRAME) && StringUtils.ishttp(menu.getPath());
|
||||
}
|
||||
|
||||
/**
|
||||
* 是否为parent_view组件
|
||||
*
|
||||
* @param menu 菜单信息
|
||||
* @return 结果
|
||||
*/
|
||||
public boolean isParentView(SysMenu menu)
|
||||
{
|
||||
return menu.getParentId().intValue() != 0 && UserConstants.TYPE_DIR.equals(menu.getMenuType());
|
||||
}
|
||||
|
||||
/**
|
||||
* 根据父节点的ID获取所有子节点
|
||||
*
|
||||
* @param list 分类表
|
||||
* @param parentId 传入的父节点ID
|
||||
* @return String
|
||||
*/
|
||||
public List<SysMenu> getChildPerms(List<SysMenu> list, int parentId)
|
||||
{
|
||||
List<SysMenu> returnList = new ArrayList<SysMenu>();
|
||||
for (Iterator<SysMenu> iterator = list.iterator(); iterator.hasNext();)
|
||||
{
|
||||
SysMenu t = (SysMenu) iterator.next();
|
||||
// 一、根据传入的某个父节点ID,遍历该父节点的所有子节点
|
||||
if (t.getParentId() == parentId)
|
||||
{
|
||||
recursionFn(list, t);
|
||||
returnList.add(t);
|
||||
}
|
||||
}
|
||||
return returnList;
|
||||
}
|
||||
|
||||
/**
|
||||
* 递归列表
|
||||
*
|
||||
* @param list
|
||||
* @param t
|
||||
*/
|
||||
private void recursionFn(List<SysMenu> list, SysMenu t)
|
||||
{
|
||||
// 得到子节点列表
|
||||
List<SysMenu> childList = getChildList(list, t);
|
||||
t.setChildren(childList);
|
||||
for (SysMenu tChild : childList)
|
||||
{
|
||||
if (hasChild(list, tChild))
|
||||
{
|
||||
recursionFn(list, tChild);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 得到子节点列表
|
||||
*/
|
||||
private List<SysMenu> getChildList(List<SysMenu> list, SysMenu t)
|
||||
{
|
||||
List<SysMenu> tlist = new ArrayList<SysMenu>();
|
||||
Iterator<SysMenu> it = list.iterator();
|
||||
while (it.hasNext())
|
||||
{
|
||||
SysMenu n = (SysMenu) it.next();
|
||||
if (n.getParentId().longValue() == t.getMenuId().longValue())
|
||||
{
|
||||
tlist.add(n);
|
||||
}
|
||||
}
|
||||
return tlist;
|
||||
}
|
||||
|
||||
/**
|
||||
* 判断是否有子节点
|
||||
*/
|
||||
private boolean hasChild(List<SysMenu> list, SysMenu t)
|
||||
{
|
||||
return getChildList(list, t).size() > 0;
|
||||
}
|
||||
|
||||
/**
|
||||
* 内链域名特殊字符替换
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
public String innerLinkReplaceEach(String path)
|
||||
{
|
||||
return StringUtils.replaceEach(path, new String[] { Constants.HTTP, Constants.HTTPS },
|
||||
new String[] { "", "" });
|
||||
}
|
||||
}
|
@ -0,0 +1,92 @@
|
||||
package com.ruoyi.system.service.impl;
|
||||
|
||||
import java.util.List;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import com.ruoyi.system.domain.SysNotice;
|
||||
import com.ruoyi.system.mapper.SysNoticeMapper;
|
||||
import com.ruoyi.system.service.ISysNoticeService;
|
||||
|
||||
/**
|
||||
* 公告 服务层实现
|
||||
*
|
||||
* @author ruoyi
|
||||
*/
|
||||
@Service
|
||||
public class SysNoticeServiceImpl implements ISysNoticeService
|
||||
{
|
||||
@Autowired
|
||||
private SysNoticeMapper noticeMapper;
|
||||
|
||||
/**
|
||||
* 查询公告信息
|
||||
*
|
||||
* @param noticeId 公告ID
|
||||
* @return 公告信息
|
||||
*/
|
||||
@Override
|
||||
public SysNotice selectNoticeById(Long noticeId)
|
||||
{
|
||||
return noticeMapper.selectNoticeById(noticeId);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询公告列表
|
||||
*
|
||||
* @param notice 公告信息
|
||||
* @return 公告集合
|
||||
*/
|
||||
@Override
|
||||
public List<SysNotice> selectNoticeList(SysNotice notice)
|
||||
{
|
||||
return noticeMapper.selectNoticeList(notice);
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增公告
|
||||
*
|
||||
* @param notice 公告信息
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int insertNotice(SysNotice notice)
|
||||
{
|
||||
return noticeMapper.insertNotice(notice);
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改公告
|
||||
*
|
||||
* @param notice 公告信息
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int updateNotice(SysNotice notice)
|
||||
{
|
||||
return noticeMapper.updateNotice(notice);
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除公告对象
|
||||
*
|
||||
* @param noticeId 公告ID
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deleteNoticeById(Long noticeId)
|
||||
{
|
||||
return noticeMapper.deleteNoticeById(noticeId);
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除公告信息
|
||||
*
|
||||
* @param noticeIds 需要删除的公告ID
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deleteNoticeByIds(Long[] noticeIds)
|
||||
{
|
||||
return noticeMapper.deleteNoticeByIds(noticeIds);
|
||||
}
|
||||
}
|
@ -0,0 +1,76 @@
|
||||
package com.ruoyi.system.service.impl;
|
||||
|
||||
import java.util.List;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import com.ruoyi.system.domain.SysOperLog;
|
||||
import com.ruoyi.system.mapper.SysOperLogMapper;
|
||||
import com.ruoyi.system.service.ISysOperLogService;
|
||||
|
||||
/**
|
||||
* 操作日志 服务层处理
|
||||
*
|
||||
* @author ruoyi
|
||||
*/
|
||||
@Service
|
||||
public class SysOperLogServiceImpl implements ISysOperLogService
|
||||
{
|
||||
@Autowired
|
||||
private SysOperLogMapper operLogMapper;
|
||||
|
||||
/**
|
||||
* 新增操作日志
|
||||
*
|
||||
* @param operLog 操作日志对象
|
||||
*/
|
||||
@Override
|
||||
public void insertOperlog(SysOperLog operLog)
|
||||
{
|
||||
operLogMapper.insertOperlog(operLog);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询系统操作日志集合
|
||||
*
|
||||
* @param operLog 操作日志对象
|
||||
* @return 操作日志集合
|
||||
*/
|
||||
@Override
|
||||
public List<SysOperLog> selectOperLogList(SysOperLog operLog)
|
||||
{
|
||||
return operLogMapper.selectOperLogList(operLog);
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除系统操作日志
|
||||
*
|
||||
* @param operIds 需要删除的操作日志ID
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deleteOperLogByIds(Long[] operIds)
|
||||
{
|
||||
return operLogMapper.deleteOperLogByIds(operIds);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询操作日志详细
|
||||
*
|
||||
* @param operId 操作ID
|
||||
* @return 操作日志对象
|
||||
*/
|
||||
@Override
|
||||
public SysOperLog selectOperLogById(Long operId)
|
||||
{
|
||||
return operLogMapper.selectOperLogById(operId);
|
||||
}
|
||||
|
||||
/**
|
||||
* 清空操作日志
|
||||
*/
|
||||
@Override
|
||||
public void cleanOperLog()
|
||||
{
|
||||
operLogMapper.cleanOperLog();
|
||||
}
|
||||
}
|
@ -0,0 +1,178 @@
|
||||
package com.ruoyi.system.service.impl;
|
||||
|
||||
import java.util.List;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import com.ruoyi.common.constant.UserConstants;
|
||||
import com.ruoyi.common.exception.ServiceException;
|
||||
import com.ruoyi.common.utils.StringUtils;
|
||||
import com.ruoyi.system.domain.SysPost;
|
||||
import com.ruoyi.system.mapper.SysPostMapper;
|
||||
import com.ruoyi.system.mapper.SysUserPostMapper;
|
||||
import com.ruoyi.system.service.ISysPostService;
|
||||
|
||||
/**
|
||||
* 岗位信息 服务层处理
|
||||
*
|
||||
* @author ruoyi
|
||||
*/
|
||||
@Service
|
||||
public class SysPostServiceImpl implements ISysPostService
|
||||
{
|
||||
@Autowired
|
||||
private SysPostMapper postMapper;
|
||||
|
||||
@Autowired
|
||||
private SysUserPostMapper userPostMapper;
|
||||
|
||||
/**
|
||||
* 查询岗位信息集合
|
||||
*
|
||||
* @param post 岗位信息
|
||||
* @return 岗位信息集合
|
||||
*/
|
||||
@Override
|
||||
public List<SysPost> selectPostList(SysPost post)
|
||||
{
|
||||
return postMapper.selectPostList(post);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询所有岗位
|
||||
*
|
||||
* @return 岗位列表
|
||||
*/
|
||||
@Override
|
||||
public List<SysPost> selectPostAll()
|
||||
{
|
||||
return postMapper.selectPostAll();
|
||||
}
|
||||
|
||||
/**
|
||||
* 通过岗位ID查询岗位信息
|
||||
*
|
||||
* @param postId 岗位ID
|
||||
* @return 角色对象信息
|
||||
*/
|
||||
@Override
|
||||
public SysPost selectPostById(Long postId)
|
||||
{
|
||||
return postMapper.selectPostById(postId);
|
||||
}
|
||||
|
||||
/**
|
||||
* 根据用户ID获取岗位选择框列表
|
||||
*
|
||||
* @param userId 用户ID
|
||||
* @return 选中岗位ID列表
|
||||
*/
|
||||
@Override
|
||||
public List<Long> selectPostListByUserId(Long userId)
|
||||
{
|
||||
return postMapper.selectPostListByUserId(userId);
|
||||
}
|
||||
|
||||
/**
|
||||
* 校验岗位名称是否唯一
|
||||
*
|
||||
* @param post 岗位信息
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public String checkPostNameUnique(SysPost post)
|
||||
{
|
||||
Long postId = StringUtils.isNull(post.getPostId()) ? -1L : post.getPostId();
|
||||
SysPost info = postMapper.checkPostNameUnique(post.getPostName());
|
||||
if (StringUtils.isNotNull(info) && info.getPostId().longValue() != postId.longValue())
|
||||
{
|
||||
return UserConstants.NOT_UNIQUE;
|
||||
}
|
||||
return UserConstants.UNIQUE;
|
||||
}
|
||||
|
||||
/**
|
||||
* 校验岗位编码是否唯一
|
||||
*
|
||||
* @param post 岗位信息
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public String checkPostCodeUnique(SysPost post)
|
||||
{
|
||||
Long postId = StringUtils.isNull(post.getPostId()) ? -1L : post.getPostId();
|
||||
SysPost info = postMapper.checkPostCodeUnique(post.getPostCode());
|
||||
if (StringUtils.isNotNull(info) && info.getPostId().longValue() != postId.longValue())
|
||||
{
|
||||
return UserConstants.NOT_UNIQUE;
|
||||
}
|
||||
return UserConstants.UNIQUE;
|
||||
}
|
||||
|
||||
/**
|
||||
* 通过岗位ID查询岗位使用数量
|
||||
*
|
||||
* @param postId 岗位ID
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int countUserPostById(Long postId)
|
||||
{
|
||||
return userPostMapper.countUserPostById(postId);
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除岗位信息
|
||||
*
|
||||
* @param postId 岗位ID
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deletePostById(Long postId)
|
||||
{
|
||||
return postMapper.deletePostById(postId);
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除岗位信息
|
||||
*
|
||||
* @param postIds 需要删除的岗位ID
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deletePostByIds(Long[] postIds)
|
||||
{
|
||||
for (Long postId : postIds)
|
||||
{
|
||||
SysPost post = selectPostById(postId);
|
||||
if (countUserPostById(postId) > 0)
|
||||
{
|
||||
throw new ServiceException(String.format("%1$s已分配,不能删除", post.getPostName()));
|
||||
}
|
||||
}
|
||||
return postMapper.deletePostByIds(postIds);
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增保存岗位信息
|
||||
*
|
||||
* @param post 岗位信息
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int insertPost(SysPost post)
|
||||
{
|
||||
return postMapper.insertPost(post);
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改保存岗位信息
|
||||
*
|
||||
* @param post 岗位信息
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int updatePost(SysPost post)
|
||||
{
|
||||
return postMapper.updatePost(post);
|
||||
}
|
||||
}
|
@ -0,0 +1,424 @@
|
||||
package com.ruoyi.system.service.impl;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.Arrays;
|
||||
import java.util.HashSet;
|
||||
import java.util.List;
|
||||
import java.util.Set;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
import com.ruoyi.common.annotation.DataScope;
|
||||
import com.ruoyi.common.constant.UserConstants;
|
||||
import com.ruoyi.common.core.domain.entity.SysRole;
|
||||
import com.ruoyi.common.core.domain.entity.SysUser;
|
||||
import com.ruoyi.common.exception.ServiceException;
|
||||
import com.ruoyi.common.utils.SecurityUtils;
|
||||
import com.ruoyi.common.utils.StringUtils;
|
||||
import com.ruoyi.common.utils.spring.SpringUtils;
|
||||
import com.ruoyi.system.domain.SysRoleDept;
|
||||
import com.ruoyi.system.domain.SysRoleMenu;
|
||||
import com.ruoyi.system.domain.SysUserRole;
|
||||
import com.ruoyi.system.mapper.SysRoleDeptMapper;
|
||||
import com.ruoyi.system.mapper.SysRoleMapper;
|
||||
import com.ruoyi.system.mapper.SysRoleMenuMapper;
|
||||
import com.ruoyi.system.mapper.SysUserRoleMapper;
|
||||
import com.ruoyi.system.service.ISysRoleService;
|
||||
|
||||
/**
|
||||
* 角色 业务层处理
|
||||
*
|
||||
* @author ruoyi
|
||||
*/
|
||||
@Service
|
||||
public class SysRoleServiceImpl implements ISysRoleService
|
||||
{
|
||||
@Autowired
|
||||
private SysRoleMapper roleMapper;
|
||||
|
||||
@Autowired
|
||||
private SysRoleMenuMapper roleMenuMapper;
|
||||
|
||||
@Autowired
|
||||
private SysUserRoleMapper userRoleMapper;
|
||||
|
||||
@Autowired
|
||||
private SysRoleDeptMapper roleDeptMapper;
|
||||
|
||||
/**
|
||||
* 根据条件分页查询角色数据
|
||||
*
|
||||
* @param role 角色信息
|
||||
* @return 角色数据集合信息
|
||||
*/
|
||||
@Override
|
||||
@DataScope(deptAlias = "d")
|
||||
public List<SysRole> selectRoleList(SysRole role)
|
||||
{
|
||||
return roleMapper.selectRoleList(role);
|
||||
}
|
||||
|
||||
/**
|
||||
* 根据用户ID查询角色
|
||||
*
|
||||
* @param userId 用户ID
|
||||
* @return 角色列表
|
||||
*/
|
||||
@Override
|
||||
public List<SysRole> selectRolesByUserId(Long userId)
|
||||
{
|
||||
List<SysRole> userRoles = roleMapper.selectRolePermissionByUserId(userId);
|
||||
List<SysRole> roles = selectRoleAll();
|
||||
for (SysRole role : roles)
|
||||
{
|
||||
for (SysRole userRole : userRoles)
|
||||
{
|
||||
if (role.getRoleId().longValue() == userRole.getRoleId().longValue())
|
||||
{
|
||||
role.setFlag(true);
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
return roles;
|
||||
}
|
||||
|
||||
/**
|
||||
* 根据用户ID查询权限
|
||||
*
|
||||
* @param userId 用户ID
|
||||
* @return 权限列表
|
||||
*/
|
||||
@Override
|
||||
public Set<String> selectRolePermissionByUserId(Long userId)
|
||||
{
|
||||
List<SysRole> perms = roleMapper.selectRolePermissionByUserId(userId);
|
||||
Set<String> permsSet = new HashSet<>();
|
||||
for (SysRole perm : perms)
|
||||
{
|
||||
if (StringUtils.isNotNull(perm))
|
||||
{
|
||||
permsSet.addAll(Arrays.asList(perm.getRoleKey().trim().split(",")));
|
||||
}
|
||||
}
|
||||
return permsSet;
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询所有角色
|
||||
*
|
||||
* @return 角色列表
|
||||
*/
|
||||
@Override
|
||||
public List<SysRole> selectRoleAll()
|
||||
{
|
||||
return SpringUtils.getAopProxy(this).selectRoleList(new SysRole());
|
||||
}
|
||||
|
||||
/**
|
||||
* 根据用户ID获取角色选择框列表
|
||||
*
|
||||
* @param userId 用户ID
|
||||
* @return 选中角色ID列表
|
||||
*/
|
||||
@Override
|
||||
public List<Long> selectRoleListByUserId(Long userId)
|
||||
{
|
||||
return roleMapper.selectRoleListByUserId(userId);
|
||||
}
|
||||
|
||||
/**
|
||||
* 通过角色ID查询角色
|
||||
*
|
||||
* @param roleId 角色ID
|
||||
* @return 角色对象信息
|
||||
*/
|
||||
@Override
|
||||
public SysRole selectRoleById(Long roleId)
|
||||
{
|
||||
return roleMapper.selectRoleById(roleId);
|
||||
}
|
||||
|
||||
/**
|
||||
* 校验角色名称是否唯一
|
||||
*
|
||||
* @param role 角色信息
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public String checkRoleNameUnique(SysRole role)
|
||||
{
|
||||
Long roleId = StringUtils.isNull(role.getRoleId()) ? -1L : role.getRoleId();
|
||||
SysRole info = roleMapper.checkRoleNameUnique(role.getRoleName());
|
||||
if (StringUtils.isNotNull(info) && info.getRoleId().longValue() != roleId.longValue())
|
||||
{
|
||||
return UserConstants.NOT_UNIQUE;
|
||||
}
|
||||
return UserConstants.UNIQUE;
|
||||
}
|
||||
|
||||
/**
|
||||
* 校验角色权限是否唯一
|
||||
*
|
||||
* @param role 角色信息
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public String checkRoleKeyUnique(SysRole role)
|
||||
{
|
||||
Long roleId = StringUtils.isNull(role.getRoleId()) ? -1L : role.getRoleId();
|
||||
SysRole info = roleMapper.checkRoleKeyUnique(role.getRoleKey());
|
||||
if (StringUtils.isNotNull(info) && info.getRoleId().longValue() != roleId.longValue())
|
||||
{
|
||||
return UserConstants.NOT_UNIQUE;
|
||||
}
|
||||
return UserConstants.UNIQUE;
|
||||
}
|
||||
|
||||
/**
|
||||
* 校验角色是否允许操作
|
||||
*
|
||||
* @param role 角色信息
|
||||
*/
|
||||
@Override
|
||||
public void checkRoleAllowed(SysRole role)
|
||||
{
|
||||
if (StringUtils.isNotNull(role.getRoleId()) && role.isAdmin())
|
||||
{
|
||||
throw new ServiceException("不允许操作超级管理员角色");
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 校验角色是否有数据权限
|
||||
*
|
||||
* @param roleId 角色id
|
||||
*/
|
||||
@Override
|
||||
public void checkRoleDataScope(Long roleId)
|
||||
{
|
||||
if (!SysUser.isAdmin(SecurityUtils.getUserId()))
|
||||
{
|
||||
SysRole role = new SysRole();
|
||||
role.setRoleId(roleId);
|
||||
List<SysRole> roles = SpringUtils.getAopProxy(this).selectRoleList(role);
|
||||
if (StringUtils.isEmpty(roles))
|
||||
{
|
||||
throw new ServiceException("没有权限访问角色数据!");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 通过角色ID查询角色使用数量
|
||||
*
|
||||
* @param roleId 角色ID
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int countUserRoleByRoleId(Long roleId)
|
||||
{
|
||||
return userRoleMapper.countUserRoleByRoleId(roleId);
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增保存角色信息
|
||||
*
|
||||
* @param role 角色信息
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
@Transactional
|
||||
public int insertRole(SysRole role)
|
||||
{
|
||||
// 新增角色信息
|
||||
roleMapper.insertRole(role);
|
||||
return insertRoleMenu(role);
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改保存角色信息
|
||||
*
|
||||
* @param role 角色信息
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
@Transactional
|
||||
public int updateRole(SysRole role)
|
||||
{
|
||||
// 修改角色信息
|
||||
roleMapper.updateRole(role);
|
||||
// 删除角色与菜单关联
|
||||
roleMenuMapper.deleteRoleMenuByRoleId(role.getRoleId());
|
||||
return insertRoleMenu(role);
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改角色状态
|
||||
*
|
||||
* @param role 角色信息
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int updateRoleStatus(SysRole role)
|
||||
{
|
||||
return roleMapper.updateRole(role);
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改数据权限信息
|
||||
*
|
||||
* @param role 角色信息
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
@Transactional
|
||||
public int authDataScope(SysRole role)
|
||||
{
|
||||
// 修改角色信息
|
||||
roleMapper.updateRole(role);
|
||||
// 删除角色与部门关联
|
||||
roleDeptMapper.deleteRoleDeptByRoleId(role.getRoleId());
|
||||
// 新增角色和部门信息(数据权限)
|
||||
return insertRoleDept(role);
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增角色菜单信息
|
||||
*
|
||||
* @param role 角色对象
|
||||
*/
|
||||
public int insertRoleMenu(SysRole role)
|
||||
{
|
||||
int rows = 1;
|
||||
// 新增用户与角色管理
|
||||
List<SysRoleMenu> list = new ArrayList<SysRoleMenu>();
|
||||
for (Long menuId : role.getMenuIds())
|
||||
{
|
||||
SysRoleMenu rm = new SysRoleMenu();
|
||||
rm.setRoleId(role.getRoleId());
|
||||
rm.setMenuId(menuId);
|
||||
list.add(rm);
|
||||
}
|
||||
if (list.size() > 0)
|
||||
{
|
||||
rows = roleMenuMapper.batchRoleMenu(list);
|
||||
}
|
||||
return rows;
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增角色部门信息(数据权限)
|
||||
*
|
||||
* @param role 角色对象
|
||||
*/
|
||||
public int insertRoleDept(SysRole role)
|
||||
{
|
||||
int rows = 1;
|
||||
// 新增角色与部门(数据权限)管理
|
||||
List<SysRoleDept> list = new ArrayList<SysRoleDept>();
|
||||
for (Long deptId : role.getDeptIds())
|
||||
{
|
||||
SysRoleDept rd = new SysRoleDept();
|
||||
rd.setRoleId(role.getRoleId());
|
||||
rd.setDeptId(deptId);
|
||||
list.add(rd);
|
||||
}
|
||||
if (list.size() > 0)
|
||||
{
|
||||
rows = roleDeptMapper.batchRoleDept(list);
|
||||
}
|
||||
return rows;
|
||||
}
|
||||
|
||||
/**
|
||||
* 通过角色ID删除角色
|
||||
*
|
||||
* @param roleId 角色ID
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
@Transactional
|
||||
public int deleteRoleById(Long roleId)
|
||||
{
|
||||
// 删除角色与菜单关联
|
||||
roleMenuMapper.deleteRoleMenuByRoleId(roleId);
|
||||
// 删除角色与部门关联
|
||||
roleDeptMapper.deleteRoleDeptByRoleId(roleId);
|
||||
return roleMapper.deleteRoleById(roleId);
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除角色信息
|
||||
*
|
||||
* @param roleIds 需要删除的角色ID
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
@Transactional
|
||||
public int deleteRoleByIds(Long[] roleIds)
|
||||
{
|
||||
for (Long roleId : roleIds)
|
||||
{
|
||||
checkRoleAllowed(new SysRole(roleId));
|
||||
checkRoleDataScope(roleId);
|
||||
SysRole role = selectRoleById(roleId);
|
||||
if (countUserRoleByRoleId(roleId) > 0)
|
||||
{
|
||||
throw new ServiceException(String.format("%1$s已分配,不能删除", role.getRoleName()));
|
||||
}
|
||||
}
|
||||
// 删除角色与菜单关联
|
||||
roleMenuMapper.deleteRoleMenu(roleIds);
|
||||
// 删除角色与部门关联
|
||||
roleDeptMapper.deleteRoleDept(roleIds);
|
||||
return roleMapper.deleteRoleByIds(roleIds);
|
||||
}
|
||||
|
||||
/**
|
||||
* 取消授权用户角色
|
||||
*
|
||||
* @param userRole 用户和角色关联信息
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deleteAuthUser(SysUserRole userRole)
|
||||
{
|
||||
return userRoleMapper.deleteUserRoleInfo(userRole);
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量取消授权用户角色
|
||||
*
|
||||
* @param roleId 角色ID
|
||||
* @param userIds 需要取消授权的用户数据ID
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deleteAuthUsers(Long roleId, Long[] userIds)
|
||||
{
|
||||
return userRoleMapper.deleteUserRoleInfos(roleId, userIds);
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量选择授权用户角色
|
||||
*
|
||||
* @param roleId 角色ID
|
||||
* @param userIds 需要授权的用户数据ID
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int insertAuthUsers(Long roleId, Long[] userIds)
|
||||
{
|
||||
// 新增用户与角色管理
|
||||
List<SysUserRole> list = new ArrayList<SysUserRole>();
|
||||
for (Long userId : userIds)
|
||||
{
|
||||
SysUserRole ur = new SysUserRole();
|
||||
ur.setUserId(userId);
|
||||
ur.setRoleId(roleId);
|
||||
list.add(ur);
|
||||
}
|
||||
return userRoleMapper.batchUserRole(list);
|
||||
}
|
||||
}
|
@ -0,0 +1,96 @@
|
||||
package com.ruoyi.system.service.impl;
|
||||
|
||||
import org.springframework.stereotype.Service;
|
||||
import com.ruoyi.common.core.domain.model.LoginUser;
|
||||
import com.ruoyi.common.utils.StringUtils;
|
||||
import com.ruoyi.system.domain.SysUserOnline;
|
||||
import com.ruoyi.system.service.ISysUserOnlineService;
|
||||
|
||||
/**
|
||||
* 在线用户 服务层处理
|
||||
*
|
||||
* @author ruoyi
|
||||
*/
|
||||
@Service
|
||||
public class SysUserOnlineServiceImpl implements ISysUserOnlineService
|
||||
{
|
||||
/**
|
||||
* 通过登录地址查询信息
|
||||
*
|
||||
* @param ipaddr 登录地址
|
||||
* @param user 用户信息
|
||||
* @return 在线用户信息
|
||||
*/
|
||||
@Override
|
||||
public SysUserOnline selectOnlineByIpaddr(String ipaddr, LoginUser user)
|
||||
{
|
||||
if (StringUtils.equals(ipaddr, user.getIpaddr()))
|
||||
{
|
||||
return loginUserToUserOnline(user);
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
* 通过用户名称查询信息
|
||||
*
|
||||
* @param userName 用户名称
|
||||
* @param user 用户信息
|
||||
* @return 在线用户信息
|
||||
*/
|
||||
@Override
|
||||
public SysUserOnline selectOnlineByUserName(String userName, LoginUser user)
|
||||
{
|
||||
if (StringUtils.equals(userName, user.getUsername()))
|
||||
{
|
||||
return loginUserToUserOnline(user);
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
* 通过登录地址/用户名称查询信息
|
||||
*
|
||||
* @param ipaddr 登录地址
|
||||
* @param userName 用户名称
|
||||
* @param user 用户信息
|
||||
* @return 在线用户信息
|
||||
*/
|
||||
@Override
|
||||
public SysUserOnline selectOnlineByInfo(String ipaddr, String userName, LoginUser user)
|
||||
{
|
||||
if (StringUtils.equals(ipaddr, user.getIpaddr()) && StringUtils.equals(userName, user.getUsername()))
|
||||
{
|
||||
return loginUserToUserOnline(user);
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
* 设置在线用户信息
|
||||
*
|
||||
* @param user 用户信息
|
||||
* @return 在线用户
|
||||
*/
|
||||
@Override
|
||||
public SysUserOnline loginUserToUserOnline(LoginUser user)
|
||||
{
|
||||
if (StringUtils.isNull(user) || StringUtils.isNull(user.getUser()))
|
||||
{
|
||||
return null;
|
||||
}
|
||||
SysUserOnline sysUserOnline = new SysUserOnline();
|
||||
sysUserOnline.setTokenId(user.getToken());
|
||||
sysUserOnline.setUserName(user.getUsername());
|
||||
sysUserOnline.setIpaddr(user.getIpaddr());
|
||||
sysUserOnline.setLoginLocation(user.getLoginLocation());
|
||||
sysUserOnline.setBrowser(user.getBrowser());
|
||||
sysUserOnline.setOs(user.getOs());
|
||||
sysUserOnline.setLoginTime(user.getLoginTime());
|
||||
if (StringUtils.isNotNull(user.getUser().getDept()))
|
||||
{
|
||||
sysUserOnline.setDeptName(user.getUser().getDept().getDeptName());
|
||||
}
|
||||
return sysUserOnline;
|
||||
}
|
||||
}
|
@ -0,0 +1,562 @@
|
||||
package com.ruoyi.system.service.impl;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
import java.util.stream.Collectors;
|
||||
import javax.validation.Validator;
|
||||
import org.slf4j.Logger;
|
||||
import org.slf4j.LoggerFactory;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
import org.springframework.util.CollectionUtils;
|
||||
import com.ruoyi.common.annotation.DataScope;
|
||||
import com.ruoyi.common.constant.UserConstants;
|
||||
import com.ruoyi.common.core.domain.entity.SysRole;
|
||||
import com.ruoyi.common.core.domain.entity.SysUser;
|
||||
import com.ruoyi.common.exception.ServiceException;
|
||||
import com.ruoyi.common.utils.SecurityUtils;
|
||||
import com.ruoyi.common.utils.StringUtils;
|
||||
import com.ruoyi.common.utils.bean.BeanValidators;
|
||||
import com.ruoyi.common.utils.spring.SpringUtils;
|
||||
import com.ruoyi.system.domain.SysPost;
|
||||
import com.ruoyi.system.domain.SysUserPost;
|
||||
import com.ruoyi.system.domain.SysUserRole;
|
||||
import com.ruoyi.system.mapper.SysPostMapper;
|
||||
import com.ruoyi.system.mapper.SysRoleMapper;
|
||||
import com.ruoyi.system.mapper.SysUserMapper;
|
||||
import com.ruoyi.system.mapper.SysUserPostMapper;
|
||||
import com.ruoyi.system.mapper.SysUserRoleMapper;
|
||||
import com.ruoyi.system.service.ISysConfigService;
|
||||
import com.ruoyi.system.service.ISysUserService;
|
||||
|
||||
/**
|
||||
* 用户 业务层处理
|
||||
*
|
||||
* @author ruoyi
|
||||
*/
|
||||
@Service
|
||||
public class SysUserServiceImpl implements ISysUserService
|
||||
{
|
||||
private static final Logger log = LoggerFactory.getLogger(SysUserServiceImpl.class);
|
||||
|
||||
@Autowired
|
||||
private SysUserMapper userMapper;
|
||||
|
||||
@Autowired
|
||||
private SysRoleMapper roleMapper;
|
||||
|
||||
@Autowired
|
||||
private SysPostMapper postMapper;
|
||||
|
||||
@Autowired
|
||||
private SysUserRoleMapper userRoleMapper;
|
||||
|
||||
@Autowired
|
||||
private SysUserPostMapper userPostMapper;
|
||||
|
||||
@Autowired
|
||||
private ISysConfigService configService;
|
||||
|
||||
@Autowired
|
||||
protected Validator validator;
|
||||
|
||||
/**
|
||||
* 根据条件分页查询用户列表
|
||||
*
|
||||
* @param user 用户信息
|
||||
* @return 用户信息集合信息
|
||||
*/
|
||||
@Override
|
||||
@DataScope(deptAlias = "d", userAlias = "u")
|
||||
public List<SysUser> selectUserList(SysUser user)
|
||||
{
|
||||
return userMapper.selectUserList(user);
|
||||
}
|
||||
|
||||
/**
|
||||
* 根据条件分页查询已分配用户角色列表
|
||||
*
|
||||
* @param user 用户信息
|
||||
* @return 用户信息集合信息
|
||||
*/
|
||||
@Override
|
||||
@DataScope(deptAlias = "d", userAlias = "u")
|
||||
public List<SysUser> selectAllocatedList(SysUser user)
|
||||
{
|
||||
return userMapper.selectAllocatedList(user);
|
||||
}
|
||||
|
||||
/**
|
||||
* 根据条件分页查询未分配用户角色列表
|
||||
*
|
||||
* @param user 用户信息
|
||||
* @return 用户信息集合信息
|
||||
*/
|
||||
@Override
|
||||
@DataScope(deptAlias = "d", userAlias = "u")
|
||||
public List<SysUser> selectUnallocatedList(SysUser user)
|
||||
{
|
||||
return userMapper.selectUnallocatedList(user);
|
||||
}
|
||||
|
||||
/**
|
||||
* 通过用户名查询用户
|
||||
*
|
||||
* @param userName 用户名
|
||||
* @return 用户对象信息
|
||||
*/
|
||||
@Override
|
||||
public SysUser selectUserByUserName(String userName)
|
||||
{
|
||||
return userMapper.selectUserByUserName(userName);
|
||||
}
|
||||
|
||||
/**
|
||||
* 通过用户ID查询用户
|
||||
*
|
||||
* @param userId 用户ID
|
||||
* @return 用户对象信息
|
||||
*/
|
||||
@Override
|
||||
public SysUser selectUserById(Long userId)
|
||||
{
|
||||
return userMapper.selectUserById(userId);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询用户所属角色组
|
||||
*
|
||||
* @param userName 用户名
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public String selectUserRoleGroup(String userName)
|
||||
{
|
||||
List<SysRole> list = roleMapper.selectRolesByUserName(userName);
|
||||
if (CollectionUtils.isEmpty(list))
|
||||
{
|
||||
return StringUtils.EMPTY;
|
||||
}
|
||||
return list.stream().map(SysRole::getRoleName).collect(Collectors.joining(","));
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询用户所属岗位组
|
||||
*
|
||||
* @param userName 用户名
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public String selectUserPostGroup(String userName)
|
||||
{
|
||||
List<SysPost> list = postMapper.selectPostsByUserName(userName);
|
||||
if (CollectionUtils.isEmpty(list))
|
||||
{
|
||||
return StringUtils.EMPTY;
|
||||
}
|
||||
return list.stream().map(SysPost::getPostName).collect(Collectors.joining(","));
|
||||
}
|
||||
|
||||
/**
|
||||
* 校验用户名称是否唯一
|
||||
*
|
||||
* @param userName 用户名称
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public String checkUserNameUnique(String userName)
|
||||
{
|
||||
int count = userMapper.checkUserNameUnique(userName);
|
||||
if (count > 0)
|
||||
{
|
||||
return UserConstants.NOT_UNIQUE;
|
||||
}
|
||||
return UserConstants.UNIQUE;
|
||||
}
|
||||
|
||||
/**
|
||||
* 校验手机号码是否唯一
|
||||
*
|
||||
* @param user 用户信息
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
public String checkPhoneUnique(SysUser user)
|
||||
{
|
||||
Long userId = StringUtils.isNull(user.getUserId()) ? -1L : user.getUserId();
|
||||
SysUser info = userMapper.checkPhoneUnique(user.getPhonenumber());
|
||||
if (StringUtils.isNotNull(info) && info.getUserId().longValue() != userId.longValue())
|
||||
{
|
||||
return UserConstants.NOT_UNIQUE;
|
||||
}
|
||||
return UserConstants.UNIQUE;
|
||||
}
|
||||
|
||||
/**
|
||||
* 校验email是否唯一
|
||||
*
|
||||
* @param user 用户信息
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
public String checkEmailUnique(SysUser user)
|
||||
{
|
||||
Long userId = StringUtils.isNull(user.getUserId()) ? -1L : user.getUserId();
|
||||
SysUser info = userMapper.checkEmailUnique(user.getEmail());
|
||||
if (StringUtils.isNotNull(info) && info.getUserId().longValue() != userId.longValue())
|
||||
{
|
||||
return UserConstants.NOT_UNIQUE;
|
||||
}
|
||||
return UserConstants.UNIQUE;
|
||||
}
|
||||
|
||||
/**
|
||||
* 校验用户是否允许操作
|
||||
*
|
||||
* @param user 用户信息
|
||||
*/
|
||||
@Override
|
||||
public void checkUserAllowed(SysUser user)
|
||||
{
|
||||
if (StringUtils.isNotNull(user.getUserId()) && user.isAdmin())
|
||||
{
|
||||
throw new ServiceException("不允许操作超级管理员用户");
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 校验用户是否有数据权限
|
||||
*
|
||||
* @param userId 用户id
|
||||
*/
|
||||
@Override
|
||||
public void checkUserDataScope(Long userId)
|
||||
{
|
||||
if (!SysUser.isAdmin(SecurityUtils.getUserId()))
|
||||
{
|
||||
SysUser user = new SysUser();
|
||||
user.setUserId(userId);
|
||||
List<SysUser> users = SpringUtils.getAopProxy(this).selectUserList(user);
|
||||
if (StringUtils.isEmpty(users))
|
||||
{
|
||||
throw new ServiceException("没有权限访问用户数据!");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增保存用户信息
|
||||
*
|
||||
* @param user 用户信息
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
@Transactional
|
||||
public int insertUser(SysUser user)
|
||||
{
|
||||
// 新增用户信息
|
||||
int rows = userMapper.insertUser(user);
|
||||
// 新增用户岗位关联
|
||||
insertUserPost(user);
|
||||
// 新增用户与角色管理
|
||||
insertUserRole(user);
|
||||
return rows;
|
||||
}
|
||||
|
||||
/**
|
||||
* 注册用户信息
|
||||
*
|
||||
* @param user 用户信息
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public boolean registerUser(SysUser user)
|
||||
{
|
||||
return userMapper.insertUser(user) > 0;
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改保存用户信息
|
||||
*
|
||||
* @param user 用户信息
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
@Transactional
|
||||
public int updateUser(SysUser user)
|
||||
{
|
||||
Long userId = user.getUserId();
|
||||
// 删除用户与角色关联
|
||||
userRoleMapper.deleteUserRoleByUserId(userId);
|
||||
// 新增用户与角色管理
|
||||
insertUserRole(user);
|
||||
// 删除用户与岗位关联
|
||||
userPostMapper.deleteUserPostByUserId(userId);
|
||||
// 新增用户与岗位管理
|
||||
insertUserPost(user);
|
||||
return userMapper.updateUser(user);
|
||||
}
|
||||
|
||||
/**
|
||||
* 用户授权角色
|
||||
*
|
||||
* @param userId 用户ID
|
||||
* @param roleIds 角色组
|
||||
*/
|
||||
@Override
|
||||
@Transactional
|
||||
public void insertUserAuth(Long userId, Long[] roleIds)
|
||||
{
|
||||
userRoleMapper.deleteUserRoleByUserId(userId);
|
||||
insertUserRole(userId, roleIds);
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改用户状态
|
||||
*
|
||||
* @param user 用户信息
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int updateUserStatus(SysUser user)
|
||||
{
|
||||
return userMapper.updateUser(user);
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改用户基本信息
|
||||
*
|
||||
* @param user 用户信息
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int updateUserProfile(SysUser user)
|
||||
{
|
||||
return userMapper.updateUser(user);
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改用户头像
|
||||
*
|
||||
* @param userName 用户名
|
||||
* @param avatar 头像地址
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public boolean updateUserAvatar(String userName, String avatar)
|
||||
{
|
||||
return userMapper.updateUserAvatar(userName, avatar) > 0;
|
||||
}
|
||||
|
||||
/**
|
||||
* 重置用户密码
|
||||
*
|
||||
* @param user 用户信息
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int resetPwd(SysUser user)
|
||||
{
|
||||
return userMapper.updateUser(user);
|
||||
}
|
||||
|
||||
/**
|
||||
* 重置用户密码
|
||||
*
|
||||
* @param userName 用户名
|
||||
* @param password 密码
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int resetUserPwd(String userName, String password)
|
||||
{
|
||||
return userMapper.resetUserPwd(userName, password);
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增用户角色信息
|
||||
*
|
||||
* @param user 用户对象
|
||||
*/
|
||||
public void insertUserRole(SysUser user)
|
||||
{
|
||||
Long[] roles = user.getRoleIds();
|
||||
if (StringUtils.isNotNull(roles))
|
||||
{
|
||||
// 新增用户与角色管理
|
||||
List<SysUserRole> list = new ArrayList<SysUserRole>();
|
||||
for (Long roleId : roles)
|
||||
{
|
||||
SysUserRole ur = new SysUserRole();
|
||||
ur.setUserId(user.getUserId());
|
||||
ur.setRoleId(roleId);
|
||||
list.add(ur);
|
||||
}
|
||||
if (list.size() > 0)
|
||||
{
|
||||
userRoleMapper.batchUserRole(list);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增用户岗位信息
|
||||
*
|
||||
* @param user 用户对象
|
||||
*/
|
||||
public void insertUserPost(SysUser user)
|
||||
{
|
||||
Long[] posts = user.getPostIds();
|
||||
if (StringUtils.isNotNull(posts))
|
||||
{
|
||||
// 新增用户与岗位管理
|
||||
List<SysUserPost> list = new ArrayList<SysUserPost>();
|
||||
for (Long postId : posts)
|
||||
{
|
||||
SysUserPost up = new SysUserPost();
|
||||
up.setUserId(user.getUserId());
|
||||
up.setPostId(postId);
|
||||
list.add(up);
|
||||
}
|
||||
if (list.size() > 0)
|
||||
{
|
||||
userPostMapper.batchUserPost(list);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增用户角色信息
|
||||
*
|
||||
* @param userId 用户ID
|
||||
* @param roleIds 角色组
|
||||
*/
|
||||
public void insertUserRole(Long userId, Long[] roleIds)
|
||||
{
|
||||
if (StringUtils.isNotNull(roleIds))
|
||||
{
|
||||
// 新增用户与角色管理
|
||||
List<SysUserRole> list = new ArrayList<SysUserRole>();
|
||||
for (Long roleId : roleIds)
|
||||
{
|
||||
SysUserRole ur = new SysUserRole();
|
||||
ur.setUserId(userId);
|
||||
ur.setRoleId(roleId);
|
||||
list.add(ur);
|
||||
}
|
||||
if (list.size() > 0)
|
||||
{
|
||||
userRoleMapper.batchUserRole(list);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 通过用户ID删除用户
|
||||
*
|
||||
* @param userId 用户ID
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
@Transactional
|
||||
public int deleteUserById(Long userId)
|
||||
{
|
||||
// 删除用户与角色关联
|
||||
userRoleMapper.deleteUserRoleByUserId(userId);
|
||||
// 删除用户与岗位表
|
||||
userPostMapper.deleteUserPostByUserId(userId);
|
||||
return userMapper.deleteUserById(userId);
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除用户信息
|
||||
*
|
||||
* @param userIds 需要删除的用户ID
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
@Transactional
|
||||
public int deleteUserByIds(Long[] userIds)
|
||||
{
|
||||
for (Long userId : userIds)
|
||||
{
|
||||
checkUserAllowed(new SysUser(userId));
|
||||
checkUserDataScope(userId);
|
||||
}
|
||||
// 删除用户与角色关联
|
||||
userRoleMapper.deleteUserRole(userIds);
|
||||
// 删除用户与岗位关联
|
||||
userPostMapper.deleteUserPost(userIds);
|
||||
return userMapper.deleteUserByIds(userIds);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导入用户数据
|
||||
*
|
||||
* @param userList 用户数据列表
|
||||
* @param isUpdateSupport 是否更新支持,如果已存在,则进行更新数据
|
||||
* @param operName 操作用户
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public String importUser(List<SysUser> userList, Boolean isUpdateSupport, String operName)
|
||||
{
|
||||
if (StringUtils.isNull(userList) || userList.size() == 0)
|
||||
{
|
||||
throw new ServiceException("导入用户数据不能为空!");
|
||||
}
|
||||
int successNum = 0;
|
||||
int failureNum = 0;
|
||||
StringBuilder successMsg = new StringBuilder();
|
||||
StringBuilder failureMsg = new StringBuilder();
|
||||
String password = configService.selectConfigByKey("sys.user.initPassword");
|
||||
for (SysUser user : userList)
|
||||
{
|
||||
try
|
||||
{
|
||||
// 验证是否存在这个用户
|
||||
SysUser u = userMapper.selectUserByUserName(user.getUserName());
|
||||
if (StringUtils.isNull(u))
|
||||
{
|
||||
BeanValidators.validateWithException(validator, user);
|
||||
user.setPassword(SecurityUtils.encryptPassword(password));
|
||||
user.setCreateBy(operName);
|
||||
this.insertUser(user);
|
||||
successNum++;
|
||||
successMsg.append("<br/>" + successNum + "、账号 " + user.getUserName() + " 导入成功");
|
||||
}
|
||||
else if (isUpdateSupport)
|
||||
{
|
||||
BeanValidators.validateWithException(validator, user);
|
||||
user.setUpdateBy(operName);
|
||||
this.updateUser(user);
|
||||
successNum++;
|
||||
successMsg.append("<br/>" + successNum + "、账号 " + user.getUserName() + " 更新成功");
|
||||
}
|
||||
else
|
||||
{
|
||||
failureNum++;
|
||||
failureMsg.append("<br/>" + failureNum + "、账号 " + user.getUserName() + " 已存在");
|
||||
}
|
||||
}
|
||||
catch (Exception e)
|
||||
{
|
||||
failureNum++;
|
||||
String msg = "<br/>" + failureNum + "、账号 " + user.getUserName() + " 导入失败:";
|
||||
failureMsg.append(msg + e.getMessage());
|
||||
log.error(msg, e);
|
||||
}
|
||||
}
|
||||
if (failureNum > 0)
|
||||
{
|
||||
failureMsg.insert(0, "很抱歉,导入失败!共 " + failureNum + " 条数据格式不正确,错误如下:");
|
||||
throw new ServiceException(failureMsg.toString());
|
||||
}
|
||||
else
|
||||
{
|
||||
successMsg.insert(0, "恭喜您,数据已全部导入成功!共 " + successNum + " 条,数据如下:");
|
||||
}
|
||||
return successMsg.toString();
|
||||
}
|
||||
}
|
@ -0,0 +1,20 @@
|
||||
package com.ruoyi.system.service_shate;
|
||||
|
||||
import com.ruoyi.system.domain_shate.AustraliaMiddleEastVO;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 澳大利亚中东部地区
|
||||
* @Author: JinSheng Song
|
||||
* @Date: 2022/5/11 11:32
|
||||
*/
|
||||
public interface IAustraliaMiddleEastService
|
||||
{
|
||||
public List<AustraliaMiddleEastVO> selectAustralia(String yearMonth,String month);
|
||||
|
||||
public Integer DelAustralia(@Param("id") String id);
|
||||
|
||||
public Integer IntoAustralia(AustraliaMiddleEastVO eastVO);
|
||||
}
|
@ -0,0 +1,73 @@
|
||||
package com.ruoyi.system.service_shate;
|
||||
|
||||
import com.ruoyi.system.domain_shate.DateUpload;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
|
||||
import java.time.LocalDate;
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
import java.util.StringTokenizer;
|
||||
|
||||
/**
|
||||
* @Author: JinSheng Song
|
||||
* @Date: 2022/7/11 15:43
|
||||
*/
|
||||
public interface IDateUploadService {
|
||||
|
||||
List<DateUpload> selectUpload( String zone,
|
||||
String type,
|
||||
String type1,
|
||||
String type2,
|
||||
String year,
|
||||
String dateWithSway,
|
||||
String name,
|
||||
String dateTime);
|
||||
|
||||
DateUpload selectShpfire(String zone,String year,String datetime,String type);
|
||||
|
||||
Integer DelUpload( Integer id);
|
||||
|
||||
Integer IntoUpload(DateUpload upload);
|
||||
|
||||
DateUpload selectShp( String zone,String type,String dateTime);
|
||||
|
||||
Integer DelShp( Integer id);
|
||||
|
||||
Integer IntoShp(DateUpload upload);
|
||||
|
||||
DateUpload selectDel(Integer id);
|
||||
|
||||
Integer altitude( String zone,
|
||||
String imageDate);
|
||||
Integer aspect( String zone,
|
||||
String imageDate);
|
||||
Integer landuse( String zone,
|
||||
String imageDate);
|
||||
Integer suitability( String zone,
|
||||
String imageDate);
|
||||
Integer road( String zone,
|
||||
String imageDate);
|
||||
Integer seedSuccess( String zone,
|
||||
String imageDate);
|
||||
Integer vegetationDistribution( String zone,
|
||||
String imageDate);
|
||||
Integer slope( String zone,
|
||||
String imageDate);
|
||||
Integer desertification( String zone,
|
||||
String imageDate);
|
||||
Integer moisture( String zone,
|
||||
String imageDate);
|
||||
Integer salinization( String zone,
|
||||
String imageDate);
|
||||
Integer healthy(String zone,
|
||||
String imageDate,
|
||||
String resolution);
|
||||
Integer water( String zone,
|
||||
String imageDate);
|
||||
Integer waterArea( String zone,
|
||||
String imageDate);
|
||||
Integer roadLength( String zone,
|
||||
String imageDate);
|
||||
Integer climateIndex( String zone,
|
||||
String imageDate);
|
||||
}
|
@ -0,0 +1,24 @@
|
||||
package com.ruoyi.system.service_shate;
|
||||
|
||||
import com.ruoyi.system.domain_shate.LandUse;
|
||||
import com.ruoyi.system.domain_shate.SeedingSuccessRate;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Set;
|
||||
|
||||
/**
|
||||
* @Author: JinSheng Song
|
||||
* @Date: 2022/7/8 11:20
|
||||
*/
|
||||
public interface ILandUseServices
|
||||
{
|
||||
List<LandUse> sqlSeeding(String zone, String[] landUses,String year);
|
||||
|
||||
List<LandUse> sqlSeeding1( String zone,String year);
|
||||
|
||||
Integer insertSeeding(LandUse use);
|
||||
|
||||
List<LandUse> sqlYear();
|
||||
|
||||
}
|
@ -0,0 +1,19 @@
|
||||
package com.ruoyi.system.service_shate;
|
||||
|
||||
import com.ruoyi.system.domain_shate.PlantingSuitability;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @Author: JinSheng Song
|
||||
* @Date: 2022/7/8 11:27
|
||||
*/
|
||||
public interface IPlantingSuitabilityService
|
||||
{
|
||||
List<PlantingSuitability> sqlSeeding(String zone);
|
||||
|
||||
Integer InsertSeeding(PlantingSuitability suitability);
|
||||
|
||||
List<PlantingSuitability> sqlYear();
|
||||
}
|
@ -0,0 +1,38 @@
|
||||
package com.ruoyi.system.service_shate;
|
||||
|
||||
import com.ruoyi.system.domain_shate.Climate;
|
||||
import com.ruoyi.system.domain_shate.RegionIndex;
|
||||
import com.ruoyi.system.domain_shate.RoadFactor;
|
||||
import com.ruoyi.system.domain_shate.WaterFactor;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @Author: JinSheng Song
|
||||
* @Date: 2022/7/8 11:23
|
||||
*/
|
||||
public interface IRegionalFactorService
|
||||
{
|
||||
List<WaterFactor> sqlYear();
|
||||
|
||||
List<RegionIndex> sqlYear1();
|
||||
|
||||
List<RoadFactor> sqlYear2();
|
||||
|
||||
List<WaterFactor> sqlWater(String zone,String year);
|
||||
|
||||
List<RegionIndex> sqlRegion(String zone,String year);
|
||||
|
||||
List<RoadFactor> sqlRoad(String zone,String year);
|
||||
|
||||
Integer InsertWater(WaterFactor factor);
|
||||
|
||||
Integer InsertWaterArea(RegionIndex index);
|
||||
|
||||
Integer InsertRoadLength(RegionIndex index);
|
||||
|
||||
Integer InsertRoad(RoadFactor factor);
|
||||
|
||||
List<Climate> sqlClimate(String zone);
|
||||
}
|
@ -0,0 +1,23 @@
|
||||
package com.ruoyi.system.service_shate;
|
||||
|
||||
import com.ruoyi.system.domain_shate.SeedingSuccessRate;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @Author: JinSheng Song
|
||||
* @Date: 2022/7/8 9:41
|
||||
*/
|
||||
public interface ISeedingSuccessService {
|
||||
|
||||
List<SeedingSuccessRate> sqlSeeding(String zone,String year);
|
||||
|
||||
List<SeedingSuccessRate> sqlYear();
|
||||
|
||||
Integer InsertSeeding1(SeedingSuccessRate eastVO);
|
||||
|
||||
Integer InsertSeeding2(SeedingSuccessRate eastVO);
|
||||
|
||||
Integer Delete(String zone,String imageDate,String name);
|
||||
}
|
@ -0,0 +1,33 @@
|
||||
package com.ruoyi.system.service_shate;
|
||||
|
||||
import com.ruoyi.system.domain_shate.SoilDesertification;
|
||||
import com.ruoyi.system.domain_shate.SoilMoisture;
|
||||
import com.ruoyi.system.domain_shate.SoilSalinization;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @Author: JinSheng Song
|
||||
* @Date: 2022/7/8 11:25
|
||||
*/
|
||||
public interface ISoilFactorService {
|
||||
|
||||
List<SoilDesertification> sqlYear();
|
||||
|
||||
List<SoilMoisture> sqlYear1();
|
||||
|
||||
List<SoilSalinization> sqlYear2();
|
||||
|
||||
List<SoilDesertification> sqlDesert(String zone, String year);
|
||||
|
||||
List<SoilMoisture> sqlMoisture(String zone, String year);
|
||||
|
||||
List<SoilSalinization> sqlSalin(String zone, String year);
|
||||
|
||||
Integer InsertSalin(SoilSalinization soil);
|
||||
|
||||
Integer InsertDesert(SoilDesertification desertification);
|
||||
|
||||
Integer InsertMoisture(SoilMoisture moisture);
|
||||
}
|
@ -0,0 +1,34 @@
|
||||
package com.ruoyi.system.service_shate;
|
||||
|
||||
import com.ruoyi.system.domain_shate.Altitude;
|
||||
import com.ruoyi.system.domain_shate.Aspect;
|
||||
import com.ruoyi.system.domain_shate.Slope;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @Author: JinSheng Song
|
||||
* @Date: 2022/7/8 11:30
|
||||
*/
|
||||
public interface ITopographicFactorService
|
||||
{
|
||||
|
||||
List<Altitude> sqlYear();
|
||||
|
||||
List<Slope> sqlYear1();
|
||||
|
||||
List<Aspect> sqlYear2();
|
||||
|
||||
List<Altitude> sqlAltitude(String zone,String year);
|
||||
|
||||
List<Slope> sqlSlope(String zone,String year);
|
||||
|
||||
List<Aspect> sqlAspect(String zone,String year);
|
||||
|
||||
Integer InsertSlope(Slope slope);
|
||||
|
||||
Integer InsertAltitude(Altitude altitude);
|
||||
|
||||
Integer InsertAspect(Aspect aspect);
|
||||
}
|
@ -0,0 +1,20 @@
|
||||
package com.ruoyi.system.service_shate;
|
||||
|
||||
import com.ruoyi.system.domain_shate.SeedingSuccessRate;
|
||||
import com.ruoyi.system.domain_shate.VegetationHealth;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @Author: JinSheng Song
|
||||
* @Date: 2022/7/8 10:47
|
||||
*/
|
||||
public interface IVegetationHealthServices {
|
||||
|
||||
List<VegetationHealth> sqlSeeding(String zone,String name,String year);
|
||||
|
||||
List<VegetationHealth> sqlYear();
|
||||
|
||||
Integer insertSeeding(VegetationHealth health);
|
||||
}
|
@ -0,0 +1,38 @@
|
||||
package com.ruoyi.system.service_shate.impl;
|
||||
|
||||
import com.ruoyi.system.mapper_shate.AustraliaMiddleEastMapper;
|
||||
import com.ruoyi.system.service_shate.IAustraliaMiddleEastService;
|
||||
import com.ruoyi.system.domain_shate.AustraliaMiddleEastVO;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 亚大综合监测
|
||||
* @Author: JinSheng Song
|
||||
* @Date: 2022/5/11 11:43
|
||||
*/
|
||||
@Service
|
||||
public class AustraliaMiddleEastServiceimpl implements IAustraliaMiddleEastService
|
||||
{
|
||||
@Resource
|
||||
private AustraliaMiddleEastMapper australiaMiddleEastMapper;
|
||||
|
||||
@Override
|
||||
public List<AustraliaMiddleEastVO> selectAustralia(String yearMonth,String month)
|
||||
{
|
||||
return australiaMiddleEastMapper.selectAustralia(yearMonth,month);
|
||||
}
|
||||
|
||||
@Override
|
||||
public Integer DelAustralia(String id) {
|
||||
return australiaMiddleEastMapper.DelAustralia(id);
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
public Integer IntoAustralia(AustraliaMiddleEastVO eastVO) {
|
||||
return australiaMiddleEastMapper.IntoAustralia(eastVO);
|
||||
}
|
||||
}
|
@ -0,0 +1,143 @@
|
||||
package com.ruoyi.system.service_shate.impl;
|
||||
|
||||
import com.ruoyi.system.domain_shate.DateUpload;
|
||||
import com.ruoyi.system.mapper_shate.DateUploadMapper;
|
||||
import com.ruoyi.system.service_shate.IDateUploadService;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
import java.time.LocalDate;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @Author: JinSheng Song
|
||||
* @Date: 2022/7/11 15:44
|
||||
*/
|
||||
@Service
|
||||
public class DateUploadServiceImpl implements IDateUploadService {
|
||||
|
||||
@Resource
|
||||
private DateUploadMapper mapper;
|
||||
|
||||
@Override
|
||||
public List<DateUpload> selectUpload(String zone,String type,String type1,String type2,String year, String dateWithSway,String name,String dateTime) {
|
||||
return mapper.selectUpload(zone,type,type1,type2,year,dateWithSway,name,dateTime);
|
||||
}
|
||||
|
||||
@Override
|
||||
public DateUpload selectShpfire(String zone, String year, String datetime,String type) {
|
||||
return mapper.selectShpfile(zone,type,datetime,year);
|
||||
}
|
||||
|
||||
@Override
|
||||
public Integer DelUpload(Integer id) {
|
||||
return mapper.DelUpload(id);
|
||||
}
|
||||
|
||||
@Override
|
||||
public Integer IntoUpload(DateUpload upload) {
|
||||
return mapper.IntoUpload(upload);
|
||||
}
|
||||
|
||||
@Override
|
||||
public DateUpload selectShp(String zone, String type, String dateTime) {
|
||||
return mapper.selectShp(zone,type,dateTime);
|
||||
}
|
||||
|
||||
@Override
|
||||
public Integer DelShp(Integer id) {
|
||||
return mapper.DelShp(id);
|
||||
}
|
||||
|
||||
@Override
|
||||
public Integer IntoShp(DateUpload upload) {
|
||||
return mapper.IntoShp(upload);
|
||||
}
|
||||
|
||||
@Override
|
||||
public DateUpload selectDel(Integer id) {
|
||||
return mapper.selectDel(id);
|
||||
}
|
||||
|
||||
@Override
|
||||
public Integer altitude(String zone, String imageDate) {
|
||||
return mapper.altitude(zone,imageDate);
|
||||
}
|
||||
|
||||
@Override
|
||||
public Integer aspect(String zone, String imageDate) {
|
||||
return mapper.aspect(zone,imageDate);
|
||||
}
|
||||
|
||||
@Override
|
||||
public Integer landuse(String zone, String imageDate) {
|
||||
return mapper.landuse(zone,imageDate);
|
||||
}
|
||||
|
||||
@Override
|
||||
public Integer suitability(String zone, String imageDate) {
|
||||
return mapper.suitability(zone,imageDate);
|
||||
}
|
||||
|
||||
@Override
|
||||
public Integer road(String zone, String imageDate) {
|
||||
return mapper.road(zone,imageDate);
|
||||
}
|
||||
|
||||
@Override
|
||||
public Integer seedSuccess(String zone, String imageDate) {
|
||||
return mapper.seedSuccess(zone,imageDate);
|
||||
}
|
||||
|
||||
@Override
|
||||
public Integer vegetationDistribution(String zone, String imageDate) {
|
||||
return mapper.vegetationDistribution(zone,imageDate);
|
||||
}
|
||||
|
||||
@Override
|
||||
public Integer slope(String zone, String imageDate) {
|
||||
return mapper.slope(zone,imageDate);
|
||||
}
|
||||
|
||||
@Override
|
||||
public Integer desertification(String zone, String imageDate) {
|
||||
return mapper.desertification(zone,imageDate);
|
||||
}
|
||||
|
||||
@Override
|
||||
public Integer moisture(String zone, String imageDate) {
|
||||
return mapper.moisture(zone,imageDate);
|
||||
}
|
||||
|
||||
@Override
|
||||
public Integer salinization(String zone, String imageDate) {
|
||||
return mapper.salinization(zone,imageDate);
|
||||
}
|
||||
|
||||
@Override
|
||||
public Integer healthy(String zone, String imageDate,String resolution) {
|
||||
return mapper.healthy(zone,imageDate,resolution);
|
||||
}
|
||||
|
||||
@Override
|
||||
public Integer water(String zone, String imageDate) {
|
||||
return mapper.water(zone,imageDate);
|
||||
}
|
||||
|
||||
@Override
|
||||
public Integer waterArea(String zone, String imageDate) {
|
||||
return mapper.waterArea(zone,imageDate);
|
||||
}
|
||||
|
||||
@Override
|
||||
public Integer roadLength(String zone, String imageDate) {
|
||||
return mapper.roadLength(zone,imageDate);
|
||||
}
|
||||
|
||||
@Override
|
||||
public Integer climateIndex(String zone, String imageDate) {
|
||||
return mapper.climateIndex(zone,imageDate);
|
||||
}
|
||||
|
||||
|
||||
}
|
@ -0,0 +1,45 @@
|
||||
package com.ruoyi.system.service_shate.impl;
|
||||
|
||||
import com.ruoyi.system.domain_shate.LandUse;
|
||||
import com.ruoyi.system.domain_shate.SeedingSuccessRate;
|
||||
import com.ruoyi.system.mapper_shate.LandUseMapper;
|
||||
import com.ruoyi.system.service_shate.ILandUseServices;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
import java.time.Year;
|
||||
import java.util.List;
|
||||
import java.util.Set;
|
||||
|
||||
/**
|
||||
* @Author: JinSheng Song
|
||||
* @Date: 2022/7/8 11:20
|
||||
*/
|
||||
@Service
|
||||
public class LandUseServiceipml implements ILandUseServices
|
||||
{
|
||||
@Resource
|
||||
private LandUseMapper mapper;
|
||||
|
||||
@Override
|
||||
public List<LandUse> sqlSeeding(String zone, String[] landUses,String year) {
|
||||
List<LandUse> value=mapper.sqlSeeding(zone, landUses,year);
|
||||
return value;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<LandUse> sqlSeeding1(String zone, String year) {
|
||||
List<LandUse> value=mapper.sqlSeeding1(zone,year);
|
||||
return value;
|
||||
}
|
||||
|
||||
@Override
|
||||
public Integer insertSeeding(LandUse use) {
|
||||
return mapper.insertSeeding(use);
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<LandUse> sqlYear() {
|
||||
return mapper.sqlYear();
|
||||
}
|
||||
}
|
@ -0,0 +1,34 @@
|
||||
package com.ruoyi.system.service_shate.impl;
|
||||
|
||||
import com.ruoyi.system.domain_shate.PlantingSuitability;
|
||||
import com.ruoyi.system.mapper_shate.PlantingSuitabilityMapper;
|
||||
import com.ruoyi.system.service_shate.IPlantingSuitabilityService;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @Author: JinSheng Song
|
||||
* @Date: 2022/7/8 11:28
|
||||
*/
|
||||
@Service
|
||||
public class PlantingSuitabilityServiceIpml implements IPlantingSuitabilityService {
|
||||
@Resource
|
||||
private PlantingSuitabilityMapper mapper;
|
||||
@Override
|
||||
public List<PlantingSuitability> sqlSeeding(String zone) {
|
||||
List<PlantingSuitability> value=mapper.sqlSeeding(zone);
|
||||
return value;
|
||||
}
|
||||
|
||||
@Override
|
||||
public Integer InsertSeeding(PlantingSuitability suitability) {
|
||||
return mapper.InsertSeeding(suitability);
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<PlantingSuitability> sqlYear() {
|
||||
return mapper.sqlYear();
|
||||
}
|
||||
}
|
@ -0,0 +1,81 @@
|
||||
package com.ruoyi.system.service_shate.impl;
|
||||
|
||||
import com.ruoyi.system.domain_shate.Climate;
|
||||
import com.ruoyi.system.domain_shate.RegionIndex;
|
||||
import com.ruoyi.system.domain_shate.RoadFactor;
|
||||
import com.ruoyi.system.domain_shate.WaterFactor;
|
||||
import com.ruoyi.system.mapper_shate.RegionalFactorMapper;
|
||||
import com.ruoyi.system.service_shate.IRegionalFactorService;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.yaml.snakeyaml.events.Event;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @Author: JinSheng Song
|
||||
* @Date: 2022/7/8 11:23
|
||||
*/
|
||||
@Service
|
||||
public class RegionalFactorServiceIpml implements IRegionalFactorService {
|
||||
|
||||
@Resource
|
||||
private RegionalFactorMapper mapper;
|
||||
|
||||
@Override
|
||||
public List<WaterFactor> sqlYear() {
|
||||
return mapper.sqlYear();
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<RegionIndex> sqlYear1() {
|
||||
return mapper.sqlYear1();
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<RoadFactor> sqlYear2() {
|
||||
return mapper.sqlYear2();
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<WaterFactor> sqlWater(String zone, String year) {
|
||||
return mapper.sqlWater(zone,year);
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<RegionIndex> sqlRegion(String zone,String year) {
|
||||
return mapper.sqlRegion(zone,year);
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<RoadFactor> sqlRoad(String zone,String year) {
|
||||
return mapper.sqlRoad(zone,year);
|
||||
}
|
||||
|
||||
@Override
|
||||
public Integer InsertWater(WaterFactor factor) {
|
||||
return mapper.InsertWater(factor);
|
||||
}
|
||||
|
||||
@Override
|
||||
public Integer InsertWaterArea(RegionIndex index) {
|
||||
return mapper.InsertWaterArea(index);
|
||||
}
|
||||
|
||||
@Override
|
||||
public Integer InsertRoadLength(RegionIndex index) {
|
||||
return mapper.InsertRoadLength(index);
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
public Integer InsertRoad(RoadFactor factor) {
|
||||
return mapper.InsertRoad(factor);
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<Climate> sqlClimate(String zone) {
|
||||
return mapper.sqlClimate(zone);
|
||||
}
|
||||
}
|
@ -0,0 +1,47 @@
|
||||
package com.ruoyi.system.service_shate.impl;
|
||||
|
||||
import com.ruoyi.system.domain_shate.SeedingSuccessRate;
|
||||
import com.ruoyi.system.mapper_shate.SeedingSuccessMapper;
|
||||
import com.ruoyi.system.service_shate.ISeedingSuccessService;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @Author: JinSheng Song
|
||||
* @Date: 2022/7/8 9:42
|
||||
*/
|
||||
@Service
|
||||
public class SeedingSuccessServiceimpl implements ISeedingSuccessService
|
||||
{
|
||||
@Resource
|
||||
private SeedingSuccessMapper mapper;
|
||||
@Override
|
||||
public List<SeedingSuccessRate> sqlSeeding(String zone, String year)
|
||||
{
|
||||
List<SeedingSuccessRate> vaue =mapper.sqlSeeding(zone,year);
|
||||
return vaue;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<SeedingSuccessRate> sqlYear() {
|
||||
return mapper.sqlYear();
|
||||
}
|
||||
|
||||
@Override
|
||||
public Integer InsertSeeding1(SeedingSuccessRate eastVO) {
|
||||
return mapper.InsertSeeding1(eastVO);
|
||||
}
|
||||
|
||||
@Override
|
||||
public Integer InsertSeeding2(SeedingSuccessRate eastVO) {
|
||||
return mapper.InsertSeeding2(eastVO);
|
||||
}
|
||||
|
||||
@Override
|
||||
public Integer Delete(String zone, String imageDate,String name) {
|
||||
return mapper.Delete(name,zone,imageDate);
|
||||
}
|
||||
}
|
@ -0,0 +1,67 @@
|
||||
package com.ruoyi.system.service_shate.impl;
|
||||
|
||||
import com.ruoyi.system.domain_shate.SoilDesertification;
|
||||
import com.ruoyi.system.domain_shate.SoilMoisture;
|
||||
import com.ruoyi.system.domain_shate.SoilSalinization;
|
||||
import com.ruoyi.system.mapper_shate.SoilFactorMapper;
|
||||
import com.ruoyi.system.service_shate.ISoilFactorService;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @Author: JinSheng Song
|
||||
* @Date: 2022/7/8 11:25
|
||||
*/
|
||||
@Service
|
||||
public class SoilFactorServiceIpml implements ISoilFactorService {
|
||||
@Resource
|
||||
private SoilFactorMapper mapper;
|
||||
|
||||
@Override
|
||||
public List<SoilDesertification> sqlYear() {
|
||||
return mapper.sqlYear();
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<SoilMoisture> sqlYear1() {
|
||||
return mapper.sqlYear1();
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<SoilSalinization> sqlYear2() {
|
||||
return mapper.sqlYear2();
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<SoilDesertification> sqlDesert(String zone, String year) {
|
||||
return mapper.sqlDesert(zone,year);
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<SoilMoisture> sqlMoisture(String zone, String year) {
|
||||
return mapper.sqlMoisture(zone,year);
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<SoilSalinization> sqlSalin(String zone, String year) {
|
||||
return mapper.sqlSalin(zone,year);
|
||||
}
|
||||
|
||||
@Override
|
||||
public Integer InsertSalin(SoilSalinization soil) {
|
||||
return mapper.InsertSalin(soil);
|
||||
}
|
||||
|
||||
@Override
|
||||
public Integer InsertDesert(SoilDesertification desertification) {
|
||||
return mapper.InsertDesert(desertification);
|
||||
}
|
||||
|
||||
@Override
|
||||
public Integer InsertMoisture(SoilMoisture moisture) {
|
||||
return mapper.InsertMoisture(moisture);
|
||||
}
|
||||
}
|
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user