Compare commits
2 Commits
5041f3f92f
...
master
Author | SHA1 | Date | |
---|---|---|---|
4af1c07029 | |||
8918116dbd |
8
pom.xml
8
pom.xml
@ -18,13 +18,13 @@
|
|||||||
<project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
|
<project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
|
||||||
<java.version>11</java.version>
|
<java.version>11</java.version>
|
||||||
<maven-jar-plugin.version>3.1.1</maven-jar-plugin.version>
|
<maven-jar-plugin.version>3.1.1</maven-jar-plugin.version>
|
||||||
<druid.version>1.2.8</druid.version>
|
<druid.version>1.2.11</druid.version>
|
||||||
<bitwalker.version>1.21</bitwalker.version>
|
<bitwalker.version>1.21</bitwalker.version>
|
||||||
<swagger.version>3.0.0</swagger.version>
|
<swagger.version>3.0.0</swagger.version>
|
||||||
<kaptcha.version>2.3.2</kaptcha.version>
|
<kaptcha.version>2.3.2</kaptcha.version>
|
||||||
<mybatis-spring-boot.version>2.2.2</mybatis-spring-boot.version>
|
<mybatis-spring-boot.version>2.2.2</mybatis-spring-boot.version>
|
||||||
<pagehelper.boot.version>1.4.1</pagehelper.boot.version>
|
<pagehelper.boot.version>1.4.2</pagehelper.boot.version>
|
||||||
<fastjson.version>1.2.80</fastjson.version>
|
<fastjson.version>1.2.83</fastjson.version>
|
||||||
<oshi.version>6.1.6</oshi.version>
|
<oshi.version>6.1.6</oshi.version>
|
||||||
<commons.io.version>2.11.0</commons.io.version>
|
<commons.io.version>2.11.0</commons.io.version>
|
||||||
<commons.fileupload.version>1.4</commons.fileupload.version>
|
<commons.fileupload.version>1.4</commons.fileupload.version>
|
||||||
@ -42,7 +42,7 @@
|
|||||||
<dependency>
|
<dependency>
|
||||||
<groupId>org.springframework.boot</groupId>
|
<groupId>org.springframework.boot</groupId>
|
||||||
<artifactId>spring-boot-dependencies</artifactId>
|
<artifactId>spring-boot-dependencies</artifactId>
|
||||||
<version>2.5.13</version>
|
<version>2.5.14</version>
|
||||||
<type>pom</type>
|
<type>pom</type>
|
||||||
<scope>import</scope>
|
<scope>import</scope>
|
||||||
</dependency>
|
</dependency>
|
||||||
|
@ -17,7 +17,27 @@
|
|||||||
|
|
||||||
<dependencies>
|
<dependencies>
|
||||||
|
|
||||||
<!-- spring-boot-devtools -->
|
<dependency>
|
||||||
|
|
||||||
|
<groupId>org.apache.poi</groupId>
|
||||||
|
|
||||||
|
<artifactId>poi</artifactId>
|
||||||
|
|
||||||
|
<version>4.0.1</version>
|
||||||
|
|
||||||
|
</dependency>
|
||||||
|
|
||||||
|
<dependency>
|
||||||
|
|
||||||
|
<groupId>org.apache.poi</groupId>
|
||||||
|
|
||||||
|
<artifactId>poi-ooxml</artifactId>
|
||||||
|
|
||||||
|
<version>4.0.1</version>
|
||||||
|
|
||||||
|
</dependency>
|
||||||
|
|
||||||
|
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>org.springframework.boot</groupId>
|
<groupId>org.springframework.boot</groupId>
|
||||||
<artifactId>spring-boot-devtools</artifactId>
|
<artifactId>spring-boot-devtools</artifactId>
|
||||||
@ -34,7 +54,19 @@
|
|||||||
<dependency>
|
<dependency>
|
||||||
<groupId>io.swagger</groupId>
|
<groupId>io.swagger</groupId>
|
||||||
<artifactId>swagger-models</artifactId>
|
<artifactId>swagger-models</artifactId>
|
||||||
<version>1.6.2</version>
|
<version>1.6.6</version>
|
||||||
|
</dependency>
|
||||||
|
<!-- knife4j -->
|
||||||
|
<dependency>
|
||||||
|
<groupId>com.github.xiaoymin</groupId>
|
||||||
|
<artifactId>knife4j-spring-boot-starter</artifactId>
|
||||||
|
<version>3.0.3</version>
|
||||||
|
</dependency>
|
||||||
|
<!-- postgresql驱动包-->
|
||||||
|
<dependency>
|
||||||
|
<groupId>org.postgresql</groupId>
|
||||||
|
<artifactId>postgresql</artifactId>
|
||||||
|
<version>42.2.20</version>
|
||||||
</dependency>
|
</dependency>
|
||||||
|
|
||||||
<!-- Mysql驱动包 -->
|
<!-- Mysql驱动包 -->
|
||||||
|
@ -18,15 +18,18 @@ public class RuoYiApplication
|
|||||||
{
|
{
|
||||||
// System.setProperty("spring.devtools.restart.enabled", "false");
|
// System.setProperty("spring.devtools.restart.enabled", "false");
|
||||||
SpringApplication.run(RuoYiApplication.class, args);
|
SpringApplication.run(RuoYiApplication.class, args);
|
||||||
System.out.println("(♥◠‿◠)ノ゙ 我们一起学喵叫 ლ(´ڡ`ლ)゙ \n" +
|
System.out.println();
|
||||||
" .-------. ____ __ \n" +
|
System.out.println(" --->>>启动成功!<<<---");
|
||||||
" | _ _ \\ 喵 \\ \\ / / \n" +
|
// System.out.println("(♥◠‿◠)ノ゙ ლ(´ڡ`ლ)゙ \n" +
|
||||||
" | ( ' ) | 喵 \\ _. / ' \n" +
|
// " .-------. ____ __ \n" +
|
||||||
" |(_ o _) / 喵 _( )_ .' \n" +
|
// " | _ _ \\ \\ \\ / / \n" +
|
||||||
" | (_,_).' __ ___(_ o _)' \n" +
|
// " | ( ' ) | \\ _. / ' \n" +
|
||||||
" | |\\ \\ | || |(_,_)' \n" +
|
// " |(_ o _) / _( )_ .' \n" +
|
||||||
" | | \\ `' /| `-' / \n" +
|
// " | (_,_).' __ ___(_ o _)' \n" +
|
||||||
" | | \\ / \\ / \n" +
|
// " | |\\ \\ | || |(_,_)' \n" +
|
||||||
" ''-' `'-' `-..-' ");
|
// " | | \\ `' /| `-' / \n" +
|
||||||
|
// " | | \\ / \\ / \n" +
|
||||||
|
// " ''-' `'-' `-..-' ");
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -1,96 +0,0 @@
|
|||||||
package com.ruoyi.web.controller.common;
|
|
||||||
|
|
||||||
import java.awt.image.BufferedImage;
|
|
||||||
import java.io.IOException;
|
|
||||||
import java.util.concurrent.TimeUnit;
|
|
||||||
import javax.annotation.Resource;
|
|
||||||
import javax.imageio.ImageIO;
|
|
||||||
import javax.servlet.http.HttpServletResponse;
|
|
||||||
import com.ruoyi.common.config.RuoYiConfig;
|
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
|
||||||
import org.springframework.stereotype.Component;
|
|
||||||
import org.springframework.stereotype.Service;
|
|
||||||
import org.springframework.util.FastByteArrayOutputStream;
|
|
||||||
import org.springframework.web.bind.annotation.GetMapping;
|
|
||||||
import org.springframework.web.bind.annotation.RequestMapping;
|
|
||||||
import org.springframework.web.bind.annotation.RestController;
|
|
||||||
import com.google.code.kaptcha.Producer;
|
|
||||||
import com.ruoyi.common.constant.Constants;
|
|
||||||
import com.ruoyi.common.core.domain.AjaxResult;
|
|
||||||
import com.ruoyi.common.core.redis.RedisCache;
|
|
||||||
import com.ruoyi.common.utils.sign.Base64;
|
|
||||||
import com.ruoyi.common.utils.uuid.IdUtils;
|
|
||||||
import com.ruoyi.system.service.ISysConfigService;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 验证码操作处理
|
|
||||||
*
|
|
||||||
* @author ruoyi
|
|
||||||
*/
|
|
||||||
@RestController
|
|
||||||
public class CaptchaController
|
|
||||||
{
|
|
||||||
@Resource(name = "captchaProducer")
|
|
||||||
private Producer captchaProducer;
|
|
||||||
|
|
||||||
@Resource(name = "captchaProducerMath")
|
|
||||||
private Producer captchaProducerMath;
|
|
||||||
|
|
||||||
@Resource
|
|
||||||
private RedisCache redisCache;
|
|
||||||
|
|
||||||
@Resource
|
|
||||||
private ISysConfigService configService;
|
|
||||||
/**
|
|
||||||
* 生成验证码
|
|
||||||
*/
|
|
||||||
@GetMapping("/captchaImage")
|
|
||||||
public AjaxResult getCode(HttpServletResponse response) throws IOException
|
|
||||||
{
|
|
||||||
AjaxResult ajax = AjaxResult.success();
|
|
||||||
boolean captchaOnOff = configService.selectCaptchaOnOff();
|
|
||||||
ajax.put("captchaOnOff", captchaOnOff);
|
|
||||||
if (!captchaOnOff)
|
|
||||||
{
|
|
||||||
return ajax;
|
|
||||||
}
|
|
||||||
|
|
||||||
// 保存验证码信息
|
|
||||||
String uuid = IdUtils.simpleUUID();
|
|
||||||
String verifyKey = Constants.CAPTCHA_CODE_KEY + uuid;
|
|
||||||
|
|
||||||
String capStr = null, code = null;
|
|
||||||
BufferedImage image = null;
|
|
||||||
|
|
||||||
// 生成验证码
|
|
||||||
String captchaType = RuoYiConfig.getCaptchaType();
|
|
||||||
if ("math".equals(captchaType))
|
|
||||||
{
|
|
||||||
String capText = captchaProducerMath.createText();
|
|
||||||
capStr = capText.substring(0, capText.lastIndexOf("@"));
|
|
||||||
code = capText.substring(capText.lastIndexOf("@") + 1);
|
|
||||||
image = captchaProducerMath.createImage(capStr);
|
|
||||||
}
|
|
||||||
else if ("char".equals(captchaType))
|
|
||||||
{
|
|
||||||
capStr = code = captchaProducer.createText();
|
|
||||||
image = captchaProducer.createImage(capStr);
|
|
||||||
}
|
|
||||||
|
|
||||||
redisCache.setCacheObject(verifyKey, code, Constants.CAPTCHA_EXPIRATION, TimeUnit.MINUTES);
|
|
||||||
// 转换流信息写出
|
|
||||||
FastByteArrayOutputStream os = new FastByteArrayOutputStream();
|
|
||||||
try
|
|
||||||
{
|
|
||||||
ImageIO.write(image, "jpg", os);
|
|
||||||
}
|
|
||||||
catch (IOException e)
|
|
||||||
{
|
|
||||||
return AjaxResult.error(e.getMessage());
|
|
||||||
}
|
|
||||||
|
|
||||||
ajax.put("uuid", uuid);
|
|
||||||
ajax.put("img", Base64.encode(os.toByteArray()));
|
|
||||||
return ajax;
|
|
||||||
}
|
|
||||||
}
|
|
@ -12,9 +12,11 @@ import com.ruoyi.common.core.domain.AjaxResult;
|
|||||||
import com.ruoyi.common.core.domain.entity.SysMenu;
|
import com.ruoyi.common.core.domain.entity.SysMenu;
|
||||||
import com.ruoyi.common.core.domain.entity.SysUser;
|
import com.ruoyi.common.core.domain.entity.SysUser;
|
||||||
import com.ruoyi.common.core.domain.model.LoginBody;
|
import com.ruoyi.common.core.domain.model.LoginBody;
|
||||||
import com.ruoyi.common.utils.SecurityUtils;
|
import com.ruoyi.common.core.domain.model.LoginUser;
|
||||||
|
import com.ruoyi.common.utils.ServletUtils;
|
||||||
import com.ruoyi.framework.web.service.SysLoginService;
|
import com.ruoyi.framework.web.service.SysLoginService;
|
||||||
import com.ruoyi.framework.web.service.SysPermissionService;
|
import com.ruoyi.framework.web.service.SysPermissionService;
|
||||||
|
import com.ruoyi.framework.web.service.TokenService;
|
||||||
import com.ruoyi.system.service.ISysMenuService;
|
import com.ruoyi.system.service.ISysMenuService;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -34,6 +36,9 @@ public class SysLoginController
|
|||||||
@Autowired
|
@Autowired
|
||||||
private SysPermissionService permissionService;
|
private SysPermissionService permissionService;
|
||||||
|
|
||||||
|
@Autowired
|
||||||
|
private TokenService tokenService;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 登录方法
|
* 登录方法
|
||||||
*
|
*
|
||||||
@ -45,8 +50,7 @@ public class SysLoginController
|
|||||||
{
|
{
|
||||||
AjaxResult ajax = AjaxResult.success();
|
AjaxResult ajax = AjaxResult.success();
|
||||||
// 生成令牌
|
// 生成令牌
|
||||||
String token = loginService.login(loginBody.getUsername(), loginBody.getPassword(), loginBody.getCode(),
|
String token = loginService.login(loginBody.getUsername(), loginBody.getPassword(), loginBody.getCode());
|
||||||
loginBody.getUuid());
|
|
||||||
ajax.put(Constants.TOKEN, token);
|
ajax.put(Constants.TOKEN, token);
|
||||||
return ajax;
|
return ajax;
|
||||||
}
|
}
|
||||||
@ -59,7 +63,8 @@ public class SysLoginController
|
|||||||
@GetMapping("getInfo")
|
@GetMapping("getInfo")
|
||||||
public AjaxResult getInfo()
|
public AjaxResult getInfo()
|
||||||
{
|
{
|
||||||
SysUser user = SecurityUtils.getLoginUser().getUser();
|
LoginUser loginUser = tokenService.getLoginUser(ServletUtils.getRequest());
|
||||||
|
SysUser user = loginUser.getUser();
|
||||||
// 角色集合
|
// 角色集合
|
||||||
Set<String> roles = permissionService.getRolePermission(user);
|
Set<String> roles = permissionService.getRolePermission(user);
|
||||||
// 权限集合
|
// 权限集合
|
||||||
@ -79,8 +84,10 @@ public class SysLoginController
|
|||||||
@GetMapping("getRouters")
|
@GetMapping("getRouters")
|
||||||
public AjaxResult getRouters()
|
public AjaxResult getRouters()
|
||||||
{
|
{
|
||||||
Long userId = SecurityUtils.getUserId();
|
LoginUser loginUser = tokenService.getLoginUser(ServletUtils.getRequest());
|
||||||
List<SysMenu> menus = menuService.selectMenuTreeByUserId(userId);
|
// 用户信息
|
||||||
|
SysUser user = loginUser.getUser();
|
||||||
|
List<SysMenu> menus = menuService.selectMenuTreeByUserId(user.getUserId());
|
||||||
return AjaxResult.success(menuService.buildMenus(menus));
|
return AjaxResult.success(menuService.buildMenus(menus));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -28,10 +28,10 @@ public class SysRegisterController extends BaseController
|
|||||||
@PostMapping("/register")
|
@PostMapping("/register")
|
||||||
public AjaxResult register(@RequestBody RegisterBody user)
|
public AjaxResult register(@RequestBody RegisterBody user)
|
||||||
{
|
{
|
||||||
if (!("true".equals(configService.selectConfigByKey("sys.account.registerUser"))))
|
// if (!("true".equals(configService.selectConfigByKey("sys.account.registerUser"))))
|
||||||
{
|
// {
|
||||||
return error("当前系统没有开启注册功能!");
|
// return error("当前系统没有开启注册功能!");
|
||||||
}
|
// }
|
||||||
String msg = registerService.register(user);
|
String msg = registerService.register(user);
|
||||||
return StringUtils.isEmpty(msg) ? success() : error(msg);
|
return StringUtils.isEmpty(msg) ? success() : error(msg);
|
||||||
}
|
}
|
||||||
|
@ -1,40 +1,53 @@
|
|||||||
package com.ruoyi.web.controller.yada;
|
package com.ruoyi.web.controller.yada;
|
||||||
|
|
||||||
|
import com.ruoyi.common.config.RuoYiConfig;
|
||||||
import com.ruoyi.common.core.domain.AjaxResult;
|
import com.ruoyi.common.core.domain.AjaxResult;
|
||||||
import com.ruoyi.system.domain_yada.AorestCoverageVO;
|
import com.ruoyi.common.utils.file.FileUploadUtils;
|
||||||
import com.ruoyi.system.domain_yada.AustraliaMiddleEastVO;
|
import com.ruoyi.common.utils.file.FileUtils;
|
||||||
|
import com.ruoyi.system.domain_yada.*;
|
||||||
import com.ruoyi.system.service_yada.IAorestCoverageService;
|
import com.ruoyi.system.service_yada.IAorestCoverageService;
|
||||||
import com.ruoyi.system.service_yada.IAustraliaMiddleEastService;
|
import com.ruoyi.system.service_yada.IAustraliaMiddleEastService;
|
||||||
|
import com.ruoyi.system.service_yada.ThematicMapService;
|
||||||
|
import io.swagger.annotations.Api;
|
||||||
|
import io.swagger.annotations.ApiImplicitParam;
|
||||||
|
import io.swagger.annotations.ApiOperation;
|
||||||
import org.apache.ibatis.annotations.Param;
|
import org.apache.ibatis.annotations.Param;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
import org.springframework.web.bind.annotation.RequestMapping;
|
import org.springframework.beans.factory.annotation.Value;
|
||||||
import org.springframework.web.bind.annotation.RequestMethod;
|
import org.springframework.web.bind.annotation.*;
|
||||||
import org.springframework.web.bind.annotation.RestController;
|
import org.springframework.web.multipart.MultipartFile;
|
||||||
|
|
||||||
import javax.annotation.Resource;
|
import javax.annotation.Resource;
|
||||||
import javax.servlet.http.HttpServletRequest;
|
import javax.servlet.http.HttpServletRequest;
|
||||||
import javax.servlet.http.HttpServletResponse;
|
import javax.servlet.http.HttpServletResponse;
|
||||||
|
import javax.xml.crypto.Data;
|
||||||
|
import java.io.InputStream;
|
||||||
|
import java.security.Guard;
|
||||||
|
import java.text.SimpleDateFormat;
|
||||||
|
import java.time.LocalDateTime;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 森林覆盖率
|
* 森林覆盖率
|
||||||
* @Author: JinSheng Song
|
|
||||||
* @Date: 2022/5/11 9:08
|
|
||||||
*/
|
*/
|
||||||
@RestController
|
@RestController
|
||||||
@RequestMapping(value = "/business-service/api/Aorest", produces = "application/json;charset=UTF-8")
|
@RequestMapping(value = "/business-service/api/Aorest", produces = "application/json;charset=UTF-8")
|
||||||
|
@Api(tags = "森林覆盖率")
|
||||||
public class AorestCoverageController {
|
public class AorestCoverageController {
|
||||||
@Resource
|
@Resource
|
||||||
private IAorestCoverageService service;
|
private IAorestCoverageService service;
|
||||||
|
|
||||||
|
@Resource
|
||||||
|
private ThematicMapService thematicMapService;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 查询方法
|
* 查询方法
|
||||||
* @param response
|
* 需要查询的字段参数
|
||||||
* @param request
|
* @return 参数类
|
||||||
* @return
|
|
||||||
*/
|
*/
|
||||||
@RequestMapping(value = "/selectAorestCoverage",method = {RequestMethod.POST})
|
@RequestMapping(value = "/selectAorestCoverage",method = {RequestMethod.GET})
|
||||||
public AjaxResult selectAorestCoverage(HttpServletResponse response, HttpServletRequest request)
|
@ApiOperation(value = "查询方法",httpMethod = "GET")
|
||||||
|
public AjaxResult selectAorestCoverage()
|
||||||
{
|
{
|
||||||
List<AorestCoverageVO> eastVOSList= service.selectAorestCoverage();
|
List<AorestCoverageVO> eastVOSList= service.selectAorestCoverage();
|
||||||
return AjaxResult.success(eastVOSList);
|
return AjaxResult.success(eastVOSList);
|
||||||
@ -42,10 +55,12 @@ public class AorestCoverageController {
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* 删除方法
|
* 删除方法
|
||||||
* @param ID
|
* @param ID id
|
||||||
* @return
|
* @return 状态码
|
||||||
*/
|
*/
|
||||||
@RequestMapping(value = "/DelAorestCoverage",method = {RequestMethod.POST})
|
@RequestMapping(value = "/DelAorestCoverage",method = {RequestMethod.DELETE})
|
||||||
|
@ApiImplicitParam(name = "userId", value = "用户ID", required = true, dataType = "int", paramType = "path", dataTypeClass = Integer.class)
|
||||||
|
@ApiOperation(value = "删除方法",httpMethod = "DELETE")
|
||||||
public AjaxResult DelAorestCoverage(@Param("ID") String ID)
|
public AjaxResult DelAorestCoverage(@Param("ID") String ID)
|
||||||
{
|
{
|
||||||
int NUM = service.DelAorestCoverage(ID);
|
int NUM = service.DelAorestCoverage(ID);
|
||||||
@ -59,12 +74,17 @@ public class AorestCoverageController {
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* 新增方法
|
* 新增方法
|
||||||
* @param eastVOS
|
* @param eastVOS 新增实体类
|
||||||
* @return
|
* @return 状态码
|
||||||
*/
|
*/
|
||||||
@RequestMapping(value = "/IntoAorestCoverage",method = {RequestMethod.POST})
|
@RequestMapping(value = "/IntoAorestCoverage",method = {RequestMethod.POST})
|
||||||
public AjaxResult IntoAorestCoverage(AorestCoverageVO eastVOS)
|
@ApiOperation(value = "新增方法",httpMethod = "POST")
|
||||||
|
public AjaxResult IntoAorestCoverage(@RequestBody AorestCoverageVO eastVOS)
|
||||||
{
|
{
|
||||||
|
try {
|
||||||
|
|
||||||
|
|
||||||
|
eastVOS.setCreateTime(LocalDateTime.now());
|
||||||
int NUM = service.IntoAorestCoverage(eastVOS);
|
int NUM = service.IntoAorestCoverage(eastVOS);
|
||||||
if (NUM>0)
|
if (NUM>0)
|
||||||
{
|
{
|
||||||
@ -72,4 +92,81 @@ public class AorestCoverageController {
|
|||||||
}
|
}
|
||||||
return AjaxResult.error();
|
return AjaxResult.error();
|
||||||
}
|
}
|
||||||
|
catch (Exception E){
|
||||||
|
E.getMessage();
|
||||||
|
return AjaxResult.error();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 上传文件
|
||||||
|
* @return 状态码
|
||||||
|
*/
|
||||||
|
@RequestMapping(value = "/IntoUpLoad",method = {RequestMethod.POST})
|
||||||
|
@ApiOperation(value = "上传文件",httpMethod = "POST")
|
||||||
|
public AjaxResult IntoUpload(@RequestBody MultipartFile file)
|
||||||
|
{
|
||||||
|
UploadFile upload=new UploadFile();
|
||||||
|
|
||||||
|
ThematicMapDomain domain=new ThematicMapDomain();
|
||||||
|
|
||||||
|
UploadFile value= null;
|
||||||
|
try {
|
||||||
|
value = uploadFile(file,upload);
|
||||||
|
} catch (Exception e) {
|
||||||
|
e.printStackTrace();
|
||||||
|
}
|
||||||
|
|
||||||
|
int NUM = service.IntoUpload(value);
|
||||||
|
domain.setPictureCode(value.getFileId());
|
||||||
|
|
||||||
|
if (NUM>0)
|
||||||
|
{
|
||||||
|
return AjaxResult.success();
|
||||||
|
}
|
||||||
|
return AjaxResult.error();
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 文件查询
|
||||||
|
* @param response 头
|
||||||
|
* @param request 客户端请求
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
@RequestMapping(value = "/selectUpload",method = {RequestMethod.GET})
|
||||||
|
@ApiOperation(value = "文件查询",httpMethod = "GET")
|
||||||
|
public AjaxResult selectUpload(HttpServletResponse response, HttpServletRequest request,@RequestBody UploadFile upload)
|
||||||
|
{
|
||||||
|
List<UploadFile> eastVOSList= service.selectUpload(upload.getFileId(),upload.getFileName());
|
||||||
|
return AjaxResult.success(eastVOSList);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
public UploadFile uploadFile(MultipartFile file,UploadFile upload) throws Exception
|
||||||
|
{
|
||||||
|
// 上传文件路径
|
||||||
|
String filePath = RuoYiConfig.getUploadPath();
|
||||||
|
// 上传并返回新文件名称
|
||||||
|
String fileName = FileUploadUtils.upload(filePath, file);
|
||||||
|
upload.setFileId(String.valueOf(System.currentTimeMillis()));
|
||||||
|
upload.setFileName(file.getOriginalFilename());
|
||||||
|
upload.setFilePath(fileName);
|
||||||
|
upload.setFileSize(String.valueOf(file.getSize()));
|
||||||
|
upload.setCreateTime(LocalDateTime.now());
|
||||||
|
return upload;
|
||||||
|
}
|
||||||
|
|
||||||
|
@RequestMapping(value = "/Dictionary")
|
||||||
|
@ApiOperation(value = "字典查询",httpMethod = "POST")
|
||||||
|
public AjaxResult Dictionary(@RequestBody Dictionary dic)
|
||||||
|
{
|
||||||
|
List<Dictionary> diclist=service.selectDic(dic.getCodingType(),dic.getCodingType1(), dic.getCodingType2());
|
||||||
|
return AjaxResult.success(diclist);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -3,8 +3,12 @@ package com.ruoyi.web.controller.yada;
|
|||||||
import com.ruoyi.common.core.domain.AjaxResult;
|
import com.ruoyi.common.core.domain.AjaxResult;
|
||||||
import com.ruoyi.system.service_yada.IAustraliaMiddleEastService;
|
import com.ruoyi.system.service_yada.IAustraliaMiddleEastService;
|
||||||
import com.ruoyi.system.domain_yada.AustraliaMiddleEastVO;
|
import com.ruoyi.system.domain_yada.AustraliaMiddleEastVO;
|
||||||
|
import io.swagger.annotations.Api;
|
||||||
|
import io.swagger.annotations.ApiImplicitParam;
|
||||||
|
import io.swagger.annotations.ApiOperation;
|
||||||
import org.apache.ibatis.annotations.Param;
|
import org.apache.ibatis.annotations.Param;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.web.bind.annotation.RequestBody;
|
||||||
import org.springframework.web.bind.annotation.RequestMapping;
|
import org.springframework.web.bind.annotation.RequestMapping;
|
||||||
import org.springframework.web.bind.annotation.RequestMethod;
|
import org.springframework.web.bind.annotation.RequestMethod;
|
||||||
import org.springframework.web.bind.annotation.RestController;
|
import org.springframework.web.bind.annotation.RestController;
|
||||||
@ -12,15 +16,15 @@ import org.springframework.web.bind.annotation.RestController;
|
|||||||
import javax.annotation.Resource;
|
import javax.annotation.Resource;
|
||||||
import javax.servlet.http.HttpServletRequest;
|
import javax.servlet.http.HttpServletRequest;
|
||||||
import javax.servlet.http.HttpServletResponse;
|
import javax.servlet.http.HttpServletResponse;
|
||||||
|
import java.time.LocalDateTime;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 澳大利亚中东部地区
|
* 澳大利亚中东部地区
|
||||||
* @Author: JinSheng Song
|
|
||||||
* @Date: 2022/5/11 9:08
|
|
||||||
*/
|
*/
|
||||||
@RestController
|
@RestController
|
||||||
@RequestMapping(value = "/business-service/api/Australia", produces = "application/json;charset=UTF-8")
|
@RequestMapping(value = "/business-service/api/Australia", produces = "application/json;charset=UTF-8")
|
||||||
|
@Api(tags = "澳大利亚中东部地区")
|
||||||
public class AustraliaMiddleEastController
|
public class AustraliaMiddleEastController
|
||||||
{
|
{
|
||||||
@Resource
|
@Resource
|
||||||
@ -28,23 +32,24 @@ public class AustraliaMiddleEastController
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* 查询方法
|
* 查询方法
|
||||||
* @param response
|
* @return 实体类
|
||||||
* @param request
|
|
||||||
* @return
|
|
||||||
*/
|
*/
|
||||||
@RequestMapping(value = "/SelectAustralia",method = {RequestMethod.POST})
|
@ApiOperation(value = "查询方法",httpMethod = "GET")
|
||||||
public AjaxResult SelectAustralia(HttpServletResponse response, HttpServletRequest request)
|
@RequestMapping(value = "/SelectAustralia",method = {RequestMethod.GET})
|
||||||
|
public AjaxResult SelectAustralia(@RequestBody AustraliaMiddleEastVO eastVO )
|
||||||
{
|
{
|
||||||
List<AustraliaMiddleEastVO> eastVOSList= australiaMiddleEastService.selectAustralia();
|
List<AustraliaMiddleEastVO> eastVOSList= australiaMiddleEastService.selectAustralia(eastVO.getYearMonth(),eastVO.getMonth());
|
||||||
return AjaxResult.success(eastVOSList);
|
return AjaxResult.success(eastVOSList);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 删除方法
|
* 删除方法
|
||||||
* @param ID
|
* @param ID id
|
||||||
* @return
|
* @return 状态码
|
||||||
*/
|
*/
|
||||||
@RequestMapping(value = "/DelAustralia",method = {RequestMethod.POST})
|
@RequestMapping(value = "/DelAustralia",method = {RequestMethod.DELETE})
|
||||||
|
@ApiImplicitParam(name = "userId", value = "用户ID", required = true, dataType = "int", paramType = "path", dataTypeClass = Integer.class)
|
||||||
|
@ApiOperation(value = "删除方法",httpMethod = "DELETE")
|
||||||
public AjaxResult DelAustralia(@Param("ID") String ID)
|
public AjaxResult DelAustralia(@Param("ID") String ID)
|
||||||
{
|
{
|
||||||
int NUM = australiaMiddleEastService.DelAustralia(ID);
|
int NUM = australiaMiddleEastService.DelAustralia(ID);
|
||||||
@ -58,12 +63,14 @@ public class AustraliaMiddleEastController
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* 新增方法
|
* 新增方法
|
||||||
* @param eastVOS
|
* @param eastVOS 新增实体类
|
||||||
* @return
|
* @return 状态码
|
||||||
*/
|
*/
|
||||||
@RequestMapping(value = "/IntoAustralia",method = {RequestMethod.POST})
|
@RequestMapping(value = "/IntoAustralia",method = {RequestMethod.POST})
|
||||||
public AjaxResult IntoAustralia(AustraliaMiddleEastVO eastVOS)
|
@ApiOperation(value = "新增方法",httpMethod = "POST")
|
||||||
|
public AjaxResult IntoAustralia(@RequestBody AustraliaMiddleEastVO eastVOS)
|
||||||
{
|
{
|
||||||
|
eastVOS.setCreateTime(LocalDateTime.now());
|
||||||
int NUM = australiaMiddleEastService.IntoAustralia(eastVOS);
|
int NUM = australiaMiddleEastService.IntoAustralia(eastVOS);
|
||||||
if (NUM>0)
|
if (NUM>0)
|
||||||
{
|
{
|
||||||
|
@ -5,8 +5,12 @@ import com.ruoyi.system.domain_yada.AustraliaMiddleEastVO;
|
|||||||
import com.ruoyi.system.domain_yada.GlobalTypeVO;
|
import com.ruoyi.system.domain_yada.GlobalTypeVO;
|
||||||
import com.ruoyi.system.service_yada.IAustraliaMiddleEastService;
|
import com.ruoyi.system.service_yada.IAustraliaMiddleEastService;
|
||||||
import com.ruoyi.system.service_yada.IGlobalTypeService;
|
import com.ruoyi.system.service_yada.IGlobalTypeService;
|
||||||
|
import io.swagger.annotations.Api;
|
||||||
|
import io.swagger.annotations.ApiImplicitParam;
|
||||||
|
import io.swagger.annotations.ApiOperation;
|
||||||
import org.apache.ibatis.annotations.Param;
|
import org.apache.ibatis.annotations.Param;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.web.bind.annotation.RequestBody;
|
||||||
import org.springframework.web.bind.annotation.RequestMapping;
|
import org.springframework.web.bind.annotation.RequestMapping;
|
||||||
import org.springframework.web.bind.annotation.RequestMethod;
|
import org.springframework.web.bind.annotation.RequestMethod;
|
||||||
import org.springframework.web.bind.annotation.RestController;
|
import org.springframework.web.bind.annotation.RestController;
|
||||||
@ -14,38 +18,41 @@ import org.springframework.web.bind.annotation.RestController;
|
|||||||
import javax.annotation.Resource;
|
import javax.annotation.Resource;
|
||||||
import javax.servlet.http.HttpServletRequest;
|
import javax.servlet.http.HttpServletRequest;
|
||||||
import javax.servlet.http.HttpServletResponse;
|
import javax.servlet.http.HttpServletResponse;
|
||||||
|
import java.time.LocalDateTime;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*全球各类型占比
|
*全球各类型占比
|
||||||
* @Author: JinSheng Song
|
|
||||||
* @Date: 2022/5/11 9:05
|
|
||||||
*/
|
*/
|
||||||
@RestController
|
@RestController
|
||||||
@RequestMapping("/monitor/clobal")
|
@RequestMapping("/monitor/clobal")
|
||||||
|
@Api(tags = "全球各类型占比")
|
||||||
public class GlobalTypeController {
|
public class GlobalTypeController {
|
||||||
@Resource
|
@Resource
|
||||||
private IGlobalTypeService typeService;
|
private IGlobalTypeService typeService;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 查询方法
|
* 查询方法
|
||||||
* @param response
|
* @param response 响应头
|
||||||
* @param request
|
* @param request 客户端请求
|
||||||
* @return
|
* @return 参数类
|
||||||
*/
|
*/
|
||||||
@RequestMapping(value = "/selectGlobalType",method = {RequestMethod.POST})
|
@RequestMapping(value = "/selectGlobalType",method = {RequestMethod.POST})
|
||||||
public AjaxResult selectGlobalType(HttpServletResponse response, HttpServletRequest request)
|
@ApiOperation(value = "查询方法",httpMethod = "POST")
|
||||||
|
public AjaxResult selectGlobalType(HttpServletResponse response, HttpServletRequest request,@RequestBody GlobalTypeVO TypeVO)
|
||||||
{
|
{
|
||||||
List<GlobalTypeVO> eastVOSList= typeService.selectGlobalType();
|
List<GlobalTypeVO> eastVOSList= typeService.selectGlobalType(TypeVO.getTypeName(),TypeVO.getParticularYear());
|
||||||
return AjaxResult.success(eastVOSList);
|
return AjaxResult.success(eastVOSList);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 删除方法
|
* 删除方法
|
||||||
* @param ID
|
* @param ID id
|
||||||
* @return
|
* @return 状态码
|
||||||
*/
|
*/
|
||||||
@RequestMapping(value = "/DelGlobalType",method = {RequestMethod.POST})
|
@RequestMapping(value = "/DelGlobalType",method = {RequestMethod.DELETE})
|
||||||
|
@ApiOperation(value = "删除方法",httpMethod = "DELETE")
|
||||||
|
@ApiImplicitParam(name = "userId", value = "用户ID", required = true, dataType = "int", paramType = "path", dataTypeClass = Integer.class)
|
||||||
public AjaxResult DelGlobalType(@Param("ID") String ID)
|
public AjaxResult DelGlobalType(@Param("ID") String ID)
|
||||||
{
|
{
|
||||||
int NUM = typeService.DelGlobalType(ID);
|
int NUM = typeService.DelGlobalType(ID);
|
||||||
@ -59,12 +66,14 @@ public class GlobalTypeController {
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* 新增方法
|
* 新增方法
|
||||||
* @param eastVOS
|
* @param eastVOS 新增实体类
|
||||||
* @return
|
* @return 状态码
|
||||||
*/
|
*/
|
||||||
|
@ApiOperation(value = "新增方法",httpMethod = "POST")
|
||||||
@RequestMapping(value = "/IntoGlobalType",method = {RequestMethod.POST})
|
@RequestMapping(value = "/IntoGlobalType",method = {RequestMethod.POST})
|
||||||
public AjaxResult IntoGlobalType(GlobalTypeVO eastVOS)
|
public AjaxResult IntoGlobalType(@RequestBody GlobalTypeVO eastVOS)
|
||||||
{
|
{
|
||||||
|
eastVOS.setCreateTime(LocalDateTime.now());
|
||||||
int NUM = typeService.IntoGlobalType(eastVOS);
|
int NUM = typeService.IntoGlobalType(eastVOS);
|
||||||
if (NUM>0)
|
if (NUM>0)
|
||||||
{
|
{
|
||||||
|
@ -5,8 +5,12 @@ import com.ruoyi.system.domain_yada.AustraliaMiddleEastVO;
|
|||||||
import com.ruoyi.system.domain_yada.OceanTemperatureVO;
|
import com.ruoyi.system.domain_yada.OceanTemperatureVO;
|
||||||
import com.ruoyi.system.service_yada.IAustraliaMiddleEastService;
|
import com.ruoyi.system.service_yada.IAustraliaMiddleEastService;
|
||||||
import com.ruoyi.system.service_yada.IOceanTemperatureService;
|
import com.ruoyi.system.service_yada.IOceanTemperatureService;
|
||||||
|
import io.swagger.annotations.Api;
|
||||||
|
import io.swagger.annotations.ApiImplicitParam;
|
||||||
|
import io.swagger.annotations.ApiOperation;
|
||||||
import org.apache.ibatis.annotations.Param;
|
import org.apache.ibatis.annotations.Param;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.web.bind.annotation.RequestBody;
|
||||||
import org.springframework.web.bind.annotation.RequestMapping;
|
import org.springframework.web.bind.annotation.RequestMapping;
|
||||||
import org.springframework.web.bind.annotation.RequestMethod;
|
import org.springframework.web.bind.annotation.RequestMethod;
|
||||||
import org.springframework.web.bind.annotation.RestController;
|
import org.springframework.web.bind.annotation.RestController;
|
||||||
@ -14,13 +18,13 @@ import org.springframework.web.bind.annotation.RestController;
|
|||||||
import javax.annotation.Resource;
|
import javax.annotation.Resource;
|
||||||
import javax.servlet.http.HttpServletRequest;
|
import javax.servlet.http.HttpServletRequest;
|
||||||
import javax.servlet.http.HttpServletResponse;
|
import javax.servlet.http.HttpServletResponse;
|
||||||
|
import java.time.LocalDateTime;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 海洋表面温度监测
|
* 海洋表面温度监测
|
||||||
* @Author: JinSheng Song
|
|
||||||
* @Date: 2022/5/11 9:13
|
|
||||||
*/
|
*/
|
||||||
|
@Api(tags = "海洋表面温度监测")
|
||||||
@RestController
|
@RestController
|
||||||
@RequestMapping(value = "/business-service/api/Ocean", produces = "application/json;charset=UTF-8")
|
@RequestMapping(value = "/business-service/api/Ocean", produces = "application/json;charset=UTF-8")
|
||||||
public class OceanTemperatureController {
|
public class OceanTemperatureController {
|
||||||
@ -29,23 +33,25 @@ public class OceanTemperatureController {
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* 查询方法
|
* 查询方法
|
||||||
* @param response
|
* @return 参数类
|
||||||
* @param request
|
|
||||||
* @return
|
|
||||||
*/
|
*/
|
||||||
@RequestMapping(value = "/selectOcean",method = {RequestMethod.POST})
|
@RequestMapping(value = "/selectOcean",method = {RequestMethod.GET})
|
||||||
public AjaxResult selectOcean(HttpServletResponse response, HttpServletRequest request)
|
@ApiOperation(value = "查询方法",httpMethod = "GET")
|
||||||
|
public AjaxResult selectOcean(@RequestBody OceanTemperatureVO temperatureVO)
|
||||||
{
|
{
|
||||||
List<OceanTemperatureVO> eastVOSList= temperatureService.selectOcean();
|
List<OceanTemperatureVO> eastVOSList= temperatureService.selectOcean(temperatureVO.getStartDate());
|
||||||
return AjaxResult.success(eastVOSList);
|
return AjaxResult.success(eastVOSList);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 删除方法
|
* 删除方法
|
||||||
* @param ID
|
* @param ID id
|
||||||
* @return
|
* @return 状态码
|
||||||
*/
|
*/
|
||||||
@RequestMapping(value = "/DelOcean",method = {RequestMethod.POST})
|
@RequestMapping(value = "/DelOcean",method = {RequestMethod.DELETE})
|
||||||
|
@ApiOperation(value = "删除方法",httpMethod = "DELETE")
|
||||||
|
@ApiImplicitParam(name = "userId", value = "用户ID", required = true, dataType = "int", paramType = "path", dataTypeClass = Integer.class)
|
||||||
|
|
||||||
public AjaxResult DelOcean(@Param("ID") String ID)
|
public AjaxResult DelOcean(@Param("ID") String ID)
|
||||||
{
|
{
|
||||||
int NUM = temperatureService.DelOcean(ID);
|
int NUM = temperatureService.DelOcean(ID);
|
||||||
@ -59,12 +65,14 @@ public class OceanTemperatureController {
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* 新增方法
|
* 新增方法
|
||||||
* @param eastVOS
|
* @param eastVOS 新增实体类
|
||||||
* @return
|
* @return 状态码
|
||||||
*/
|
*/
|
||||||
|
@ApiOperation(value = "新增方法",httpMethod = "POST")
|
||||||
@RequestMapping(value = "/IntoAustralia",method = {RequestMethod.POST})
|
@RequestMapping(value = "/IntoAustralia",method = {RequestMethod.POST})
|
||||||
public AjaxResult IntoOcean(OceanTemperatureVO eastVOS)
|
public AjaxResult IntoOcean(@RequestBody OceanTemperatureVO eastVOS)
|
||||||
{
|
{
|
||||||
|
eastVOS.setCreateTime(LocalDateTime.now());
|
||||||
int NUM = temperatureService.IntoOcean(eastVOS);
|
int NUM = temperatureService.IntoOcean(eastVOS);
|
||||||
if (NUM>0)
|
if (NUM>0)
|
||||||
{
|
{
|
||||||
|
@ -3,8 +3,12 @@ package com.ruoyi.web.controller.yada;
|
|||||||
import com.ruoyi.common.core.domain.AjaxResult;
|
import com.ruoyi.common.core.domain.AjaxResult;
|
||||||
import com.ruoyi.system.service_yada.IRegionVGIService;
|
import com.ruoyi.system.service_yada.IRegionVGIService;
|
||||||
import com.ruoyi.system.domain_yada.RegionVGIVO;
|
import com.ruoyi.system.domain_yada.RegionVGIVO;
|
||||||
|
import io.swagger.annotations.Api;
|
||||||
|
import io.swagger.annotations.ApiImplicitParam;
|
||||||
|
import io.swagger.annotations.ApiOperation;
|
||||||
import org.apache.ibatis.annotations.Param;
|
import org.apache.ibatis.annotations.Param;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.web.bind.annotation.RequestBody;
|
||||||
import org.springframework.web.bind.annotation.RequestMapping;
|
import org.springframework.web.bind.annotation.RequestMapping;
|
||||||
|
|
||||||
import org.springframework.web.bind.annotation.RequestMethod;
|
import org.springframework.web.bind.annotation.RequestMethod;
|
||||||
@ -13,13 +17,13 @@ import org.springframework.web.bind.annotation.RestController;
|
|||||||
import javax.annotation.Resource;
|
import javax.annotation.Resource;
|
||||||
import javax.servlet.http.HttpServletRequest;
|
import javax.servlet.http.HttpServletRequest;
|
||||||
import javax.servlet.http.HttpServletResponse;
|
import javax.servlet.http.HttpServletResponse;
|
||||||
|
import java.time.LocalDateTime;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 各区域VGI
|
* 各区域VGI
|
||||||
* @Author: JinSheng Song
|
|
||||||
* @Date: 2022/5/11 9:08
|
|
||||||
*/
|
*/
|
||||||
|
@Api(tags = "各区域VGI")
|
||||||
@RestController
|
@RestController
|
||||||
@RequestMapping(value = "/business-service/api/orderMng", produces = "application/json;charset=UTF-8")
|
@RequestMapping(value = "/business-service/api/orderMng", produces = "application/json;charset=UTF-8")
|
||||||
public class RegionVGIController
|
public class RegionVGIController
|
||||||
@ -28,12 +32,11 @@ public class RegionVGIController
|
|||||||
private IRegionVGIService regionVGIService;
|
private IRegionVGIService regionVGIService;
|
||||||
/**
|
/**
|
||||||
* 查询方法
|
* 查询方法
|
||||||
* @param response
|
* @return 参数类
|
||||||
* @param request
|
|
||||||
* @return
|
|
||||||
*/
|
*/
|
||||||
@RequestMapping(value = "/SelectRegion",method = {RequestMethod.POST})
|
@RequestMapping(value = "/SelectRegion",method = {RequestMethod.GET})
|
||||||
public AjaxResult SelectRegion(HttpServletResponse response, HttpServletRequest request)
|
@ApiOperation(value = "查询方法",httpMethod = "GET")
|
||||||
|
public AjaxResult SelectRegion()
|
||||||
{
|
{
|
||||||
List<RegionVGIVO> vgivost= regionVGIService.selectRegion();
|
List<RegionVGIVO> vgivost= regionVGIService.selectRegion();
|
||||||
return AjaxResult.success(vgivost);
|
return AjaxResult.success(vgivost);
|
||||||
@ -41,10 +44,12 @@ public class RegionVGIController
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* 删除方法
|
* 删除方法
|
||||||
* @param ID
|
* @param ID id
|
||||||
* @return
|
* @return 状态码
|
||||||
*/
|
*/
|
||||||
@RequestMapping(value = "/DelRegion",method = {RequestMethod.POST})
|
@RequestMapping(value = "/DelRegion",method = {RequestMethod.DELETE})
|
||||||
|
@ApiOperation(value = "删除方法",httpMethod = "DELETE")
|
||||||
|
@ApiImplicitParam(name = "userId", value = "用户ID", required = true, dataType = "int", paramType = "path", dataTypeClass = Integer.class)
|
||||||
public AjaxResult DelRegion(@Param("ID") String ID)
|
public AjaxResult DelRegion(@Param("ID") String ID)
|
||||||
{
|
{
|
||||||
int NUM = regionVGIService.DelRegion(ID);
|
int NUM = regionVGIService.DelRegion(ID);
|
||||||
@ -58,12 +63,14 @@ public class RegionVGIController
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* 新增方法
|
* 新增方法
|
||||||
* @param vgivo
|
* @param vgivo 新增实体类
|
||||||
* @return
|
* @return 状态码
|
||||||
*/
|
*/
|
||||||
|
@ApiOperation(value = "新增方法",httpMethod = "POST")
|
||||||
@RequestMapping(value = "/IntoRegion",method = {RequestMethod.POST})
|
@RequestMapping(value = "/IntoRegion",method = {RequestMethod.POST})
|
||||||
public AjaxResult IntoRegion(RegionVGIVO vgivo)
|
public AjaxResult IntoRegion(@RequestBody RegionVGIVO vgivo)
|
||||||
{
|
{
|
||||||
|
vgivo.setCreatedTime(LocalDateTime.now());
|
||||||
int NUM = regionVGIService.IntoRegion(vgivo);
|
int NUM = regionVGIService.IntoRegion(vgivo);
|
||||||
if (NUM>0)
|
if (NUM>0)
|
||||||
{
|
{
|
||||||
|
@ -6,22 +6,19 @@ import com.ruoyi.system.domain_yada.RegionVGIVO;
|
|||||||
import com.ruoyi.system.domain_yada.RegionalSystemVO;
|
import com.ruoyi.system.domain_yada.RegionalSystemVO;
|
||||||
import com.ruoyi.system.service_yada.IAustraliaMiddleEastService;
|
import com.ruoyi.system.service_yada.IAustraliaMiddleEastService;
|
||||||
import com.ruoyi.system.service_yada.IRegionalSystemService;
|
import com.ruoyi.system.service_yada.IRegionalSystemService;
|
||||||
import org.apache.ibatis.annotations.Param;
|
import io.swagger.annotations.Api;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import io.swagger.annotations.ApiImplicitParam;
|
||||||
import org.springframework.web.bind.annotation.RequestMapping;
|
import io.swagger.annotations.ApiOperation;
|
||||||
import org.springframework.web.bind.annotation.RequestMethod;
|
import org.springframework.web.bind.annotation.*;
|
||||||
import org.springframework.web.bind.annotation.RestController;
|
|
||||||
|
|
||||||
import javax.annotation.Resource;
|
import javax.annotation.Resource;
|
||||||
import javax.servlet.http.HttpServletRequest;
|
import java.time.LocalDateTime;
|
||||||
import javax.servlet.http.HttpServletResponse;
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 区域生态系统
|
* 区域生态系统
|
||||||
* @Author: JinSheng Song
|
|
||||||
* @Date: 2022/5/11 9:12
|
|
||||||
*/
|
*/
|
||||||
|
@Api(tags = "区域生态系统")
|
||||||
@RestController
|
@RestController
|
||||||
@RequestMapping(value = "/business-service/api/Regional", produces = "application/json;charset=UTF-8")
|
@RequestMapping(value = "/business-service/api/Regional", produces = "application/json;charset=UTF-8")
|
||||||
public class RegionalSystemController {
|
public class RegionalSystemController {
|
||||||
@ -30,24 +27,25 @@ public class RegionalSystemController {
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* 查询方法
|
* 查询方法
|
||||||
* @param response
|
* @return 参数类
|
||||||
* @param request
|
|
||||||
* @return
|
|
||||||
*/
|
*/
|
||||||
@RequestMapping(value = "/selectRegional",method = {RequestMethod.POST})
|
@RequestMapping(value = "/selectRegional",method = {RequestMethod.GET})
|
||||||
public AjaxResult selectRegional(HttpServletResponse response, HttpServletRequest request)
|
@ApiOperation(value = "查询方法",httpMethod = "GET")
|
||||||
|
public AjaxResult selectRegional(@RequestParam("region") String region)
|
||||||
{
|
{
|
||||||
List<RegionalSystemVO> eastVOSList= systemService.selectRegional();
|
List<RegionalSystemVO> eastVOSList= systemService.selectRegional(region);
|
||||||
return AjaxResult.success(eastVOSList);
|
return AjaxResult.success(eastVOSList);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 删除方法
|
* 删除方法
|
||||||
* @param ID
|
* @param ID id
|
||||||
* @return
|
* @return 状态码
|
||||||
*/
|
*/
|
||||||
@RequestMapping(value = "/DelRegional",method = {RequestMethod.POST})
|
@RequestMapping(value = "/DelRegional",method = {RequestMethod.DELETE})
|
||||||
public AjaxResult DelRegional(@Param("ID") String ID)
|
@ApiOperation(value = "删除方法",httpMethod = "DELETE")
|
||||||
|
@ApiImplicitParam(name = "userId", value = "用户ID", required = true, dataType = "int", paramType = "path", dataTypeClass = Integer.class)
|
||||||
|
public AjaxResult DelRegional(@RequestParam("ID") String ID)
|
||||||
{
|
{
|
||||||
int NUM = systemService.DelRegional(ID);
|
int NUM = systemService.DelRegional(ID);
|
||||||
if (NUM>0)
|
if (NUM>0)
|
||||||
@ -60,12 +58,14 @@ public class RegionalSystemController {
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* 新增方法
|
* 新增方法
|
||||||
* @param eastVOS
|
* @param eastVOS 新增实体类
|
||||||
* @return
|
* @return 状态码
|
||||||
*/
|
*/
|
||||||
|
@ApiOperation(value = "新增方法",httpMethod = "POST")
|
||||||
@RequestMapping(value = "/IntoRegional",method = {RequestMethod.POST})
|
@RequestMapping(value = "/IntoRegional",method = {RequestMethod.POST})
|
||||||
public AjaxResult IntoRegional(RegionalSystemVO eastVOS)
|
public AjaxResult IntoRegional(@RequestBody RegionalSystemVO eastVOS)
|
||||||
{
|
{
|
||||||
|
eastVOS.setCreateTime(LocalDateTime.now());
|
||||||
int NUM = systemService.IntoRegional(eastVOS);
|
int NUM = systemService.IntoRegional(eastVOS);
|
||||||
if (NUM>0)
|
if (NUM>0)
|
||||||
{
|
{
|
||||||
|
@ -0,0 +1,330 @@
|
|||||||
|
package com.ruoyi.web.controller.yada;
|
||||||
|
|
||||||
|
import com.alibaba.fastjson.JSON;
|
||||||
|
import com.alibaba.fastjson.JSONObject;
|
||||||
|
import com.ruoyi.common.core.domain.AjaxResult;
|
||||||
|
import com.ruoyi.common.utils.file.WeatherUtils;
|
||||||
|
import com.ruoyi.system.domain_yada.*;
|
||||||
|
import com.ruoyi.system.service_yada.*;
|
||||||
|
import io.swagger.annotations.Api;
|
||||||
|
import io.swagger.annotations.ApiOperation;
|
||||||
|
import jdk.jfr.Frequency;
|
||||||
|
import org.apache.poi.ss.usermodel.Row;
|
||||||
|
import org.apache.poi.ss.usermodel.Sheet;
|
||||||
|
import org.apache.poi.ss.usermodel.Workbook;
|
||||||
|
import org.apache.poi.xssf.usermodel.XSSFSheet;
|
||||||
|
import org.apache.poi.xssf.usermodel.XSSFWorkbook;
|
||||||
|
import org.springframework.beans.factory.annotation.Value;
|
||||||
|
import org.springframework.web.bind.annotation.RequestBody;
|
||||||
|
import org.springframework.web.bind.annotation.RequestMapping;
|
||||||
|
import org.springframework.web.bind.annotation.RequestMethod;
|
||||||
|
import org.springframework.web.bind.annotation.RestController;
|
||||||
|
import org.springframework.web.multipart.MultipartFile;
|
||||||
|
import springfox.documentation.spring.web.json.Json;
|
||||||
|
|
||||||
|
import javax.annotation.Resource;
|
||||||
|
import javax.servlet.http.HttpServletRequest;
|
||||||
|
import javax.servlet.http.HttpServletResponse;
|
||||||
|
import java.io.IOException;
|
||||||
|
import java.io.InputStream;
|
||||||
|
import java.math.BigDecimal;
|
||||||
|
import java.net.http.HttpRequest;
|
||||||
|
import java.time.LocalDateTime;
|
||||||
|
import java.util.ArrayList;
|
||||||
|
import java.util.HashMap;
|
||||||
|
import java.util.List;
|
||||||
|
import java.util.Map;
|
||||||
|
|
||||||
|
@RestController
|
||||||
|
@RequestMapping(value = "/Special")
|
||||||
|
@Api(tags = "模板导入")
|
||||||
|
public class SpecialController {
|
||||||
|
|
||||||
|
@Resource
|
||||||
|
private IRegionVGIService regionVGIService;
|
||||||
|
|
||||||
|
@Resource
|
||||||
|
private IAustraliaMiddleEastService australiaMiddleEastService;
|
||||||
|
|
||||||
|
@Resource
|
||||||
|
private IAorestCoverageService service;
|
||||||
|
|
||||||
|
@Resource
|
||||||
|
private IVegetationCoverageService coverageService;
|
||||||
|
|
||||||
|
@Resource
|
||||||
|
private IRegionalSystemService systemService;
|
||||||
|
|
||||||
|
/**
|
||||||
|
*/
|
||||||
|
|
||||||
|
@RequestMapping(value = "/helpSaveExcel")
|
||||||
|
private AjaxResult helpSaveExcel(@RequestBody MultipartFile file) {
|
||||||
|
List<RegionVGIVO> value = saveExcel(file);
|
||||||
|
|
||||||
|
return IntoRegion(value);
|
||||||
|
}
|
||||||
|
|
||||||
|
@RequestMapping(value = "/helpWeatherClass",method = {RequestMethod.GET})
|
||||||
|
public AjaxResult helpWeatherClass(String city,String type)
|
||||||
|
{
|
||||||
|
String url="https://restapi.amap.com/v3/weather/weatherInfo";
|
||||||
|
Map<String,String> map=new HashMap<>();
|
||||||
|
map.put("key","37087f0a3007dc67d37859553cd02d33");
|
||||||
|
map.put("city",city);
|
||||||
|
if (type!=null){ map.put("extensions",type);}
|
||||||
|
map.put("output","json");
|
||||||
|
String value= WeatherUtils.httpRequest(url,map);
|
||||||
|
WeatherUtilsVO vo = JSON.parseObject(value,WeatherUtilsVO.class);
|
||||||
|
// String value2=vo.getForecasts().substring(1,vo.getForecasts().length()-1);
|
||||||
|
// System.out.println(value2);
|
||||||
|
// vo.setForecast(JSON.parseObject(value2,ForecastVo.class));
|
||||||
|
// JSONObject userJson=JSONObject.parseObject(value);
|
||||||
|
// WeatherUtilsVO utilsValue= JSON.toJavaObject(userJson,WeatherUtilsVO.class);
|
||||||
|
|
||||||
|
return AjaxResult.success(vo);
|
||||||
|
} /**
|
||||||
|
* 森林覆盖率模板导入
|
||||||
|
*/
|
||||||
|
@RequestMapping(value = "/helpExcelAorest")
|
||||||
|
private AjaxResult helpExcelAorest(@RequestBody MultipartFile file) {
|
||||||
|
List<AorestCoverageVO> value = saveExcelAorest(file);
|
||||||
|
|
||||||
|
return IntoAorestCoverage(value);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
*平均植被覆盖度和净初级生产力
|
||||||
|
*/
|
||||||
|
@RequestMapping(value = "/helpExcelnpp")
|
||||||
|
private AjaxResult helpExcelnpp(@RequestBody MultipartFile file) {
|
||||||
|
List<VegetationCoverageVO> value = saveExcelnpp(file);
|
||||||
|
|
||||||
|
return IntoVegetation(value);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 澳大利亚中部地区模板导入
|
||||||
|
*/
|
||||||
|
@RequestMapping(value = "/helpExcelAus")
|
||||||
|
private AjaxResult helpExcelAus(@RequestBody MultipartFile file) {
|
||||||
|
List<AustraliaMiddleEastVO> value = saveExcelAus(file);
|
||||||
|
|
||||||
|
return IntoAustralia(value);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 区域生态系统类型转移
|
||||||
|
*/
|
||||||
|
@RequestMapping(value = "/helpExcelRegion")
|
||||||
|
private AjaxResult helpExcelRegion(@RequestBody MultipartFile file) {
|
||||||
|
List<RegionalSystemVO> value = saveExcelRegion(file);
|
||||||
|
|
||||||
|
return IntoRegional(value);
|
||||||
|
}
|
||||||
|
|
||||||
|
public AjaxResult IntoRegional(List<RegionalSystemVO> eastVOS)
|
||||||
|
{
|
||||||
|
try {
|
||||||
|
for (int i = 0; i < eastVOS.size(); i++) {
|
||||||
|
eastVOS.get(i).setCreateTime(LocalDateTime.now());
|
||||||
|
systemService.IntoRegional(eastVOS.get(i));
|
||||||
|
}
|
||||||
|
return AjaxResult.success();
|
||||||
|
}
|
||||||
|
catch (Exception E){
|
||||||
|
E.getMessage();
|
||||||
|
return AjaxResult.error(E.getMessage());
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
public AjaxResult IntoAustralia(List<AustraliaMiddleEastVO> eastVOS) {
|
||||||
|
|
||||||
|
for (int i = 0; i < eastVOS.size(); i++) {
|
||||||
|
eastVOS.get(i).setCreateTime(LocalDateTime.now());
|
||||||
|
australiaMiddleEastService.IntoAustralia(eastVOS.get(i));
|
||||||
|
}
|
||||||
|
|
||||||
|
return AjaxResult.success();
|
||||||
|
}
|
||||||
|
|
||||||
|
public AjaxResult IntoRegion(List<RegionVGIVO> vgivo) {
|
||||||
|
for (int i = 0; i < vgivo.size(); i++) {
|
||||||
|
vgivo.get(i).setCreatedTime(LocalDateTime.now());
|
||||||
|
|
||||||
|
regionVGIService.IntoRegion(vgivo.get(i));
|
||||||
|
}
|
||||||
|
|
||||||
|
return AjaxResult.success();
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
public AjaxResult IntoAorestCoverage(List<AorestCoverageVO> eastVOS)
|
||||||
|
{
|
||||||
|
try {
|
||||||
|
for (int i = 0; i < eastVOS.size(); i++) {
|
||||||
|
eastVOS.get(i).setCreateTime(LocalDateTime.now());
|
||||||
|
service.IntoAorestCoverage(eastVOS.get(i));
|
||||||
|
}
|
||||||
|
return AjaxResult.success();
|
||||||
|
}
|
||||||
|
catch (Exception E){
|
||||||
|
E.getMessage();
|
||||||
|
return AjaxResult.error(E.getMessage());
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
public AjaxResult IntoVegetation(List<VegetationCoverageVO> eastVOS)
|
||||||
|
{
|
||||||
|
try {
|
||||||
|
for (int i = 0; i < eastVOS.size(); i++) {
|
||||||
|
eastVOS.get(i).setCreateTime(LocalDateTime.now());
|
||||||
|
coverageService.IntoVegetation(eastVOS.get(i));
|
||||||
|
}
|
||||||
|
return AjaxResult.success();
|
||||||
|
}
|
||||||
|
catch (Exception E){
|
||||||
|
E.getMessage();
|
||||||
|
return AjaxResult.error(E.getMessage());
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private List<RegionVGIVO> saveExcel(MultipartFile file) {
|
||||||
|
|
||||||
|
try {
|
||||||
|
List<RegionVGIVO> Value = new ArrayList<>();
|
||||||
|
InputStream inputStream = file.getInputStream();
|
||||||
|
Workbook book;
|
||||||
|
Sheet sheet;
|
||||||
|
book = new XSSFWorkbook(inputStream);
|
||||||
|
sheet = book.getSheetAt(0);
|
||||||
|
for (int i = 1; i < sheet.getLastRowNum() + 1; i++) {
|
||||||
|
RegionVGIVO value = new RegionVGIVO();
|
||||||
|
Row row = sheet.getRow(i);
|
||||||
|
value.setCreatedTime(LocalDateTime.now());
|
||||||
|
value.setRegion(row.getCell(0).toString());
|
||||||
|
value.setRegionEn(row.getCell(1).toString());
|
||||||
|
value.setForest(Double.parseDouble(row.getCell(2).toString()));
|
||||||
|
value.setGrassland(Double.parseDouble(row.getCell(3).toString()));
|
||||||
|
value.setParticularYear(row.getCell(4).toString());
|
||||||
|
Value.add(value);
|
||||||
|
}
|
||||||
|
return Value;
|
||||||
|
} catch (IOException e) {
|
||||||
|
e.printStackTrace();
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
private List<AustraliaMiddleEastVO> saveExcelAus(MultipartFile file) {
|
||||||
|
|
||||||
|
try {
|
||||||
|
List<AustraliaMiddleEastVO> Value = new ArrayList<>();
|
||||||
|
InputStream inputStream = file.getInputStream();
|
||||||
|
Workbook book;
|
||||||
|
Sheet sheet;
|
||||||
|
book = new XSSFWorkbook(inputStream);
|
||||||
|
sheet = book.getSheetAt(0);
|
||||||
|
for (int i = 1; i < sheet.getLastRowNum() + 1; i++) {
|
||||||
|
AustraliaMiddleEastVO value = new AustraliaMiddleEastVO();
|
||||||
|
Row row = sheet.getRow(i);
|
||||||
|
value.setYearMonth(row.getCell(0).toString());
|
||||||
|
value.setMonth(row.getCell(1).toString());
|
||||||
|
value.setSstAnomalyIndex(Double.parseDouble(row.getCell(2).toString()));
|
||||||
|
value.setTemperatureAnomolies(Double.parseDouble(row.getCell(3).toString()));
|
||||||
|
value.setPrecipitationAnomolies(Double.parseDouble(row.getCell(4).toString()));
|
||||||
|
value.setVaiAnomolies(Double.parseDouble(row.getCell(5).toString()));
|
||||||
|
Value.add(value);
|
||||||
|
}
|
||||||
|
return Value;
|
||||||
|
} catch (IOException e) {
|
||||||
|
e.printStackTrace();
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private List<AorestCoverageVO> saveExcelAorest(MultipartFile file) {
|
||||||
|
|
||||||
|
try {
|
||||||
|
List<AorestCoverageVO> Value = new ArrayList<>();
|
||||||
|
InputStream inputStream = file.getInputStream();
|
||||||
|
Workbook book;
|
||||||
|
Sheet sheet;
|
||||||
|
book = new XSSFWorkbook(inputStream);
|
||||||
|
sheet = book.getSheetAt(0);
|
||||||
|
for (int i = 1; i < sheet.getLastRowNum() + 1; i++) {
|
||||||
|
AorestCoverageVO value = new AorestCoverageVO();
|
||||||
|
Row row = sheet.getRow(i);
|
||||||
|
value.setRegion(row.getCell(0).toString());
|
||||||
|
value.setRegionEn(row.getCell(1).toString());
|
||||||
|
value.setProtectedLands(Double.parseDouble(row.getCell(2).toString()));
|
||||||
|
value.setNonProtectedLands(Double.parseDouble(row.getCell(3).toString()));
|
||||||
|
value.setMountain(Double.parseDouble(row.getCell(4).toString()));
|
||||||
|
value.setNonMountain(Double.parseDouble(row.getCell(5).toString()));
|
||||||
|
value.setCreateTime(LocalDateTime.now());
|
||||||
|
Value.add(value);
|
||||||
|
}
|
||||||
|
return Value;
|
||||||
|
} catch (IOException e) {
|
||||||
|
e.printStackTrace();
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private List<VegetationCoverageVO> saveExcelnpp(MultipartFile file) {
|
||||||
|
|
||||||
|
try {
|
||||||
|
List<VegetationCoverageVO> Value = new ArrayList<>();
|
||||||
|
InputStream inputStream = file.getInputStream();
|
||||||
|
Workbook book;
|
||||||
|
Sheet sheet;
|
||||||
|
book = new XSSFWorkbook(inputStream);
|
||||||
|
sheet = book.getSheetAt(0);
|
||||||
|
for (int i = 1; i < sheet.getLastRowNum() + 1; i++) {
|
||||||
|
VegetationCoverageVO value = new VegetationCoverageVO();
|
||||||
|
Row row = sheet.getRow(i);
|
||||||
|
value.setRegion(row.getCell(0).toString());
|
||||||
|
value.setRegionEn(row.getCell(1).toString());
|
||||||
|
value.setProtectedLands(Double.parseDouble(row.getCell(4).toString()));
|
||||||
|
value.setNonProtectedLands(Double.parseDouble(row.getCell(5).toString()));
|
||||||
|
value.setMountain(Double.parseDouble(row.getCell(2).toString()));
|
||||||
|
value.setNonMountain(Double.parseDouble(row.getCell(3).toString()));
|
||||||
|
value.setCreateTime(LocalDateTime.now());
|
||||||
|
Value.add(value);
|
||||||
|
}
|
||||||
|
return Value;
|
||||||
|
} catch (IOException e) {
|
||||||
|
e.printStackTrace();
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private List<RegionalSystemVO> saveExcelRegion(MultipartFile file) {
|
||||||
|
|
||||||
|
try {
|
||||||
|
List<RegionalSystemVO> Value = new ArrayList<>();
|
||||||
|
InputStream inputStream = file.getInputStream();
|
||||||
|
Workbook book;
|
||||||
|
Sheet sheet;
|
||||||
|
book = new XSSFWorkbook(inputStream);
|
||||||
|
sheet = book.getSheetAt(0);
|
||||||
|
for (int i = 1; i < sheet.getLastRowNum() + 1; i++) {
|
||||||
|
RegionalSystemVO value = new RegionalSystemVO();
|
||||||
|
Row row = sheet.getRow(i);
|
||||||
|
value.setRegion(row.getCell(0).toString());
|
||||||
|
value.setRegionEn(row.getCell(1).toString());
|
||||||
|
value.setTypeConversion(row.getCell(2).toString());
|
||||||
|
value.setTypeconversionEn(row.getCell(3).toString());
|
||||||
|
value.setProportionOfChangedAreas(Double.parseDouble(row.getCell(4).toString()));
|
||||||
|
value.setCreateTime(LocalDateTime.now());
|
||||||
|
Value.add(value);
|
||||||
|
}
|
||||||
|
return Value;
|
||||||
|
} catch (IOException e) {
|
||||||
|
e.printStackTrace();
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
@ -1,9 +0,0 @@
|
|||||||
package com.ruoyi.web.controller.yada;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 专题报告
|
|
||||||
* @Author: JinSheng Song
|
|
||||||
* @Date: 2022/5/11 11:10
|
|
||||||
*/
|
|
||||||
public class SpecialReportController {
|
|
||||||
}
|
|
@ -1,25 +1,32 @@
|
|||||||
package com.ruoyi.web.controller.yada;
|
package com.ruoyi.web.controller.yada;
|
||||||
|
|
||||||
|
import com.ruoyi.common.config.RuoYiConfig;
|
||||||
import com.ruoyi.common.core.domain.AjaxResult;
|
import com.ruoyi.common.core.domain.AjaxResult;
|
||||||
|
import com.ruoyi.common.utils.file.FileUploadUtils;
|
||||||
|
import com.ruoyi.common.utils.file.FileUtils;
|
||||||
import com.ruoyi.system.domain_yada.ThematicMapDomain;
|
import com.ruoyi.system.domain_yada.ThematicMapDomain;
|
||||||
import com.ruoyi.system.service_yada.ThematicMapService;
|
import com.ruoyi.system.service_yada.ThematicMapService;
|
||||||
|
import io.swagger.annotations.*;
|
||||||
import org.apache.ibatis.annotations.Param;
|
import org.apache.ibatis.annotations.Param;
|
||||||
|
import org.springframework.web.bind.annotation.RequestBody;
|
||||||
import org.springframework.web.bind.annotation.RequestMapping;
|
import org.springframework.web.bind.annotation.RequestMapping;
|
||||||
import org.springframework.web.bind.annotation.RequestMethod;
|
import org.springframework.web.bind.annotation.RequestMethod;
|
||||||
import org.springframework.web.bind.annotation.RestController;
|
import org.springframework.web.bind.annotation.RestController;
|
||||||
|
import org.springframework.web.multipart.MultipartFile;
|
||||||
|
|
||||||
import javax.annotation.Resource;
|
import javax.annotation.Resource;
|
||||||
import javax.servlet.http.HttpServletRequest;
|
import javax.servlet.http.HttpServletRequest;
|
||||||
import javax.servlet.http.HttpServletResponse;
|
import javax.servlet.http.HttpServletResponse;
|
||||||
|
import java.time.LocalDateTime;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 中国城市监测
|
* 专题图模块
|
||||||
* @Author: JinSheng Song
|
* @author taco chen
|
||||||
* @Date: 2022/5/11 10:55
|
|
||||||
*/
|
*/
|
||||||
@RestController
|
@RestController
|
||||||
@RequestMapping(value = "/thematic-map")
|
@RequestMapping(value = "/thematic-map")
|
||||||
|
@Api(tags = "专题图模块")
|
||||||
public class ThematicMapController {
|
public class ThematicMapController {
|
||||||
|
|
||||||
@Resource
|
@Resource
|
||||||
@ -27,23 +34,32 @@ public class ThematicMapController {
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* 查询方法
|
* 查询方法
|
||||||
* @param response
|
* @param response 响应头
|
||||||
* @param request
|
* @return 参数类
|
||||||
* @return
|
|
||||||
*/
|
*/
|
||||||
@RequestMapping(value = "/get/all",method = {RequestMethod.GET})
|
@ApiOperation("获取所有专题图")
|
||||||
public AjaxResult selectAllThematicMap(HttpServletResponse response, HttpServletRequest request)
|
@ApiImplicitParams({})
|
||||||
|
@ApiResponses({
|
||||||
|
@ApiResponse(code =200,message = "请求成功"),
|
||||||
|
@ApiResponse(code =401,message = "没有认证"),
|
||||||
|
@ApiResponse(code =403,message = "权限不足"),
|
||||||
|
@ApiResponse(code =404,message = "未找到")
|
||||||
|
})
|
||||||
|
@RequestMapping(value = "/get/all",method = {RequestMethod.POST})
|
||||||
|
public AjaxResult selectAllThematicMap(HttpServletResponse response,@RequestBody ThematicMapDomain thematicMapDomain)
|
||||||
{
|
{
|
||||||
List<ThematicMapDomain> res= thematicMapService.selectAll();
|
List<ThematicMapDomain> res= thematicMapService.selectAll(thematicMapDomain.getPictureType(),
|
||||||
|
thematicMapDomain.getPictureTypeOne(),thematicMapDomain.getPictureTypeTwo());
|
||||||
return AjaxResult.success(res);
|
return AjaxResult.success(res);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 删除方法
|
* 删除方法
|
||||||
* @param id
|
* @param id id
|
||||||
* @return
|
* @return 状态码
|
||||||
*/
|
*/
|
||||||
@RequestMapping(value = "/delete",method = {RequestMethod.DELETE})
|
@RequestMapping(value = "/delete",method = {RequestMethod.DELETE})
|
||||||
|
@ApiOperation(value = "删除方法",httpMethod = "DELETE")
|
||||||
|
@ApiImplicitParam(name = "userId", value = "用户ID", required = true, dataType = "long", paramType = "path", dataTypeClass = long.class)
|
||||||
public AjaxResult deleteThematicMap(@Param("id") Long id)
|
public AjaxResult deleteThematicMap(@Param("id") Long id)
|
||||||
{
|
{
|
||||||
int num = thematicMapService.deleteById(id);
|
int num = thematicMapService.deleteById(id);
|
||||||
@ -55,16 +71,22 @@ public class ThematicMapController {
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* 新增方法
|
* 新增方法
|
||||||
* @param thematicMapDomain
|
* @param thematicMapDomain 新增实体类
|
||||||
* @return
|
* @return 状态码
|
||||||
*/
|
*/
|
||||||
|
@ApiOperation(value = "新增方法",httpMethod = "POST")
|
||||||
@RequestMapping(value = "/add",method = {RequestMethod.POST})
|
@RequestMapping(value = "/add",method = {RequestMethod.POST})
|
||||||
public AjaxResult saveThematicMap(ThematicMapDomain thematicMapDomain)
|
public AjaxResult saveThematicMap(@RequestBody ThematicMapDomain thematicMapDomain)
|
||||||
{
|
{
|
||||||
|
|
||||||
|
|
||||||
|
thematicMapDomain.setCreatedTime(LocalDateTime.now());
|
||||||
int num = thematicMapService.save(thematicMapDomain);
|
int num = thematicMapService.save(thematicMapDomain);
|
||||||
if (num>0) {
|
if (num>0) {
|
||||||
return AjaxResult.success();
|
return AjaxResult.success();
|
||||||
}
|
}
|
||||||
return AjaxResult.error();
|
return AjaxResult.error();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -5,8 +5,12 @@ import com.ruoyi.system.domain_yada.AustraliaMiddleEastVO;
|
|||||||
import com.ruoyi.system.domain_yada.UrbanVO;
|
import com.ruoyi.system.domain_yada.UrbanVO;
|
||||||
import com.ruoyi.system.service_yada.IAustraliaMiddleEastService;
|
import com.ruoyi.system.service_yada.IAustraliaMiddleEastService;
|
||||||
import com.ruoyi.system.service_yada.IUrbanService;
|
import com.ruoyi.system.service_yada.IUrbanService;
|
||||||
|
import io.swagger.annotations.Api;
|
||||||
|
import io.swagger.annotations.ApiImplicitParam;
|
||||||
|
import io.swagger.annotations.ApiOperation;
|
||||||
import org.apache.ibatis.annotations.Param;
|
import org.apache.ibatis.annotations.Param;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.web.bind.annotation.RequestBody;
|
||||||
import org.springframework.web.bind.annotation.RequestMapping;
|
import org.springframework.web.bind.annotation.RequestMapping;
|
||||||
import org.springframework.web.bind.annotation.RequestMethod;
|
import org.springframework.web.bind.annotation.RequestMethod;
|
||||||
import org.springframework.web.bind.annotation.RestController;
|
import org.springframework.web.bind.annotation.RestController;
|
||||||
@ -14,13 +18,13 @@ import org.springframework.web.bind.annotation.RestController;
|
|||||||
import javax.annotation.Resource;
|
import javax.annotation.Resource;
|
||||||
import javax.servlet.http.HttpServletRequest;
|
import javax.servlet.http.HttpServletRequest;
|
||||||
import javax.servlet.http.HttpServletResponse;
|
import javax.servlet.http.HttpServletResponse;
|
||||||
|
import java.time.LocalDateTime;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 中国城市监测
|
* 中国城市监测
|
||||||
* @Author: JinSheng Song
|
|
||||||
* @Date: 2022/5/11 10:55
|
|
||||||
*/
|
*/
|
||||||
|
@Api(tags = "中国城市监测")
|
||||||
@RestController
|
@RestController
|
||||||
@RequestMapping(value = "/business-service/api/Urban", produces = "application/json;charset=UTF-8")
|
@RequestMapping(value = "/business-service/api/Urban", produces = "application/json;charset=UTF-8")
|
||||||
public class UrbanController {
|
public class UrbanController {
|
||||||
@ -29,23 +33,25 @@ public class UrbanController {
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* 查询方法
|
* 查询方法
|
||||||
* @param response
|
* @param response 响应头
|
||||||
* @param request
|
* @param request 客户端请求
|
||||||
* @return
|
* @return 参数类
|
||||||
*/
|
*/
|
||||||
@RequestMapping(value = "/selectUrban",method = {RequestMethod.POST})
|
@RequestMapping(value = "/selectUrban",method = {RequestMethod.GET})
|
||||||
public AjaxResult selectUrban(HttpServletResponse response, HttpServletRequest request)
|
@ApiOperation(value = "查询方法",httpMethod = "GET")
|
||||||
|
public AjaxResult selectUrban(HttpServletResponse response, HttpServletRequest request,@RequestBody UrbanVO urbanVO)
|
||||||
{
|
{
|
||||||
List<UrbanVO> eastVOSList= urbanService.selectUrban();
|
List<UrbanVO> eastVOSList= urbanService.selectUrban(urbanVO.getName(),urbanVO.getParticularYear());
|
||||||
return AjaxResult.success(eastVOSList);
|
return AjaxResult.success(eastVOSList);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 删除方法
|
* 删除方法
|
||||||
* @param ID
|
* @param ID id
|
||||||
* @return
|
* @return 状态码
|
||||||
*/
|
*/
|
||||||
@RequestMapping(value = "/DelUrban",method = {RequestMethod.POST})
|
@RequestMapping(value = "/DelUrban",method = {RequestMethod.DELETE})
|
||||||
|
@ApiOperation(value = "删除方法",httpMethod = "DELETE")
|
||||||
public AjaxResult DelUrban(@Param("ID") String ID)
|
public AjaxResult DelUrban(@Param("ID") String ID)
|
||||||
{
|
{
|
||||||
int NUM = urbanService.DelUrban(ID);
|
int NUM = urbanService.DelUrban(ID);
|
||||||
@ -59,12 +65,15 @@ public class UrbanController {
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* 新增方法
|
* 新增方法
|
||||||
* @param eastVOS
|
* @param eastVOS 新增实体类
|
||||||
* @return
|
* @return 状态码
|
||||||
*/
|
*/
|
||||||
|
@ApiOperation(value = "新增方法",httpMethod = "POST")
|
||||||
@RequestMapping(value = "/IntoUrban",method = {RequestMethod.POST})
|
@RequestMapping(value = "/IntoUrban",method = {RequestMethod.POST})
|
||||||
public AjaxResult IntoUrban(UrbanVO eastVOS)
|
@ApiImplicitParam(name = "userId", value = "用户ID", required = true, dataType = "long", paramType = "path", dataTypeClass = long.class)
|
||||||
|
public AjaxResult IntoUrban(@RequestBody UrbanVO eastVOS)
|
||||||
{
|
{
|
||||||
|
eastVOS.setCreateTime(LocalDateTime.now());
|
||||||
int NUM = urbanService.IntoUrban(eastVOS);
|
int NUM = urbanService.IntoUrban(eastVOS);
|
||||||
if (NUM>0)
|
if (NUM>0)
|
||||||
{
|
{
|
||||||
|
@ -5,8 +5,12 @@ import com.ruoyi.system.domain_yada.AustraliaMiddleEastVO;
|
|||||||
import com.ruoyi.system.domain_yada.VegetationCoverageVO;
|
import com.ruoyi.system.domain_yada.VegetationCoverageVO;
|
||||||
import com.ruoyi.system.service_yada.IAustraliaMiddleEastService;
|
import com.ruoyi.system.service_yada.IAustraliaMiddleEastService;
|
||||||
import com.ruoyi.system.service_yada.IVegetationCoverageService;
|
import com.ruoyi.system.service_yada.IVegetationCoverageService;
|
||||||
|
import io.swagger.annotations.Api;
|
||||||
|
import io.swagger.annotations.ApiImplicitParam;
|
||||||
|
import io.swagger.annotations.ApiOperation;
|
||||||
import org.apache.ibatis.annotations.Param;
|
import org.apache.ibatis.annotations.Param;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.web.bind.annotation.RequestBody;
|
||||||
import org.springframework.web.bind.annotation.RequestMapping;
|
import org.springframework.web.bind.annotation.RequestMapping;
|
||||||
import org.springframework.web.bind.annotation.RequestMethod;
|
import org.springframework.web.bind.annotation.RequestMethod;
|
||||||
import org.springframework.web.bind.annotation.RestController;
|
import org.springframework.web.bind.annotation.RestController;
|
||||||
@ -14,13 +18,13 @@ import org.springframework.web.bind.annotation.RestController;
|
|||||||
import javax.annotation.Resource;
|
import javax.annotation.Resource;
|
||||||
import javax.servlet.http.HttpServletRequest;
|
import javax.servlet.http.HttpServletRequest;
|
||||||
import javax.servlet.http.HttpServletResponse;
|
import javax.servlet.http.HttpServletResponse;
|
||||||
|
import java.time.LocalDateTime;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 平均植被覆盖度和净初级生产力
|
* 平均植被覆盖度和净初级生产力
|
||||||
* @Author: JinSheng Song
|
|
||||||
* @Date: 2022/5/11 10:56
|
|
||||||
*/
|
*/
|
||||||
|
@Api(tags = "平均植被覆盖度和净初级生产力")
|
||||||
@RestController
|
@RestController
|
||||||
@RequestMapping(value = "/business-service/api/Vegetation", produces = "application/json;charset=UTF-8")
|
@RequestMapping(value = "/business-service/api/Vegetation", produces = "application/json;charset=UTF-8")
|
||||||
public class VegetationCoverageController {
|
public class VegetationCoverageController {
|
||||||
@ -29,12 +33,11 @@ public class VegetationCoverageController {
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* 查询方法
|
* 查询方法
|
||||||
* @param response
|
* @return 参数类
|
||||||
* @param request
|
|
||||||
* @return
|
|
||||||
*/
|
*/
|
||||||
@RequestMapping(value = "/selectVegetation",method = {RequestMethod.POST})
|
@RequestMapping(value = "/selectVegetation",method = {RequestMethod.GET})
|
||||||
public AjaxResult selectVegetation(HttpServletResponse response, HttpServletRequest request)
|
@ApiOperation(value = "查询方法",httpMethod = "GET")
|
||||||
|
public AjaxResult selectVegetation()
|
||||||
{
|
{
|
||||||
List<VegetationCoverageVO> eastVOSList= coverageService.selectVegetation();
|
List<VegetationCoverageVO> eastVOSList= coverageService.selectVegetation();
|
||||||
return AjaxResult.success(eastVOSList);
|
return AjaxResult.success(eastVOSList);
|
||||||
@ -42,10 +45,12 @@ public class VegetationCoverageController {
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* 删除方法
|
* 删除方法
|
||||||
* @param ID
|
* @param ID id
|
||||||
* @return
|
* @return 状态码
|
||||||
*/
|
*/
|
||||||
@RequestMapping(value = "/DelVegetation",method = {RequestMethod.POST})
|
@RequestMapping(value = "/DelVegetation",method = {RequestMethod.DELETE})
|
||||||
|
@ApiOperation(value = "删除方法",httpMethod = "DELETE")
|
||||||
|
@ApiImplicitParam(name = "userId", value = "用户ID", required = true, dataType = "long", paramType = "path", dataTypeClass = long.class)
|
||||||
public AjaxResult DelVegetation(@Param("ID") String ID)
|
public AjaxResult DelVegetation(@Param("ID") String ID)
|
||||||
{
|
{
|
||||||
int NUM = coverageService.DelVegetation(ID);
|
int NUM = coverageService.DelVegetation(ID);
|
||||||
@ -59,12 +64,14 @@ public class VegetationCoverageController {
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* 新增方法
|
* 新增方法
|
||||||
* @param eastVOS
|
* @param eastVOS 新增实体类
|
||||||
* @return
|
* @return 状态码
|
||||||
*/
|
*/
|
||||||
|
@ApiOperation(value = "新增方法",httpMethod = "POST")
|
||||||
@RequestMapping(value = "/IntoVegetation",method = {RequestMethod.POST})
|
@RequestMapping(value = "/IntoVegetation",method = {RequestMethod.POST})
|
||||||
public AjaxResult IntoVegetation(VegetationCoverageVO eastVOS)
|
public AjaxResult IntoVegetation(@RequestBody VegetationCoverageVO eastVOS)
|
||||||
{
|
{
|
||||||
|
eastVOS.setCreateTime(LocalDateTime.now());
|
||||||
int NUM = coverageService.IntoVegetation(eastVOS);
|
int NUM = coverageService.IntoVegetation(eastVOS);
|
||||||
if (NUM>0)
|
if (NUM>0)
|
||||||
{
|
{
|
||||||
|
@ -0,0 +1 @@
|
|||||||
|
com.ruoyi.framework.web.service.CaptchaRedisService
|
@ -2,13 +2,17 @@
|
|||||||
spring:
|
spring:
|
||||||
datasource:
|
datasource:
|
||||||
type: com.alibaba.druid.pool.DruidDataSource
|
type: com.alibaba.druid.pool.DruidDataSource
|
||||||
driverClassName: com.mysql.cj.jdbc.Driver
|
# driverClassName: com.mysql.cj.jdbc.Driver
|
||||||
|
driver-class-name: org.postgresql.Driver
|
||||||
druid:
|
druid:
|
||||||
# 主库数据源
|
|
||||||
master:
|
master:
|
||||||
url: jdbc:mysql://192.168.2.9:3306/nuoyi?useUnicode=true&characterEncoding=UTF-8&useSSL=false&zeroDateTimeBehavior=convertToNull&useSSL=true&serverTimezone=GMT%2B8
|
#url: jdbc:postgresql://47.243.79.66:5432/yada?useUnicode=true&characterEncoding=UTF-8&allowMultiQueries=true&serverTimezone=Asia/Shanghai
|
||||||
username: saas
|
#url: jdbc:postgresql://192.168.2.9:5432/yada?useUnicode=true&characterEncoding=UTF-8&allowMultiQueries=true&serverTimezone=Asia/Shanghai
|
||||||
password: XKrs123.
|
# username: postgres
|
||||||
|
# password: postgres
|
||||||
|
url: jdbc:postgresql://118.195.242.28:5432/yada?AllowPublicKeyRetrieval=True&useUnicode=true&characterEncoding=UTF-8&useSSL=false&serverTimezone=Asia/Shanghai
|
||||||
|
username: gty
|
||||||
|
password: 308525
|
||||||
# 从库数据源
|
# 从库数据源
|
||||||
slave:
|
slave:
|
||||||
# 从数据源开关/默认关闭
|
# 从数据源开关/默认关闭
|
||||||
@ -30,8 +34,9 @@ spring:
|
|||||||
minEvictableIdleTimeMillis: 300000
|
minEvictableIdleTimeMillis: 300000
|
||||||
# 配置一个连接在池中最大生存的时间,单位是毫秒
|
# 配置一个连接在池中最大生存的时间,单位是毫秒
|
||||||
maxEvictableIdleTimeMillis: 900000
|
maxEvictableIdleTimeMillis: 900000
|
||||||
# 配置检测连接是否有效
|
# 配置检测连接是否有效select * from pg_stat_activity
|
||||||
validationQuery: SELECT 1 FROM DUAL
|
# validationQuery: SELECT 1 FROM DUAL
|
||||||
|
validationQuery: SELECT version()
|
||||||
testWhileIdle: true
|
testWhileIdle: true
|
||||||
testOnBorrow: false
|
testOnBorrow: false
|
||||||
testOnReturn: false
|
testOnReturn: false
|
||||||
|
@ -3,13 +3,13 @@ ruoyi:
|
|||||||
# 名称
|
# 名称
|
||||||
name: RuoYi
|
name: RuoYi
|
||||||
# 版本
|
# 版本
|
||||||
version: 3.8.2
|
version: 3.4.0
|
||||||
# 版权年份
|
# 版权年份
|
||||||
copyrightYear: 2022
|
copyrightYear: 2021
|
||||||
# 实例演示开关
|
# 实例演示开关
|
||||||
demoEnabled: true
|
demoEnabled: true
|
||||||
# 文件路径 示例( Windows配置D:/ruoyi/uploadPath,Linux配置 /home/ruoyi/uploadPath)
|
# 文件路径 示例( Windows配置D:/ruoyi/uploadPath,Linux配置 /home/ruoyi/uploadPath)
|
||||||
profile: D:/ruoyi/uploadPath
|
profile: /home/gty/ruoyi/uploadPath
|
||||||
# 获取ip地址开关
|
# 获取ip地址开关
|
||||||
addressEnabled: false
|
addressEnabled: false
|
||||||
# 验证码类型 math 数组计算 char 字符验证
|
# 验证码类型 math 数组计算 char 字符验证
|
||||||
@ -19,19 +19,17 @@ ruoyi:
|
|||||||
server:
|
server:
|
||||||
# 服务器的HTTP端口,默认为8080
|
# 服务器的HTTP端口,默认为8080
|
||||||
port: 8080
|
port: 8080
|
||||||
|
#port: 6061
|
||||||
servlet:
|
servlet:
|
||||||
# 应用的访问路径
|
# 应用的访问路径
|
||||||
context-path: /
|
context-path: /
|
||||||
tomcat:
|
tomcat:
|
||||||
# tomcat的URI编码
|
# tomcat的URI编码
|
||||||
uri-encoding: UTF-8
|
uri-encoding: UTF-8
|
||||||
# 连接数满后的排队数,默认为100
|
|
||||||
accept-count: 1000
|
|
||||||
threads:
|
|
||||||
# tomcat最大线程数,默认为200
|
# tomcat最大线程数,默认为200
|
||||||
max: 800
|
max-threads: 800
|
||||||
# Tomcat启动初始化的线程数,默认值10
|
# Tomcat启动初始化的线程数,默认值25
|
||||||
min-spare: 100
|
min-spare-threads: 30
|
||||||
|
|
||||||
# 日志配置
|
# 日志配置
|
||||||
logging:
|
logging:
|
||||||
@ -41,15 +39,12 @@ logging:
|
|||||||
|
|
||||||
# Spring配置
|
# Spring配置
|
||||||
spring:
|
spring:
|
||||||
# config:
|
|
||||||
# activate:
|
|
||||||
# on-profile: druid
|
|
||||||
profiles:
|
|
||||||
active: druid
|
|
||||||
# 资源信息
|
# 资源信息
|
||||||
messages:
|
messages:
|
||||||
# 国际化资源文件路径
|
# 国际化资源文件路径
|
||||||
basename: i18n/messages
|
basename: i18n/messages
|
||||||
|
profiles:
|
||||||
|
active: druid
|
||||||
# 文件上传
|
# 文件上传
|
||||||
servlet:
|
servlet:
|
||||||
multipart:
|
multipart:
|
||||||
@ -69,9 +64,9 @@ spring:
|
|||||||
# 端口,默认为6379
|
# 端口,默认为6379
|
||||||
port: 6379
|
port: 6379
|
||||||
# 数据库索引
|
# 数据库索引
|
||||||
database: 3
|
database: 0
|
||||||
# 密码
|
# 密码
|
||||||
password: sdust2020
|
password: '*&jkjusWETO(^ses%i'
|
||||||
# 连接超时时间
|
# 连接超时时间
|
||||||
timeout: 10s
|
timeout: 10s
|
||||||
lettuce:
|
lettuce:
|
||||||
@ -92,20 +87,21 @@ token:
|
|||||||
# 令牌密钥
|
# 令牌密钥
|
||||||
secret: abcdefghijklmnopqrstuvwxyz
|
secret: abcdefghijklmnopqrstuvwxyz
|
||||||
# 令牌有效期(默认30分钟)
|
# 令牌有效期(默认30分钟)
|
||||||
expireTime: 30
|
expireTime: 300
|
||||||
|
|
||||||
# MyBatis配置
|
# MyBatis配置
|
||||||
mybatis:
|
mybatis:
|
||||||
# 搜索指定包别名
|
# 搜索指定包别名
|
||||||
typeAliasesPackage: com.ruoyi.**.domain,com.ruoyi.**.domain_yada
|
typeAliasesPackage: com.ruoyi.**.domain
|
||||||
# 配置mapper的扫描,找到所有的mapper.xml映射文件
|
# 配置mapper的扫描,找到所有的mapper.xml映射文件
|
||||||
mapperLocations: classpath*:mapper/**/*Mapper.xml,classpath*:mapper_yada/*Mapper.xml
|
mapperLocations: classpath*:mapper/**/*Mapper.xml
|
||||||
# 加载全局的配置文件
|
# 加载全局的配置文件
|
||||||
configLocation: classpath:mybatis/mybatis-config.xml
|
configLocation: classpath:mybatis/mybatis-config.xml
|
||||||
|
|
||||||
# PageHelper分页插件
|
# PageHelper分页插件
|
||||||
pagehelper:
|
pagehelper:
|
||||||
helperDialect: mysql
|
helperDialect: mysql
|
||||||
|
reasonable: true
|
||||||
supportMethodsArguments: true
|
supportMethodsArguments: true
|
||||||
params: count=countSql
|
params: count=countSql
|
||||||
|
|
||||||
@ -116,12 +112,27 @@ swagger:
|
|||||||
# 请求前缀
|
# 请求前缀
|
||||||
pathMapping: /dev-api
|
pathMapping: /dev-api
|
||||||
|
|
||||||
|
# 滑块验证码
|
||||||
|
aj:
|
||||||
|
captcha:
|
||||||
|
cache-type: redis
|
||||||
|
# blockPuzzle 滑块 clickWord 文字点选 default默认两者都实例化
|
||||||
|
type: blockPuzzle
|
||||||
|
# 右下角显示字
|
||||||
|
water-mark: ruoyi.vip
|
||||||
|
# 校验滑动拼图允许误差偏移量(默认5像素)
|
||||||
|
slip-offset: 5
|
||||||
|
# aes加密坐标开启或者禁用(true|false)
|
||||||
|
aes-status: true
|
||||||
|
# 滑动干扰项(0/1/2)
|
||||||
|
interference-options: 2
|
||||||
|
|
||||||
# 防止XSS攻击
|
# 防止XSS攻击
|
||||||
xss:
|
xss:
|
||||||
# 过滤开关
|
# 过滤开关
|
||||||
enabled: true
|
enabled: true
|
||||||
# 排除链接(多个用逗号分隔)
|
# 排除链接(多个用逗号分隔)
|
||||||
excludes: /system/notice
|
excludes: /system/notice/*
|
||||||
# 匹配链接
|
# 匹配链接
|
||||||
urlPatterns: /system/*,/monitor/*,/tool/*
|
urlPatterns: /system/*,/monitor/*,/tool/*
|
||||||
|
|
||||||
|
@ -1,24 +1,6 @@
|
|||||||
Application Version: ${ruoyi.version}
|
_
|
||||||
Spring Boot Version: ${spring-boot.version}
|
( )
|
||||||
////////////////////////////////////////////////////////////////////
|
| |/') _ __ ___
|
||||||
// _ooOoo_ //
|
(`\/')| , < ( '__)/',__)
|
||||||
// o6666666o //
|
> < | |\`\ | | \__, \
|
||||||
// 88" . "88 //
|
(_/\_)(_) (_)(_) (____/
|
||||||
// (| ^_^ |) //
|
|
||||||
// O\ = /O //
|
|
||||||
// ____/`---'\____ //
|
|
||||||
// .' \\| |// `. //
|
|
||||||
// / \\||| : |||// \ //
|
|
||||||
// / _||||| -:- |||||- \ //
|
|
||||||
// | | \\\ - /// | | //
|
|
||||||
// | \_| ''\---/'' | | //
|
|
||||||
// \ .-\__ `-` ___/-. / //
|
|
||||||
// ___`. .' /--.--\ `. . ___ //
|
|
||||||
// ."" '< `.___\_<|>_/___.' >'"". //
|
|
||||||
// | | : `- \`.;`\ _ /`;.`/ - ` : | | //
|
|
||||||
// \ \ `-. \_ __\ /__ _/ .-` / / //
|
|
||||||
// ========`-.____`-.___\_____/___.-`____.-'======== //
|
|
||||||
// `=---=' //
|
|
||||||
// ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ //
|
|
||||||
// 佛祖保佑 永不宕机 永无BUG //
|
|
||||||
////////////////////////////////////////////////////////////////////
|
|
@ -0,0 +1,66 @@
|
|||||||
|
package com.ruoyi.common.utils.file;
|
||||||
|
|
||||||
|
import javax.servlet.http.HttpServletRequest;
|
||||||
|
import javax.servlet.http.HttpServletResponse;
|
||||||
|
import java.io.*;
|
||||||
|
import java.net.*;
|
||||||
|
import java.util.Map;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @Author: JinSheng Song
|
||||||
|
* @Date: 2022/6/10 9:17
|
||||||
|
*/
|
||||||
|
public class WeatherUtils
|
||||||
|
{
|
||||||
|
|
||||||
|
|
||||||
|
public static String httpRequest(String requestUrl,Map params) {
|
||||||
|
//buffer用于接受返回的字符
|
||||||
|
StringBuffer buffer = new StringBuffer();
|
||||||
|
try {
|
||||||
|
//建立URL,把请求地址给补全,其中urlencode()方法用于把params里的参数给取出来
|
||||||
|
URL url = new URL(requestUrl+"?"+urlencode(params));
|
||||||
|
//打开http连接
|
||||||
|
HttpURLConnection httpUrlConn = (HttpURLConnection) url.openConnection();
|
||||||
|
httpUrlConn.setDoInput(true);
|
||||||
|
httpUrlConn.setRequestMethod("GET");
|
||||||
|
httpUrlConn.connect();
|
||||||
|
|
||||||
|
//获得输入
|
||||||
|
InputStream inputStream = httpUrlConn.getInputStream();
|
||||||
|
InputStreamReader inputStreamReader = new InputStreamReader(inputStream, "utf-8");
|
||||||
|
BufferedReader bufferedReader = new BufferedReader(inputStreamReader);
|
||||||
|
|
||||||
|
//将bufferReader的值给放到buffer里
|
||||||
|
String str = null;
|
||||||
|
while ((str = bufferedReader.readLine()) != null) {
|
||||||
|
buffer.append(str);
|
||||||
|
}
|
||||||
|
//关闭bufferReader和输入流
|
||||||
|
bufferedReader.close();
|
||||||
|
inputStreamReader.close();
|
||||||
|
inputStream.close();
|
||||||
|
inputStream = null;
|
||||||
|
//断开连接
|
||||||
|
httpUrlConn.disconnect();
|
||||||
|
|
||||||
|
} catch (Exception e) {
|
||||||
|
e.printStackTrace();
|
||||||
|
}
|
||||||
|
//返回字符串
|
||||||
|
return buffer.toString();
|
||||||
|
}
|
||||||
|
|
||||||
|
public static String urlencode(Map<String,Object>data) {
|
||||||
|
//将map里的参数变成像 showapi_appid=###&showapi_sign=###&的样子
|
||||||
|
StringBuilder sb = new StringBuilder();
|
||||||
|
for (Map.Entry i : data.entrySet()) {
|
||||||
|
try {
|
||||||
|
sb.append(i.getKey()).append("=").append(URLEncoder.encode(i.getValue()+"","UTF-8")).append("&");
|
||||||
|
} catch (UnsupportedEncodingException e) {
|
||||||
|
e.printStackTrace();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return sb.toString();
|
||||||
|
}
|
||||||
|
}
|
@ -35,18 +35,26 @@
|
|||||||
<artifactId>druid-spring-boot-starter</artifactId>
|
<artifactId>druid-spring-boot-starter</artifactId>
|
||||||
</dependency>
|
</dependency>
|
||||||
|
|
||||||
<!-- 验证码 -->
|
|
||||||
|
<!-- 滑块验证码-->
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>com.github.penggle</groupId>
|
<groupId>com.github.anji-plus</groupId>
|
||||||
<artifactId>kaptcha</artifactId>
|
<artifactId>captcha-spring-boot-starter</artifactId>
|
||||||
<exclusions>
|
<version>1.2.7</version>
|
||||||
<exclusion>
|
|
||||||
<artifactId>javax.servlet-api</artifactId>
|
|
||||||
<groupId>javax.servlet</groupId>
|
|
||||||
</exclusion>
|
|
||||||
</exclusions>
|
|
||||||
</dependency>
|
</dependency>
|
||||||
|
|
||||||
|
<!-- 验证码 -->
|
||||||
|
<!-- <dependency>-->
|
||||||
|
<!-- <groupId>com.github.penggle</groupId>-->
|
||||||
|
<!-- <artifactId>kaptcha</artifactId>-->
|
||||||
|
<!-- <exclusions>-->
|
||||||
|
<!-- <exclusion>-->
|
||||||
|
<!-- <artifactId>javax.servlet-api</artifactId>-->
|
||||||
|
<!-- <groupId>javax.servlet</groupId>-->
|
||||||
|
<!-- </exclusion>-->
|
||||||
|
<!-- </exclusions>-->
|
||||||
|
<!-- </dependency>-->
|
||||||
|
|
||||||
<!-- 获取系统信息 -->
|
<!-- 获取系统信息 -->
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>com.github.oshi</groupId>
|
<groupId>com.github.oshi</groupId>
|
||||||
|
@ -1,83 +0,0 @@
|
|||||||
package com.ruoyi.framework.config;
|
|
||||||
|
|
||||||
import java.util.Properties;
|
|
||||||
import org.springframework.context.annotation.Bean;
|
|
||||||
import org.springframework.context.annotation.Configuration;
|
|
||||||
import com.google.code.kaptcha.impl.DefaultKaptcha;
|
|
||||||
import com.google.code.kaptcha.util.Config;
|
|
||||||
import static com.google.code.kaptcha.Constants.*;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 验证码配置
|
|
||||||
*
|
|
||||||
* @author ruoyi
|
|
||||||
*/
|
|
||||||
@Configuration
|
|
||||||
public class CaptchaConfig
|
|
||||||
{
|
|
||||||
@Bean(name = "captchaProducer")
|
|
||||||
public DefaultKaptcha getKaptchaBean()
|
|
||||||
{
|
|
||||||
DefaultKaptcha defaultKaptcha = new DefaultKaptcha();
|
|
||||||
Properties properties = new Properties();
|
|
||||||
// 是否有边框 默认为true 我们可以自己设置yes,no
|
|
||||||
properties.setProperty(KAPTCHA_BORDER, "yes");
|
|
||||||
// 验证码文本字符颜色 默认为Color.BLACK
|
|
||||||
properties.setProperty(KAPTCHA_TEXTPRODUCER_FONT_COLOR, "black");
|
|
||||||
// 验证码图片宽度 默认为200
|
|
||||||
properties.setProperty(KAPTCHA_IMAGE_WIDTH, "160");
|
|
||||||
// 验证码图片高度 默认为50
|
|
||||||
properties.setProperty(KAPTCHA_IMAGE_HEIGHT, "60");
|
|
||||||
// 验证码文本字符大小 默认为40
|
|
||||||
properties.setProperty(KAPTCHA_TEXTPRODUCER_FONT_SIZE, "38");
|
|
||||||
// KAPTCHA_SESSION_KEY
|
|
||||||
properties.setProperty(KAPTCHA_SESSION_CONFIG_KEY, "kaptchaCode");
|
|
||||||
// 验证码文本字符长度 默认为5
|
|
||||||
properties.setProperty(KAPTCHA_TEXTPRODUCER_CHAR_LENGTH, "4");
|
|
||||||
// 验证码文本字体样式 默认为new Font("Arial", 1, fontSize), new Font("Courier", 1, fontSize)
|
|
||||||
properties.setProperty(KAPTCHA_TEXTPRODUCER_FONT_NAMES, "Arial,Courier");
|
|
||||||
// 图片样式 水纹com.google.code.kaptcha.impl.WaterRipple 鱼眼com.google.code.kaptcha.impl.FishEyeGimpy 阴影com.google.code.kaptcha.impl.ShadowGimpy
|
|
||||||
properties.setProperty(KAPTCHA_OBSCURIFICATOR_IMPL, "com.google.code.kaptcha.impl.ShadowGimpy");
|
|
||||||
Config config = new Config(properties);
|
|
||||||
defaultKaptcha.setConfig(config);
|
|
||||||
return defaultKaptcha;
|
|
||||||
}
|
|
||||||
|
|
||||||
@Bean(name = "captchaProducerMath")
|
|
||||||
public DefaultKaptcha getKaptchaBeanMath()
|
|
||||||
{
|
|
||||||
DefaultKaptcha defaultKaptcha = new DefaultKaptcha();
|
|
||||||
Properties properties = new Properties();
|
|
||||||
// 是否有边框 默认为true 我们可以自己设置yes,no
|
|
||||||
properties.setProperty(KAPTCHA_BORDER, "yes");
|
|
||||||
// 边框颜色 默认为Color.BLACK
|
|
||||||
properties.setProperty(KAPTCHA_BORDER_COLOR, "105,179,90");
|
|
||||||
// 验证码文本字符颜色 默认为Color.BLACK
|
|
||||||
properties.setProperty(KAPTCHA_TEXTPRODUCER_FONT_COLOR, "blue");
|
|
||||||
// 验证码图片宽度 默认为200
|
|
||||||
properties.setProperty(KAPTCHA_IMAGE_WIDTH, "160");
|
|
||||||
// 验证码图片高度 默认为50
|
|
||||||
properties.setProperty(KAPTCHA_IMAGE_HEIGHT, "60");
|
|
||||||
// 验证码文本字符大小 默认为40
|
|
||||||
properties.setProperty(KAPTCHA_TEXTPRODUCER_FONT_SIZE, "35");
|
|
||||||
// KAPTCHA_SESSION_KEY
|
|
||||||
properties.setProperty(KAPTCHA_SESSION_CONFIG_KEY, "kaptchaCodeMath");
|
|
||||||
// 验证码文本生成器
|
|
||||||
properties.setProperty(KAPTCHA_TEXTPRODUCER_IMPL, "com.ruoyi.framework.config.KaptchaTextCreator");
|
|
||||||
// 验证码文本字符间距 默认为2
|
|
||||||
properties.setProperty(KAPTCHA_TEXTPRODUCER_CHAR_SPACE, "3");
|
|
||||||
// 验证码文本字符长度 默认为5
|
|
||||||
properties.setProperty(KAPTCHA_TEXTPRODUCER_CHAR_LENGTH, "6");
|
|
||||||
// 验证码文本字体样式 默认为new Font("Arial", 1, fontSize), new Font("Courier", 1, fontSize)
|
|
||||||
properties.setProperty(KAPTCHA_TEXTPRODUCER_FONT_NAMES, "Arial,Courier");
|
|
||||||
// 验证码噪点颜色 默认为Color.BLACK
|
|
||||||
properties.setProperty(KAPTCHA_NOISE_COLOR, "white");
|
|
||||||
// 干扰实现类
|
|
||||||
properties.setProperty(KAPTCHA_NOISE_IMPL, "com.google.code.kaptcha.impl.NoNoise");
|
|
||||||
// 图片样式 水纹com.google.code.kaptcha.impl.WaterRipple 鱼眼com.google.code.kaptcha.impl.FishEyeGimpy 阴影com.google.code.kaptcha.impl.ShadowGimpy
|
|
||||||
properties.setProperty(KAPTCHA_OBSCURIFICATOR_IMPL, "com.google.code.kaptcha.impl.ShadowGimpy");
|
|
||||||
Config config = new Config(properties);
|
|
||||||
defaultKaptcha.setConfig(config);
|
|
||||||
return defaultKaptcha;
|
|
||||||
}
|
|
||||||
}
|
|
@ -1,75 +0,0 @@
|
|||||||
package com.ruoyi.framework.config;
|
|
||||||
|
|
||||||
import java.util.Random;
|
|
||||||
import com.google.code.kaptcha.text.impl.DefaultTextCreator;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 验证码文本生成器
|
|
||||||
*
|
|
||||||
* @author ruoyi
|
|
||||||
*/
|
|
||||||
public class KaptchaTextCreator extends DefaultTextCreator
|
|
||||||
{
|
|
||||||
private static final String[] CNUMBERS = "0,1,2,3,4,5,6,7,8,9,10".split(",");
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public String getText()
|
|
||||||
{
|
|
||||||
Integer result = 0;
|
|
||||||
Random random = new Random();
|
|
||||||
int x = random.nextInt(10);
|
|
||||||
int y = random.nextInt(10);
|
|
||||||
StringBuilder suChinese = new StringBuilder();
|
|
||||||
int randomoperands = (int) Math.round(Math.random() * 2);
|
|
||||||
if (randomoperands == 0)
|
|
||||||
{
|
|
||||||
result = x * y;
|
|
||||||
suChinese.append(CNUMBERS[x]);
|
|
||||||
suChinese.append("*");
|
|
||||||
suChinese.append(CNUMBERS[y]);
|
|
||||||
}
|
|
||||||
else if (randomoperands == 1)
|
|
||||||
{
|
|
||||||
if (!(x == 0) && y % x == 0)
|
|
||||||
{
|
|
||||||
result = y / x;
|
|
||||||
suChinese.append(CNUMBERS[y]);
|
|
||||||
suChinese.append("/");
|
|
||||||
suChinese.append(CNUMBERS[x]);
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
result = x + y;
|
|
||||||
suChinese.append(CNUMBERS[x]);
|
|
||||||
suChinese.append("+");
|
|
||||||
suChinese.append(CNUMBERS[y]);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
else if (randomoperands == 2)
|
|
||||||
{
|
|
||||||
if (x >= y)
|
|
||||||
{
|
|
||||||
result = x - y;
|
|
||||||
suChinese.append(CNUMBERS[x]);
|
|
||||||
suChinese.append("-");
|
|
||||||
suChinese.append(CNUMBERS[y]);
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
result = y - x;
|
|
||||||
suChinese.append(CNUMBERS[y]);
|
|
||||||
suChinese.append("-");
|
|
||||||
suChinese.append(CNUMBERS[x]);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
result = x + y;
|
|
||||||
suChinese.append(CNUMBERS[x]);
|
|
||||||
suChinese.append("+");
|
|
||||||
suChinese.append(CNUMBERS[y]);
|
|
||||||
}
|
|
||||||
suChinese.append("=?@" + result);
|
|
||||||
return suChinese.toString();
|
|
||||||
}
|
|
||||||
}
|
|
@ -97,7 +97,8 @@ public class SecurityConfig extends WebSecurityConfigurerAdapter
|
|||||||
// 过滤请求
|
// 过滤请求
|
||||||
.authorizeRequests()
|
.authorizeRequests()
|
||||||
// 对于登录login 注册register 验证码captchaImage 允许匿名访问
|
// 对于登录login 注册register 验证码captchaImage 允许匿名访问
|
||||||
.antMatchers("/login", "/register", "/captchaImage").anonymous()
|
// .antMatchers("/login", "/register", "/captchaImage").anonymous()
|
||||||
|
.antMatchers("/login", "/register", "/captcha/get", "/captcha/check").permitAll()
|
||||||
.antMatchers(
|
.antMatchers(
|
||||||
HttpMethod.GET,
|
HttpMethod.GET,
|
||||||
"/",
|
"/",
|
||||||
@ -110,6 +111,7 @@ public class SecurityConfig extends WebSecurityConfigurerAdapter
|
|||||||
.antMatchers("/swagger-ui.html").anonymous()
|
.antMatchers("/swagger-ui.html").anonymous()
|
||||||
.antMatchers("/swagger-resources/**").anonymous()
|
.antMatchers("/swagger-resources/**").anonymous()
|
||||||
.antMatchers("/webjars/**").anonymous()
|
.antMatchers("/webjars/**").anonymous()
|
||||||
|
.antMatchers("/login", "/captcha/get", "/captcha/check").permitAll()
|
||||||
.antMatchers("/*/api-docs").anonymous()
|
.antMatchers("/*/api-docs").anonymous()
|
||||||
.antMatchers("/druid/**").anonymous()
|
.antMatchers("/druid/**").anonymous()
|
||||||
// 除上面外的所有请求全部需要鉴权认证
|
// 除上面外的所有请求全部需要鉴权认证
|
||||||
|
@ -0,0 +1,53 @@
|
|||||||
|
package com.ruoyi.framework.web.service;
|
||||||
|
|
||||||
|
import java.util.concurrent.TimeUnit;
|
||||||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.data.redis.core.StringRedisTemplate;
|
||||||
|
import com.anji.captcha.service.CaptchaCacheService;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 自定义redis验证码缓存实现类
|
||||||
|
*
|
||||||
|
* @author ruoyi
|
||||||
|
*/
|
||||||
|
public class CaptchaRedisService implements CaptchaCacheService
|
||||||
|
{
|
||||||
|
@Autowired
|
||||||
|
private StringRedisTemplate stringRedisTemplate;
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void set(String key, String value, long expiresInSeconds)
|
||||||
|
{
|
||||||
|
stringRedisTemplate.opsForValue().set(key, value, expiresInSeconds, TimeUnit.SECONDS);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public boolean exists(String key)
|
||||||
|
{
|
||||||
|
return stringRedisTemplate.hasKey(key);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void delete(String key)
|
||||||
|
{
|
||||||
|
stringRedisTemplate.delete(key);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public String get(String key)
|
||||||
|
{
|
||||||
|
return stringRedisTemplate.opsForValue().get(key);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public Long increment(String key, long val)
|
||||||
|
{
|
||||||
|
return stringRedisTemplate.opsForValue().increment(key, val);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public String type()
|
||||||
|
{
|
||||||
|
return "redis";
|
||||||
|
}
|
||||||
|
}
|
@ -2,27 +2,27 @@ package com.ruoyi.framework.web.service;
|
|||||||
|
|
||||||
import javax.annotation.Resource;
|
import javax.annotation.Resource;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.context.annotation.Lazy;
|
||||||
import org.springframework.security.authentication.AuthenticationManager;
|
import org.springframework.security.authentication.AuthenticationManager;
|
||||||
import org.springframework.security.authentication.BadCredentialsException;
|
import org.springframework.security.authentication.BadCredentialsException;
|
||||||
import org.springframework.security.authentication.UsernamePasswordAuthenticationToken;
|
import org.springframework.security.authentication.UsernamePasswordAuthenticationToken;
|
||||||
import org.springframework.security.core.Authentication;
|
import org.springframework.security.core.Authentication;
|
||||||
import org.springframework.stereotype.Component;
|
import org.springframework.stereotype.Component;
|
||||||
|
import com.anji.captcha.model.common.ResponseModel;
|
||||||
|
import com.anji.captcha.model.vo.CaptchaVO;
|
||||||
|
import com.anji.captcha.service.CaptchaService;
|
||||||
import com.ruoyi.common.constant.Constants;
|
import com.ruoyi.common.constant.Constants;
|
||||||
import com.ruoyi.common.core.domain.entity.SysUser;
|
import com.ruoyi.common.core.domain.entity.SysUser;
|
||||||
import com.ruoyi.common.core.domain.model.LoginUser;
|
import com.ruoyi.common.core.domain.model.LoginUser;
|
||||||
import com.ruoyi.common.core.redis.RedisCache;
|
|
||||||
import com.ruoyi.common.exception.ServiceException;
|
import com.ruoyi.common.exception.ServiceException;
|
||||||
import com.ruoyi.common.exception.user.CaptchaException;
|
import com.ruoyi.common.exception.user.CaptchaException;
|
||||||
import com.ruoyi.common.exception.user.CaptchaExpireException;
|
|
||||||
import com.ruoyi.common.exception.user.UserPasswordNotMatchException;
|
import com.ruoyi.common.exception.user.UserPasswordNotMatchException;
|
||||||
import com.ruoyi.common.utils.DateUtils;
|
import com.ruoyi.common.utils.DateUtils;
|
||||||
import com.ruoyi.common.utils.MessageUtils;
|
import com.ruoyi.common.utils.MessageUtils;
|
||||||
import com.ruoyi.common.utils.StringUtils;
|
|
||||||
import com.ruoyi.common.utils.ServletUtils;
|
import com.ruoyi.common.utils.ServletUtils;
|
||||||
import com.ruoyi.common.utils.ip.IpUtils;
|
import com.ruoyi.common.utils.ip.IpUtils;
|
||||||
import com.ruoyi.framework.manager.AsyncManager;
|
import com.ruoyi.framework.manager.AsyncManager;
|
||||||
import com.ruoyi.framework.manager.factory.AsyncFactory;
|
import com.ruoyi.framework.manager.factory.AsyncFactory;
|
||||||
import com.ruoyi.system.service.ISysConfigService;
|
|
||||||
import com.ruoyi.system.service.ISysUserService;
|
import com.ruoyi.system.service.ISysUserService;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -39,14 +39,12 @@ public class SysLoginService
|
|||||||
@Resource
|
@Resource
|
||||||
private AuthenticationManager authenticationManager;
|
private AuthenticationManager authenticationManager;
|
||||||
|
|
||||||
@Autowired
|
|
||||||
private RedisCache redisCache;
|
|
||||||
|
|
||||||
@Autowired
|
@Autowired
|
||||||
private ISysUserService userService;
|
private ISysUserService userService;
|
||||||
|
|
||||||
@Autowired
|
@Autowired
|
||||||
private ISysConfigService configService;
|
@Lazy
|
||||||
|
private CaptchaService captchaService;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 登录验证
|
* 登录验证
|
||||||
@ -54,16 +52,18 @@ public class SysLoginService
|
|||||||
* @param username 用户名
|
* @param username 用户名
|
||||||
* @param password 密码
|
* @param password 密码
|
||||||
* @param code 验证码
|
* @param code 验证码
|
||||||
* @param uuid 唯一标识
|
|
||||||
* @return 结果
|
* @return 结果
|
||||||
*/
|
*/
|
||||||
public String login(String username, String password, String code, String uuid)
|
public String login(String username, String password, String code)
|
||||||
{
|
{
|
||||||
boolean captchaOnOff = configService.selectCaptchaOnOff();
|
CaptchaVO captchaVO = new CaptchaVO();
|
||||||
// 验证码开关
|
captchaVO.setCaptchaVerification(code);
|
||||||
if (captchaOnOff)
|
ResponseModel response = captchaService.verification(captchaVO);
|
||||||
|
if (!response.isSuccess())
|
||||||
{
|
{
|
||||||
validateCaptcha(username, code, uuid);
|
AsyncManager.me().execute(AsyncFactory.recordLogininfor(username, Constants.LOGIN_FAIL,
|
||||||
|
MessageUtils.message("user.jcaptcha.error")));
|
||||||
|
throw new CaptchaException();
|
||||||
}
|
}
|
||||||
// 用户验证
|
// 用户验证
|
||||||
Authentication authentication = null;
|
Authentication authentication = null;
|
||||||
@ -88,36 +88,10 @@ public class SysLoginService
|
|||||||
}
|
}
|
||||||
AsyncManager.me().execute(AsyncFactory.recordLogininfor(username, Constants.LOGIN_SUCCESS, MessageUtils.message("user.login.success")));
|
AsyncManager.me().execute(AsyncFactory.recordLogininfor(username, Constants.LOGIN_SUCCESS, MessageUtils.message("user.login.success")));
|
||||||
LoginUser loginUser = (LoginUser) authentication.getPrincipal();
|
LoginUser loginUser = (LoginUser) authentication.getPrincipal();
|
||||||
recordLoginInfo(loginUser.getUserId());
|
|
||||||
// 生成token
|
// 生成token
|
||||||
return tokenService.createToken(loginUser);
|
return tokenService.createToken(loginUser);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* 校验验证码
|
|
||||||
*
|
|
||||||
* @param username 用户名
|
|
||||||
* @param code 验证码
|
|
||||||
* @param uuid 唯一标识
|
|
||||||
* @return 结果
|
|
||||||
*/
|
|
||||||
public void validateCaptcha(String username, String code, String uuid)
|
|
||||||
{
|
|
||||||
String verifyKey = Constants.CAPTCHA_CODE_KEY + StringUtils.nvl(uuid, "");
|
|
||||||
String captcha = redisCache.getCacheObject(verifyKey);
|
|
||||||
redisCache.deleteObject(verifyKey);
|
|
||||||
if (captcha == null)
|
|
||||||
{
|
|
||||||
AsyncManager.me().execute(AsyncFactory.recordLogininfor(username, Constants.LOGIN_FAIL, MessageUtils.message("user.jcaptcha.expire")));
|
|
||||||
throw new CaptchaExpireException();
|
|
||||||
}
|
|
||||||
if (!code.equalsIgnoreCase(captcha))
|
|
||||||
{
|
|
||||||
AsyncManager.me().execute(AsyncFactory.recordLogininfor(username, Constants.LOGIN_FAIL, MessageUtils.message("user.jcaptcha.error")));
|
|
||||||
throw new CaptchaException();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 记录登录信息
|
* 记录登录信息
|
||||||
*
|
*
|
||||||
|
@ -41,12 +41,12 @@ public class SysRegisterService
|
|||||||
{
|
{
|
||||||
String msg = "", username = registerBody.getUsername(), password = registerBody.getPassword();
|
String msg = "", username = registerBody.getUsername(), password = registerBody.getPassword();
|
||||||
|
|
||||||
boolean captchaOnOff = configService.selectCaptchaOnOff();
|
// boolean captchaOnOff = configService.selectCaptchaOnOff();
|
||||||
// 验证码开关
|
// // 验证码开关
|
||||||
if (captchaOnOff)
|
// if (captchaOnOff)
|
||||||
{
|
// {
|
||||||
validateCaptcha(username, registerBody.getCode(), registerBody.getUuid());
|
// validateCaptcha(username, registerBody.getCode(), registerBody.getUuid());
|
||||||
}
|
// }
|
||||||
|
|
||||||
if (StringUtils.isEmpty(username))
|
if (StringUtils.isEmpty(username))
|
||||||
{
|
{
|
||||||
@ -56,16 +56,16 @@ public class SysRegisterService
|
|||||||
{
|
{
|
||||||
msg = "用户密码不能为空";
|
msg = "用户密码不能为空";
|
||||||
}
|
}
|
||||||
else if (username.length() < UserConstants.USERNAME_MIN_LENGTH
|
// else if (username.length() < UserConstants.USERNAME_MIN_LENGTH
|
||||||
|| username.length() > UserConstants.USERNAME_MAX_LENGTH)
|
// || username.length() > UserConstants.USERNAME_MAX_LENGTH)
|
||||||
{
|
// {
|
||||||
msg = "账户长度必须在2到20个字符之间";
|
// msg = "账户长度必须在2到20个字符之间";
|
||||||
}
|
// }
|
||||||
else if (password.length() < UserConstants.PASSWORD_MIN_LENGTH
|
// else if (password.length() < UserConstants.PASSWORD_MIN_LENGTH
|
||||||
|| password.length() > UserConstants.PASSWORD_MAX_LENGTH)
|
// || password.length() > UserConstants.PASSWORD_MAX_LENGTH)
|
||||||
{
|
// {
|
||||||
msg = "密码长度必须在5到20个字符之间";
|
// msg = "密码长度必须在5到20个字符之间";
|
||||||
}
|
// }
|
||||||
else if (UserConstants.NOT_UNIQUE.equals(userService.checkUserNameUnique(username)))
|
else if (UserConstants.NOT_UNIQUE.equals(userService.checkUserNameUnique(username)))
|
||||||
{
|
{
|
||||||
msg = "保存用户'" + username + "'失败,注册账号已存在";
|
msg = "保存用户'" + username + "'失败,注册账号已存在";
|
||||||
@ -89,7 +89,6 @@ public class SysRegisterService
|
|||||||
}
|
}
|
||||||
return msg;
|
return msg;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 校验验证码
|
* 校验验证码
|
||||||
*
|
*
|
||||||
|
@ -85,7 +85,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||||||
<if test="dictType != null and dictType != ''">#{dictType},</if>
|
<if test="dictType != null and dictType != ''">#{dictType},</if>
|
||||||
<if test="sort != null">#{sort},</if>
|
<if test="sort != null">#{sort},</if>
|
||||||
<if test="createBy != null and createBy != ''">#{createBy},</if>
|
<if test="createBy != null and createBy != ''">#{createBy},</if>
|
||||||
sysdate()
|
current_timestamp
|
||||||
)
|
)
|
||||||
</insert>
|
</insert>
|
||||||
|
|
||||||
@ -105,7 +105,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||||||
dict_type = #{dictType},
|
dict_type = #{dictType},
|
||||||
sort = #{sort},
|
sort = #{sort},
|
||||||
update_by = #{updateBy},
|
update_by = #{updateBy},
|
||||||
update_time = sysdate()
|
update_time = current_timestamp
|
||||||
</set>
|
</set>
|
||||||
where column_id = #{columnId}
|
where column_id = #{columnId}
|
||||||
</update>
|
</update>
|
||||||
|
@ -164,7 +164,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||||||
<if test="genPath != null and genPath != ''">#{genPath},</if>
|
<if test="genPath != null and genPath != ''">#{genPath},</if>
|
||||||
<if test="remark != null and remark != ''">#{remark},</if>
|
<if test="remark != null and remark != ''">#{remark},</if>
|
||||||
<if test="createBy != null and createBy != ''">#{createBy},</if>
|
<if test="createBy != null and createBy != ''">#{createBy},</if>
|
||||||
sysdate()
|
current_timestamp
|
||||||
)
|
)
|
||||||
</insert>
|
</insert>
|
||||||
|
|
||||||
@ -187,7 +187,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||||||
<if test="options != null and options != ''">options = #{options},</if>
|
<if test="options != null and options != ''">options = #{options},</if>
|
||||||
<if test="updateBy != null and updateBy != ''">update_by = #{updateBy},</if>
|
<if test="updateBy != null and updateBy != ''">update_by = #{updateBy},</if>
|
||||||
<if test="remark != null">remark = #{remark},</if>
|
<if test="remark != null">remark = #{remark},</if>
|
||||||
update_time = sysdate()
|
update_time = current_timestamp
|
||||||
</set>
|
</set>
|
||||||
where table_id = #{tableId}
|
where table_id = #{tableId}
|
||||||
</update>
|
</update>
|
||||||
|
@ -86,7 +86,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||||||
<if test="jobMessage != null and jobMessage != ''">#{jobMessage},</if>
|
<if test="jobMessage != null and jobMessage != ''">#{jobMessage},</if>
|
||||||
<if test="status != null and status != ''">#{status},</if>
|
<if test="status != null and status != ''">#{status},</if>
|
||||||
<if test="exceptionInfo != null and exceptionInfo != ''">#{exceptionInfo},</if>
|
<if test="exceptionInfo != null and exceptionInfo != ''">#{exceptionInfo},</if>
|
||||||
sysdate()
|
current_timestamp
|
||||||
)
|
)
|
||||||
</insert>
|
</insert>
|
||||||
|
|
||||||
|
@ -75,7 +75,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||||||
<if test="status !=null">status = #{status},</if>
|
<if test="status !=null">status = #{status},</if>
|
||||||
<if test="remark != null and remark != ''">remark = #{remark},</if>
|
<if test="remark != null and remark != ''">remark = #{remark},</if>
|
||||||
<if test="updateBy != null and updateBy != ''">update_by = #{updateBy},</if>
|
<if test="updateBy != null and updateBy != ''">update_by = #{updateBy},</if>
|
||||||
update_time = sysdate()
|
update_time = current_timestamp
|
||||||
</set>
|
</set>
|
||||||
where job_id = #{jobId}
|
where job_id = #{jobId}
|
||||||
</update>
|
</update>
|
||||||
@ -104,7 +104,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||||||
<if test="status != null and status != ''">#{status},</if>
|
<if test="status != null and status != ''">#{status},</if>
|
||||||
<if test="remark != null and remark != ''">#{remark},</if>
|
<if test="remark != null and remark != ''">#{remark},</if>
|
||||||
<if test="createBy != null and createBy != ''">#{createBy},</if>
|
<if test="createBy != null and createBy != ''">#{createBy},</if>
|
||||||
sysdate()
|
current_timestamp
|
||||||
)
|
)
|
||||||
</insert>
|
</insert>
|
||||||
|
|
||||||
|
@ -10,7 +10,9 @@ public class AustraliaMiddleEastVO extends SysBaseEntity
|
|||||||
{
|
{
|
||||||
private String id;
|
private String id;
|
||||||
|
|
||||||
private LocalDate yearMonth;
|
private String yearMonth;
|
||||||
|
|
||||||
|
private String month;
|
||||||
|
|
||||||
private Double sstAnomalyIndex;
|
private Double sstAnomalyIndex;
|
||||||
|
|
||||||
@ -20,10 +22,6 @@ public class AustraliaMiddleEastVO extends SysBaseEntity
|
|||||||
|
|
||||||
private Double vaiAnomolies;
|
private Double vaiAnomolies;
|
||||||
|
|
||||||
private String createdBy;
|
|
||||||
|
|
||||||
private LocalDate createdTime;
|
|
||||||
|
|
||||||
public String getId() {
|
public String getId() {
|
||||||
return id;
|
return id;
|
||||||
}
|
}
|
||||||
@ -32,11 +30,11 @@ public class AustraliaMiddleEastVO extends SysBaseEntity
|
|||||||
this.id = id;
|
this.id = id;
|
||||||
}
|
}
|
||||||
|
|
||||||
public LocalDate getYearMonth() {
|
public String getYearMonth() {
|
||||||
return yearMonth;
|
return yearMonth;
|
||||||
}
|
}
|
||||||
|
|
||||||
public void setYearMonth(LocalDate yearMonth) {
|
public void setYearMonth(String yearMonth) {
|
||||||
this.yearMonth = yearMonth;
|
this.yearMonth = yearMonth;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -72,19 +70,11 @@ public class AustraliaMiddleEastVO extends SysBaseEntity
|
|||||||
this.vaiAnomolies = vaiAnomolies;
|
this.vaiAnomolies = vaiAnomolies;
|
||||||
}
|
}
|
||||||
|
|
||||||
public String getCreatedBy() {
|
public String getMonth() {
|
||||||
return createdBy;
|
return month;
|
||||||
}
|
}
|
||||||
|
|
||||||
public void setCreatedBy(String createdBy) {
|
public void setMonth(String month) {
|
||||||
this.createdBy = createdBy;
|
this.month = month;
|
||||||
}
|
|
||||||
|
|
||||||
public LocalDate getCreatedTime() {
|
|
||||||
return createdTime;
|
|
||||||
}
|
|
||||||
|
|
||||||
public void setCreatedTime(LocalDate createdTime) {
|
|
||||||
this.createdTime = createdTime;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -0,0 +1,110 @@
|
|||||||
|
package com.ruoyi.system.domain_yada;
|
||||||
|
|
||||||
|
import java.time.LocalDate;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @Author: JinSheng Song
|
||||||
|
* @Date: 2022/6/10 10:04
|
||||||
|
*/
|
||||||
|
public class CastsVo
|
||||||
|
{
|
||||||
|
private String date;
|
||||||
|
|
||||||
|
private String week;
|
||||||
|
|
||||||
|
private String dayweather;
|
||||||
|
|
||||||
|
private String nightweather;
|
||||||
|
|
||||||
|
private String daytemp;
|
||||||
|
|
||||||
|
private String nighttemp;
|
||||||
|
|
||||||
|
private String daywind;
|
||||||
|
|
||||||
|
private String nightwind;
|
||||||
|
|
||||||
|
private String daypower;
|
||||||
|
|
||||||
|
private String nightpower;
|
||||||
|
|
||||||
|
public String getDate() {
|
||||||
|
return date;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setDate(String date) {
|
||||||
|
this.date = date;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getWeek() {
|
||||||
|
return week;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setWeek(String week) {
|
||||||
|
this.week = week;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getDayweather() {
|
||||||
|
return dayweather;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setDayweather(String dayweather) {
|
||||||
|
this.dayweather = dayweather;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getNightweather() {
|
||||||
|
return nightweather;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setNightweather(String nightweather) {
|
||||||
|
this.nightweather = nightweather;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getDaytemp() {
|
||||||
|
return daytemp;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setDaytemp(String daytemp) {
|
||||||
|
this.daytemp = daytemp;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getNighttemp() {
|
||||||
|
return nighttemp;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setNighttemp(String nighttemp) {
|
||||||
|
this.nighttemp = nighttemp;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getDaywind() {
|
||||||
|
return daywind;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setDaywind(String daywind) {
|
||||||
|
this.daywind = daywind;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getNightwind() {
|
||||||
|
return nightwind;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setNightwind(String nightwind) {
|
||||||
|
this.nightwind = nightwind;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getDaypower() {
|
||||||
|
return daypower;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setDaypower(String daypower) {
|
||||||
|
this.daypower = daypower;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getNightpower() {
|
||||||
|
return nightpower;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setNightpower(String nightpower) {
|
||||||
|
this.nightpower = nightpower;
|
||||||
|
}
|
||||||
|
}
|
@ -0,0 +1,69 @@
|
|||||||
|
package com.ruoyi.system.domain_yada;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @Author: JinSheng Song
|
||||||
|
* @Date: 2022/5/30 8:50
|
||||||
|
*/
|
||||||
|
//字典表
|
||||||
|
public class Dictionary extends SysBaseEntity
|
||||||
|
{
|
||||||
|
private String codingType;
|
||||||
|
|
||||||
|
private String codingType1;
|
||||||
|
|
||||||
|
private String codingType2;
|
||||||
|
|
||||||
|
private String dictionary;
|
||||||
|
|
||||||
|
private String name;
|
||||||
|
|
||||||
|
private String nameEn;
|
||||||
|
|
||||||
|
public String getCodingType1() {
|
||||||
|
return codingType1;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setCodingType1(String codingType1) {
|
||||||
|
this.codingType1 = codingType1;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getCodingType2() {
|
||||||
|
return codingType2;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setCodingType2(String codingType2) {
|
||||||
|
this.codingType2 = codingType2;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getCodingType() {
|
||||||
|
return codingType;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setCodingType(String codingType) {
|
||||||
|
this.codingType = codingType;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getDictionary() {
|
||||||
|
return dictionary;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setDictionary(String dictionary) {
|
||||||
|
this.dictionary = dictionary;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getName() {
|
||||||
|
return name;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setName(String name) {
|
||||||
|
this.name = name;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getNameEn() {
|
||||||
|
return nameEn;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setNameEn(String nameEn) {
|
||||||
|
this.nameEn = nameEn;
|
||||||
|
}
|
||||||
|
}
|
@ -0,0 +1,62 @@
|
|||||||
|
package com.ruoyi.system.domain_yada;
|
||||||
|
|
||||||
|
import java.time.LocalDateTime;
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @Author: JinSheng Song
|
||||||
|
* @Date: 2022/6/10 10:02
|
||||||
|
*/
|
||||||
|
public class ForecastVo {
|
||||||
|
|
||||||
|
private String city;
|
||||||
|
|
||||||
|
private String adcode;
|
||||||
|
|
||||||
|
private String province;
|
||||||
|
|
||||||
|
private String reporttime;
|
||||||
|
|
||||||
|
private List<CastsVo> casts;
|
||||||
|
|
||||||
|
public String getCity() {
|
||||||
|
return city;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setCity(String city) {
|
||||||
|
this.city = city;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getAdcode() {
|
||||||
|
return adcode;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setAdcode(String adcode) {
|
||||||
|
this.adcode = adcode;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getProvince() {
|
||||||
|
return province;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setProvince(String province) {
|
||||||
|
this.province = province;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getReporttime() {
|
||||||
|
return reporttime;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setReporttime(String reporttime) {
|
||||||
|
this.reporttime = reporttime;
|
||||||
|
}
|
||||||
|
|
||||||
|
public List<CastsVo> getCasts() {
|
||||||
|
return casts;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setCasts(List<CastsVo> casts) {
|
||||||
|
this.casts = casts;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -15,7 +15,7 @@ public class GlobalTypeVO extends SysBaseEntity {
|
|||||||
|
|
||||||
private Double areaProportion;
|
private Double areaProportion;
|
||||||
|
|
||||||
private String area;
|
private Double area;
|
||||||
|
|
||||||
private int particularYear;
|
private int particularYear;
|
||||||
|
|
||||||
@ -51,11 +51,11 @@ public class GlobalTypeVO extends SysBaseEntity {
|
|||||||
this.areaProportion = areaProportion;
|
this.areaProportion = areaProportion;
|
||||||
}
|
}
|
||||||
|
|
||||||
public String getArea() {
|
public Double getArea() {
|
||||||
return area;
|
return area;
|
||||||
}
|
}
|
||||||
|
|
||||||
public void setArea(String area) {
|
public void setArea(Double area) {
|
||||||
this.area = area;
|
this.area = area;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -0,0 +1,110 @@
|
|||||||
|
package com.ruoyi.system.domain_yada;
|
||||||
|
|
||||||
|
import java.time.LocalDateTime;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @Author: JinSheng Song
|
||||||
|
* @Date: 2022/6/10 9:57
|
||||||
|
*/
|
||||||
|
public class LivesVo
|
||||||
|
{
|
||||||
|
/**
|
||||||
|
* 省份名
|
||||||
|
*/
|
||||||
|
private String province;
|
||||||
|
/**
|
||||||
|
* 城市名
|
||||||
|
*/
|
||||||
|
private String city;
|
||||||
|
/**
|
||||||
|
* 区域编码
|
||||||
|
*/
|
||||||
|
private String adcode;
|
||||||
|
/**
|
||||||
|
*天气现象
|
||||||
|
*/
|
||||||
|
private String weather;
|
||||||
|
|
||||||
|
private String temperature;
|
||||||
|
|
||||||
|
private String winddirection;
|
||||||
|
|
||||||
|
private String windpower;
|
||||||
|
|
||||||
|
private String humidity;
|
||||||
|
|
||||||
|
private LocalDateTime reporttime;
|
||||||
|
|
||||||
|
public String getProvince() {
|
||||||
|
return province;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setProvince(String province) {
|
||||||
|
this.province = province;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getCity() {
|
||||||
|
return city;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setCity(String city) {
|
||||||
|
this.city = city;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getAdcode() {
|
||||||
|
return adcode;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setAdcode(String adcode) {
|
||||||
|
this.adcode = adcode;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getWeather() {
|
||||||
|
return weather;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setWeather(String weather) {
|
||||||
|
this.weather = weather;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getTemperature() {
|
||||||
|
return temperature;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setTemperature(String temperature) {
|
||||||
|
this.temperature = temperature;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getWinddirection() {
|
||||||
|
return winddirection;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setWinddirection(String winddirection) {
|
||||||
|
this.winddirection = winddirection;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getWindpower() {
|
||||||
|
return windpower;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setWindpower(String windpower) {
|
||||||
|
this.windpower = windpower;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getHumidity() {
|
||||||
|
return humidity;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setHumidity(String humidity) {
|
||||||
|
this.humidity = humidity;
|
||||||
|
}
|
||||||
|
|
||||||
|
public LocalDateTime getReporttime() {
|
||||||
|
return reporttime;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setReporttime(LocalDateTime reporttime) {
|
||||||
|
this.reporttime = reporttime;
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
@ -2,6 +2,7 @@ package com.ruoyi.system.domain_yada;
|
|||||||
|
|
||||||
import java.io.Serializable;
|
import java.io.Serializable;
|
||||||
import java.time.LocalDate;
|
import java.time.LocalDate;
|
||||||
|
import java.time.LocalDateTime;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @Author: JinSheng Song
|
* @Author: JinSheng Song
|
||||||
@ -22,11 +23,11 @@ public class RegionVGIVO implements Serializable {
|
|||||||
|
|
||||||
private Double grassland;
|
private Double grassland;
|
||||||
|
|
||||||
private Integer particularYear;
|
private String particularYear;
|
||||||
|
|
||||||
private String createdBy;
|
private String createdBy;
|
||||||
|
|
||||||
private LocalDate createdTime;
|
private LocalDateTime createdTime;
|
||||||
|
|
||||||
public String getId() {
|
public String getId() {
|
||||||
return id;
|
return id;
|
||||||
@ -84,11 +85,11 @@ public class RegionVGIVO implements Serializable {
|
|||||||
this.grassland = grassland;
|
this.grassland = grassland;
|
||||||
}
|
}
|
||||||
|
|
||||||
public Integer getParticularYear() {
|
public String getParticularYear() {
|
||||||
return particularYear;
|
return particularYear;
|
||||||
}
|
}
|
||||||
|
|
||||||
public void setParticularYear(Integer particularYear) {
|
public void setParticularYear(String particularYear) {
|
||||||
this.particularYear = particularYear;
|
this.particularYear = particularYear;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -100,11 +101,11 @@ public class RegionVGIVO implements Serializable {
|
|||||||
this.createdBy = createdBy;
|
this.createdBy = createdBy;
|
||||||
}
|
}
|
||||||
|
|
||||||
public LocalDate getCreatedTime() {
|
public LocalDateTime getCreatedTime() {
|
||||||
return createdTime;
|
return createdTime;
|
||||||
}
|
}
|
||||||
|
|
||||||
public void setCreatedTime(LocalDate createdTime) {
|
public void setCreatedTime(LocalDateTime createdTime) {
|
||||||
this.createdTime = createdTime;
|
this.createdTime = createdTime;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -11,6 +11,12 @@ public class ThematicMapDomain extends SysBaseEntity {
|
|||||||
|
|
||||||
private Long id;
|
private Long id;
|
||||||
|
|
||||||
|
private String pictureCode;
|
||||||
|
|
||||||
|
private String pictureTypeOne;
|
||||||
|
|
||||||
|
private String pictureTypeTwo;
|
||||||
|
|
||||||
private String pictureZh;
|
private String pictureZh;
|
||||||
|
|
||||||
private String pictureEn;
|
private String pictureEn;
|
||||||
@ -29,6 +35,31 @@ public class ThematicMapDomain extends SysBaseEntity {
|
|||||||
|
|
||||||
private LocalDateTime createdTime;
|
private LocalDateTime createdTime;
|
||||||
|
|
||||||
|
public String getPictureCode() {
|
||||||
|
return pictureCode;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setPictureCode(String pictureCode) {
|
||||||
|
this.pictureCode = pictureCode;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getPictureTypeOne() {
|
||||||
|
return pictureTypeOne;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setPictureTypeOne(String pictureTypeOne) {
|
||||||
|
this.pictureTypeOne = pictureTypeOne;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getPictureTypeTwo() {
|
||||||
|
return pictureTypeTwo;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setPictureTypeTwo(String pictureTypeTwo) {
|
||||||
|
this.pictureTypeTwo = pictureTypeTwo;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
public Long getId() {
|
public Long getId() {
|
||||||
return id;
|
return id;
|
||||||
}
|
}
|
||||||
@ -85,32 +116,26 @@ public class ThematicMapDomain extends SysBaseEntity {
|
|||||||
this.picturePath = picturePath;
|
this.picturePath = picturePath;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
public String getRemarks() {
|
public String getRemarks() {
|
||||||
return remarks;
|
return remarks;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
public void setRemarks(String remarks) {
|
public void setRemarks(String remarks) {
|
||||||
this.remarks = remarks;
|
this.remarks = remarks;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
public String getCreatedBy() {
|
public String getCreatedBy() {
|
||||||
return createdBy;
|
return createdBy;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
public void setCreatedBy(String createdBy) {
|
public void setCreatedBy(String createdBy) {
|
||||||
this.createdBy = createdBy;
|
this.createdBy = createdBy;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
public LocalDateTime getCreatedTime() {
|
public LocalDateTime getCreatedTime() {
|
||||||
return createdTime;
|
return createdTime;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
public void setCreatedTime(LocalDateTime createdTime) {
|
public void setCreatedTime(LocalDateTime createdTime) {
|
||||||
this.createdTime = createdTime;
|
this.createdTime = createdTime;
|
||||||
}
|
}
|
||||||
|
@ -0,0 +1,60 @@
|
|||||||
|
package com.ruoyi.system.domain_yada;
|
||||||
|
|
||||||
|
import java.time.LocalDate;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @Author: JinSheng Song
|
||||||
|
* @Date: 2022/5/24 14:24
|
||||||
|
*/
|
||||||
|
public class UploadFile extends SysBaseEntity
|
||||||
|
{
|
||||||
|
private String id;
|
||||||
|
|
||||||
|
private String fileId;
|
||||||
|
|
||||||
|
private String fileName;
|
||||||
|
|
||||||
|
private String filePath;
|
||||||
|
|
||||||
|
private String fileSize;
|
||||||
|
|
||||||
|
public String getId() {
|
||||||
|
return id;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setId(String id) {
|
||||||
|
this.id = id;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getFileId() {
|
||||||
|
return fileId;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setFileId(String fileId) {
|
||||||
|
this.fileId = fileId;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getFileName() {
|
||||||
|
return fileName;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setFileName(String fileName) {
|
||||||
|
this.fileName = fileName;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getFilePath() {
|
||||||
|
return filePath;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setFilePath(String filePath) {
|
||||||
|
this.filePath = filePath;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getFileSize() {
|
||||||
|
return fileSize;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setFileSize(String fileSize) {
|
||||||
|
this.fileSize = fileSize;
|
||||||
|
}
|
||||||
|
}
|
@ -0,0 +1,85 @@
|
|||||||
|
package com.ruoyi.system.domain_yada;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @Author: JinSheng Song
|
||||||
|
* @Date: 2022/6/10 9:53
|
||||||
|
*/
|
||||||
|
public class WeatherUtilsVO {
|
||||||
|
/**
|
||||||
|
* 接口返回状态
|
||||||
|
*/
|
||||||
|
private String status;
|
||||||
|
/**
|
||||||
|
* 返回结果数量
|
||||||
|
*/
|
||||||
|
private String count;
|
||||||
|
|
||||||
|
private String info;
|
||||||
|
|
||||||
|
private String infocode;
|
||||||
|
/**
|
||||||
|
* 实时天气预报
|
||||||
|
*/
|
||||||
|
private List<LivesVo> lives;
|
||||||
|
/**
|
||||||
|
* 预报天气
|
||||||
|
*/
|
||||||
|
private List<ForecastVo> forecasts;
|
||||||
|
|
||||||
|
// /**
|
||||||
|
// * 预报天气
|
||||||
|
// */
|
||||||
|
// private String forecasts;
|
||||||
|
|
||||||
|
public String getStatus() {
|
||||||
|
return status;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setStatus(String status) {
|
||||||
|
this.status = status;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getCount() {
|
||||||
|
return count;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setCount(String count) {
|
||||||
|
this.count = count;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getInfo() {
|
||||||
|
return info;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setInfo(String info) {
|
||||||
|
this.info = info;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getInfocode() {
|
||||||
|
return infocode;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setInfocode(String infocode) {
|
||||||
|
this.infocode = infocode;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
public List<ForecastVo> getForecasts() {
|
||||||
|
return forecasts;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setForecasts(List<ForecastVo> forecasts) {
|
||||||
|
this.forecasts = forecasts;
|
||||||
|
}
|
||||||
|
|
||||||
|
public List<LivesVo> getLives() {
|
||||||
|
return lives;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setLives(List<LivesVo> lives) {
|
||||||
|
this.lives = lives;
|
||||||
|
}
|
||||||
|
}
|
@ -1,6 +1,8 @@
|
|||||||
package com.ruoyi.system.mapper_yada;
|
package com.ruoyi.system.mapper_yada;
|
||||||
|
|
||||||
import com.ruoyi.system.domain_yada.AorestCoverageVO;
|
import com.ruoyi.system.domain_yada.AorestCoverageVO;
|
||||||
|
import com.ruoyi.system.domain_yada.Dictionary;
|
||||||
|
import com.ruoyi.system.domain_yada.UploadFile;
|
||||||
import org.apache.ibatis.annotations.Param;
|
import org.apache.ibatis.annotations.Param;
|
||||||
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
@ -11,9 +13,17 @@ import java.util.List;
|
|||||||
*/
|
*/
|
||||||
public interface AorestCoverageMapper {
|
public interface AorestCoverageMapper {
|
||||||
|
|
||||||
List<AorestCoverageVO> selectAorestCoverage();
|
List<AorestCoverageVO> selectAorestCoverage(/*@Param("region") String region,
|
||||||
|
@Param("particularYear") String particularYear*/);
|
||||||
|
|
||||||
Integer DelAorestCoverage(@Param("id") String id);
|
Integer DelAorestCoverage(@Param("id") String id);
|
||||||
|
|
||||||
Integer IntoAorestCoverage(AorestCoverageVO eastVO);
|
Integer IntoAorestCoverage(AorestCoverageVO eastVO);
|
||||||
|
|
||||||
|
Integer IntoUpload(UploadFile file);
|
||||||
|
|
||||||
|
List<UploadFile> selectUpload(@Param("fileId") String fileId,@Param("fileName") String fileName);
|
||||||
|
|
||||||
|
List<Dictionary> selectDic(@Param("codingType") String codingType,@Param("codingType1") String codingType1,
|
||||||
|
@Param("codingType2") String codingType2);
|
||||||
}
|
}
|
||||||
|
@ -13,7 +13,8 @@ import java.util.List;
|
|||||||
*/
|
*/
|
||||||
public interface AustraliaMiddleEastMapper {
|
public interface AustraliaMiddleEastMapper {
|
||||||
|
|
||||||
List<AustraliaMiddleEastVO> selectAustralia();
|
List<AustraliaMiddleEastVO> selectAustralia(@Param("yearMonth") String yearMonth,
|
||||||
|
@Param("month") String month);
|
||||||
|
|
||||||
Integer DelAustralia(@Param("id") String id);
|
Integer DelAustralia(@Param("id") String id);
|
||||||
|
|
||||||
|
@ -11,7 +11,7 @@ import java.util.List;
|
|||||||
*/
|
*/
|
||||||
public interface GlobalTypeMapper {
|
public interface GlobalTypeMapper {
|
||||||
|
|
||||||
List<GlobalTypeVO> selectGlobalType();
|
List<GlobalTypeVO> selectGlobalType(@Param("typeName") String typeName, @Param("particularYear") Integer particularYear);
|
||||||
|
|
||||||
Integer DelGlobalType(@Param("id") String id);
|
Integer DelGlobalType(@Param("id") String id);
|
||||||
|
|
||||||
|
@ -4,6 +4,7 @@ import com.ruoyi.system.domain_yada.OceanTemperatureVO;
|
|||||||
import org.apache.ibatis.annotations.Param;
|
import org.apache.ibatis.annotations.Param;
|
||||||
import org.springframework.stereotype.Repository;
|
import org.springframework.stereotype.Repository;
|
||||||
|
|
||||||
|
import java.time.LocalDate;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -13,7 +14,7 @@ import java.util.List;
|
|||||||
@Repository
|
@Repository
|
||||||
public interface OceanTemperatureMapper {
|
public interface OceanTemperatureMapper {
|
||||||
|
|
||||||
List<OceanTemperatureVO> selectOcean();
|
List<OceanTemperatureVO> selectOcean(@Param("startDate") LocalDate startDate);
|
||||||
|
|
||||||
Integer DelOcean(@Param("id") String id);
|
Integer DelOcean(@Param("id") String id);
|
||||||
|
|
||||||
|
@ -11,7 +11,8 @@ import java.util.List;
|
|||||||
*/
|
*/
|
||||||
public interface RegionVGIMapper {
|
public interface RegionVGIMapper {
|
||||||
|
|
||||||
List<RegionVGIVO> selectRegion();
|
List<RegionVGIVO> selectRegion(/*@Param("typeName") String typeName,
|
||||||
|
@Param("particularYear") String particularYear*/);
|
||||||
|
|
||||||
Integer DelRegion(@Param("id") String id);
|
Integer DelRegion(@Param("id") String id);
|
||||||
|
|
||||||
|
@ -3,6 +3,7 @@ package com.ruoyi.system.mapper_yada;
|
|||||||
import com.ruoyi.system.domain_yada.RegionalSystemVO;
|
import com.ruoyi.system.domain_yada.RegionalSystemVO;
|
||||||
import org.apache.ibatis.annotations.Param;
|
import org.apache.ibatis.annotations.Param;
|
||||||
|
|
||||||
|
import java.time.LocalDate;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -11,7 +12,7 @@ import java.util.List;
|
|||||||
*/
|
*/
|
||||||
public interface RegionalSystemMapper {
|
public interface RegionalSystemMapper {
|
||||||
|
|
||||||
List<RegionalSystemVO> selectRegional();
|
List<RegionalSystemVO> selectRegional(@Param("region") String region);
|
||||||
|
|
||||||
Integer DelRegional(@Param("id") String id);
|
Integer DelRegional(@Param("id") String id);
|
||||||
|
|
||||||
|
@ -2,8 +2,10 @@ package com.ruoyi.system.mapper_yada;
|
|||||||
|
|
||||||
import com.ruoyi.system.domain_yada.ThematicMapDomain;
|
import com.ruoyi.system.domain_yada.ThematicMapDomain;
|
||||||
import org.apache.ibatis.annotations.Mapper;
|
import org.apache.ibatis.annotations.Mapper;
|
||||||
|
import org.apache.ibatis.annotations.Param;
|
||||||
import org.springframework.stereotype.Repository;
|
import org.springframework.stereotype.Repository;
|
||||||
|
|
||||||
|
import java.time.LocalDateTime;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -15,7 +17,9 @@ public interface ThematicMapMapper {
|
|||||||
* 获取所有专题图
|
* 获取所有专题图
|
||||||
* @return
|
* @return
|
||||||
*/
|
*/
|
||||||
List<ThematicMapDomain> selectAllThematicMap();
|
List<ThematicMapDomain> selectAllThematicMap(@Param("pictureType") String pictureType,
|
||||||
|
@Param("pictureTypeOne") String pictureTypeOne,
|
||||||
|
@Param("pictureTypeTwo") String pictureTypeTwo);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 删除专题图根据编号
|
* 删除专题图根据编号
|
||||||
|
@ -12,7 +12,8 @@ import java.util.List;
|
|||||||
*/
|
*/
|
||||||
public interface UrbanMapper {
|
public interface UrbanMapper {
|
||||||
|
|
||||||
List<UrbanVO> selectUrban();
|
List<UrbanVO> selectUrban(@Param("name") String name,
|
||||||
|
@Param("particularYear") String particularYear);
|
||||||
|
|
||||||
Integer DelUrban(@Param("id") String id);
|
Integer DelUrban(@Param("id") String id);
|
||||||
|
|
||||||
|
@ -11,7 +11,8 @@ import java.util.List;
|
|||||||
*/
|
*/
|
||||||
public interface VegetationCoverageMapper {
|
public interface VegetationCoverageMapper {
|
||||||
|
|
||||||
List<VegetationCoverageVO> selectVegetation();
|
List<VegetationCoverageVO> selectVegetation(/*@Param("region") String region,
|
||||||
|
@Param("particularYear") String particularYear*/);
|
||||||
|
|
||||||
Integer DelVegetation(@Param("id") String id);
|
Integer DelVegetation(@Param("id") String id);
|
||||||
|
|
||||||
|
@ -1,7 +1,10 @@
|
|||||||
package com.ruoyi.system.service_yada;
|
package com.ruoyi.system.service_yada;
|
||||||
|
|
||||||
|
import com.ruoyi.common.utils.PageUtils;
|
||||||
import com.ruoyi.system.domain_yada.AorestCoverageVO;
|
import com.ruoyi.system.domain_yada.AorestCoverageVO;
|
||||||
import com.ruoyi.system.domain_yada.AustraliaMiddleEastVO;
|
import com.ruoyi.system.domain_yada.AustraliaMiddleEastVO;
|
||||||
|
import com.ruoyi.system.domain_yada.Dictionary;
|
||||||
|
import com.ruoyi.system.domain_yada.UploadFile;
|
||||||
import org.apache.ibatis.annotations.Param;
|
import org.apache.ibatis.annotations.Param;
|
||||||
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
@ -13,9 +16,16 @@ import java.util.List;
|
|||||||
*/
|
*/
|
||||||
public interface IAorestCoverageService {
|
public interface IAorestCoverageService {
|
||||||
|
|
||||||
public List<AorestCoverageVO> selectAorestCoverage();
|
public List<AorestCoverageVO> selectAorestCoverage(/*String region,String particularYear*/);
|
||||||
|
|
||||||
public Integer DelAorestCoverage(@Param("id") String id);
|
public Integer DelAorestCoverage(String id);
|
||||||
|
|
||||||
public Integer IntoAorestCoverage(AorestCoverageVO eastVO);
|
public Integer IntoAorestCoverage(AorestCoverageVO eastVO);
|
||||||
|
|
||||||
|
public Integer IntoUpload(UploadFile file);
|
||||||
|
|
||||||
|
public List<UploadFile> selectUpload(String fileId,String fileName);
|
||||||
|
|
||||||
|
List<Dictionary> selectDic(String codingType,String codingType1,
|
||||||
|
String codingType2);
|
||||||
}
|
}
|
||||||
|
@ -12,7 +12,7 @@ import java.util.List;
|
|||||||
*/
|
*/
|
||||||
public interface IAustraliaMiddleEastService
|
public interface IAustraliaMiddleEastService
|
||||||
{
|
{
|
||||||
public List<AustraliaMiddleEastVO> selectAustralia();
|
public List<AustraliaMiddleEastVO> selectAustralia(String yearMonth,String month);
|
||||||
|
|
||||||
public Integer DelAustralia(@Param("id") String id);
|
public Integer DelAustralia(@Param("id") String id);
|
||||||
|
|
||||||
|
@ -13,7 +13,7 @@ import java.util.List;
|
|||||||
*/
|
*/
|
||||||
public interface IGlobalTypeService {
|
public interface IGlobalTypeService {
|
||||||
|
|
||||||
public List<GlobalTypeVO> selectGlobalType();
|
public List<GlobalTypeVO> selectGlobalType(String typeName, Integer particularYear);
|
||||||
|
|
||||||
public Integer DelGlobalType(String id);
|
public Integer DelGlobalType(String id);
|
||||||
|
|
||||||
|
@ -4,6 +4,7 @@ import com.ruoyi.system.domain_yada.AustraliaMiddleEastVO;
|
|||||||
import com.ruoyi.system.domain_yada.OceanTemperatureVO;
|
import com.ruoyi.system.domain_yada.OceanTemperatureVO;
|
||||||
import org.apache.ibatis.annotations.Param;
|
import org.apache.ibatis.annotations.Param;
|
||||||
|
|
||||||
|
import java.time.LocalDate;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -13,7 +14,7 @@ import java.util.List;
|
|||||||
*/
|
*/
|
||||||
public interface IOceanTemperatureService {
|
public interface IOceanTemperatureService {
|
||||||
|
|
||||||
public List<OceanTemperatureVO> selectOcean();
|
public List<OceanTemperatureVO> selectOcean(LocalDate startDate);
|
||||||
|
|
||||||
public Integer DelOcean(@Param("id") String id);
|
public Integer DelOcean(@Param("id") String id);
|
||||||
|
|
||||||
|
@ -15,7 +15,7 @@ public interface IRegionVGIService {
|
|||||||
* 查询
|
* 查询
|
||||||
* @return
|
* @return
|
||||||
*/
|
*/
|
||||||
public List<RegionVGIVO> selectRegion();
|
public List<RegionVGIVO> selectRegion(/*String typeName,String particularYear*/);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 删除
|
* 删除
|
||||||
|
@ -13,7 +13,7 @@ import java.util.List;
|
|||||||
*/
|
*/
|
||||||
public interface IRegionalSystemService {
|
public interface IRegionalSystemService {
|
||||||
|
|
||||||
public List<RegionalSystemVO> selectRegional();
|
public List<RegionalSystemVO> selectRegional(String region);
|
||||||
|
|
||||||
public Integer DelRegional(@Param("id") String id);
|
public Integer DelRegional(@Param("id") String id);
|
||||||
|
|
||||||
|
@ -12,7 +12,7 @@ import java.util.List;
|
|||||||
*/
|
*/
|
||||||
public interface IUrbanService {
|
public interface IUrbanService {
|
||||||
|
|
||||||
public List<UrbanVO> selectUrban();
|
public List<UrbanVO> selectUrban(String name, String particularYear);
|
||||||
|
|
||||||
public Integer DelUrban(@Param("id") String id);
|
public Integer DelUrban(@Param("id") String id);
|
||||||
|
|
||||||
|
@ -13,7 +13,7 @@ import java.util.List;
|
|||||||
*/
|
*/
|
||||||
public interface IVegetationCoverageService {
|
public interface IVegetationCoverageService {
|
||||||
|
|
||||||
public List<VegetationCoverageVO> selectVegetation();
|
public List<VegetationCoverageVO> selectVegetation(/*String region,String particularYear*/);
|
||||||
|
|
||||||
public Integer DelVegetation(String id);
|
public Integer DelVegetation(String id);
|
||||||
|
|
||||||
|
@ -2,6 +2,7 @@ package com.ruoyi.system.service_yada;
|
|||||||
|
|
||||||
import com.ruoyi.system.domain_yada.ThematicMapDomain;
|
import com.ruoyi.system.domain_yada.ThematicMapDomain;
|
||||||
|
|
||||||
|
import java.time.LocalDateTime;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -16,7 +17,7 @@ public interface ThematicMapService {
|
|||||||
* 获取全部专题图
|
* 获取全部专题图
|
||||||
* @return
|
* @return
|
||||||
*/
|
*/
|
||||||
List<ThematicMapDomain> selectAll();
|
List<ThematicMapDomain> selectAll(String pictureType,String pictureTypeOne, String pictureTypeTwo);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 删除专题图根据编号
|
* 删除专题图根据编号
|
||||||
|
@ -2,9 +2,12 @@ package com.ruoyi.system.service_yada.impl;
|
|||||||
|
|
||||||
import com.ruoyi.system.domain_yada.AorestCoverageVO;
|
import com.ruoyi.system.domain_yada.AorestCoverageVO;
|
||||||
import com.ruoyi.system.domain_yada.AustraliaMiddleEastVO;
|
import com.ruoyi.system.domain_yada.AustraliaMiddleEastVO;
|
||||||
|
import com.ruoyi.system.domain_yada.Dictionary;
|
||||||
|
import com.ruoyi.system.domain_yada.UploadFile;
|
||||||
import com.ruoyi.system.mapper_yada.AorestCoverageMapper;
|
import com.ruoyi.system.mapper_yada.AorestCoverageMapper;
|
||||||
import com.ruoyi.system.mapper_yada.AustraliaMiddleEastMapper;
|
import com.ruoyi.system.mapper_yada.AustraliaMiddleEastMapper;
|
||||||
import com.ruoyi.system.service_yada.IAorestCoverageService;
|
import com.ruoyi.system.service_yada.IAorestCoverageService;
|
||||||
|
import org.apache.ibatis.annotations.Param;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
import org.springframework.stereotype.Service;
|
import org.springframework.stereotype.Service;
|
||||||
|
|
||||||
@ -23,8 +26,8 @@ public class AorestCoverageServiceimpl implements IAorestCoverageService {
|
|||||||
|
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public List<AorestCoverageVO> selectAorestCoverage() {
|
public List<AorestCoverageVO> selectAorestCoverage(/*String region,String particularYear*/) {
|
||||||
return coverageMapper.selectAorestCoverage();
|
return coverageMapper.selectAorestCoverage(/*region,particularYear*/);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@ -34,6 +37,22 @@ public class AorestCoverageServiceimpl implements IAorestCoverageService {
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public Integer IntoAorestCoverage(AorestCoverageVO eastVO) {
|
public Integer IntoAorestCoverage(AorestCoverageVO eastVO) {
|
||||||
return IntoAorestCoverage(eastVO);
|
return coverageMapper.IntoAorestCoverage(eastVO);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public Integer IntoUpload(UploadFile file) {
|
||||||
|
return coverageMapper.IntoUpload(file);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public List<UploadFile> selectUpload(String fileId, String fileName) {
|
||||||
|
return coverageMapper.selectUpload(fileId,fileName);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public List<Dictionary> selectDic(String codingType,String codingType1,
|
||||||
|
String codingType2) {
|
||||||
|
return coverageMapper.selectDic(codingType,codingType1,codingType2);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -21,9 +21,9 @@ public class AustraliaMiddleEastServiceimpl implements IAustraliaMiddleEastServi
|
|||||||
private AustraliaMiddleEastMapper australiaMiddleEastMapper;
|
private AustraliaMiddleEastMapper australiaMiddleEastMapper;
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public List<AustraliaMiddleEastVO> selectAustralia()
|
public List<AustraliaMiddleEastVO> selectAustralia(String yearMonth,String month)
|
||||||
{
|
{
|
||||||
return australiaMiddleEastMapper.selectAustralia();
|
return australiaMiddleEastMapper.selectAustralia(yearMonth,month);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
@ -5,6 +5,8 @@ import com.ruoyi.system.domain_yada.GlobalTypeVO;
|
|||||||
import com.ruoyi.system.mapper_yada.AustraliaMiddleEastMapper;
|
import com.ruoyi.system.mapper_yada.AustraliaMiddleEastMapper;
|
||||||
import com.ruoyi.system.mapper_yada.GlobalTypeMapper;
|
import com.ruoyi.system.mapper_yada.GlobalTypeMapper;
|
||||||
import com.ruoyi.system.service_yada.IGlobalTypeService;
|
import com.ruoyi.system.service_yada.IGlobalTypeService;
|
||||||
|
import org.apache.commons.compress.archivers.dump.DumpArchiveEntry;
|
||||||
|
import org.apache.ibatis.annotations.Param;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
import org.springframework.stereotype.Service;
|
import org.springframework.stereotype.Service;
|
||||||
|
|
||||||
@ -24,8 +26,8 @@ public class GlobalTypeServiceimpl implements IGlobalTypeService {
|
|||||||
|
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public List<GlobalTypeVO> selectGlobalType() {
|
public List<GlobalTypeVO> selectGlobalType(String typeName, Integer particularYear) {
|
||||||
return typeMapper.selectGlobalType();
|
return typeMapper.selectGlobalType(typeName, particularYear);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
@ -9,6 +9,7 @@ import org.springframework.beans.factory.annotation.Autowired;
|
|||||||
import org.springframework.stereotype.Service;
|
import org.springframework.stereotype.Service;
|
||||||
|
|
||||||
import javax.annotation.Resource;
|
import javax.annotation.Resource;
|
||||||
|
import java.time.LocalDate;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -24,8 +25,8 @@ public class OceanTemperatureServiceimpl implements IOceanTemperatureService {
|
|||||||
|
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public List<OceanTemperatureVO> selectOcean() {
|
public List<OceanTemperatureVO> selectOcean(LocalDate startDate) {
|
||||||
return oceanMapper.selectOcean();
|
return oceanMapper.selectOcean(startDate);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
@ -3,6 +3,7 @@ package com.ruoyi.system.service_yada.impl;
|
|||||||
import com.ruoyi.system.mapper_yada.RegionVGIMapper;
|
import com.ruoyi.system.mapper_yada.RegionVGIMapper;
|
||||||
import com.ruoyi.system.service_yada.IRegionVGIService;
|
import com.ruoyi.system.service_yada.IRegionVGIService;
|
||||||
import com.ruoyi.system.domain_yada.RegionVGIVO;
|
import com.ruoyi.system.domain_yada.RegionVGIVO;
|
||||||
|
import org.apache.ibatis.annotations.Param;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
import org.springframework.stereotype.Service;
|
import org.springframework.stereotype.Service;
|
||||||
|
|
||||||
@ -21,8 +22,8 @@ public class RegionVGIServiceimpl implements IRegionVGIService {
|
|||||||
private RegionVGIMapper vgiMapper;
|
private RegionVGIMapper vgiMapper;
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public List<RegionVGIVO> selectRegion() {
|
public List<RegionVGIVO> selectRegion(/*String typeName,String particularYear*/) {
|
||||||
return vgiMapper.selectRegion();
|
return vgiMapper.selectRegion(/*typeName,particularYear*/);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
@ -5,6 +5,7 @@ import com.ruoyi.system.domain_yada.RegionalSystemVO;
|
|||||||
import com.ruoyi.system.mapper_yada.AustraliaMiddleEastMapper;
|
import com.ruoyi.system.mapper_yada.AustraliaMiddleEastMapper;
|
||||||
import com.ruoyi.system.mapper_yada.RegionalSystemMapper;
|
import com.ruoyi.system.mapper_yada.RegionalSystemMapper;
|
||||||
import com.ruoyi.system.service_yada.IRegionalSystemService;
|
import com.ruoyi.system.service_yada.IRegionalSystemService;
|
||||||
|
import org.apache.ibatis.annotations.Param;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
import org.springframework.stereotype.Service;
|
import org.springframework.stereotype.Service;
|
||||||
|
|
||||||
@ -24,8 +25,8 @@ public class RegionalSystemServiceimpl implements IRegionalSystemService {
|
|||||||
|
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public List<RegionalSystemVO> selectRegional() {
|
public List<RegionalSystemVO> selectRegional(String region) {
|
||||||
return Regional.selectRegional();
|
return Regional.selectRegional(region);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
@ -3,9 +3,11 @@ package com.ruoyi.system.service_yada.impl;
|
|||||||
import com.ruoyi.system.domain_yada.ThematicMapDomain;
|
import com.ruoyi.system.domain_yada.ThematicMapDomain;
|
||||||
import com.ruoyi.system.mapper_yada.ThematicMapMapper;
|
import com.ruoyi.system.mapper_yada.ThematicMapMapper;
|
||||||
import com.ruoyi.system.service_yada.ThematicMapService;
|
import com.ruoyi.system.service_yada.ThematicMapService;
|
||||||
|
import org.apache.ibatis.annotations.Param;
|
||||||
import org.springframework.stereotype.Service;
|
import org.springframework.stereotype.Service;
|
||||||
|
|
||||||
import javax.annotation.Resource;
|
import javax.annotation.Resource;
|
||||||
|
import java.time.LocalDateTime;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -23,8 +25,8 @@ public class ThematicMapServiceImpl implements ThematicMapService {
|
|||||||
* @return
|
* @return
|
||||||
*/
|
*/
|
||||||
@Override
|
@Override
|
||||||
public List<ThematicMapDomain> selectAll(){
|
public List<ThematicMapDomain> selectAll(String pictureType,String pictureTypeOne, String pictureTypeTwo){
|
||||||
return thematicMapMapper.selectAllThematicMap();
|
return thematicMapMapper.selectAllThematicMap(pictureType,pictureTypeOne,pictureTypeTwo);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -4,6 +4,7 @@ import com.ruoyi.system.domain_yada.UrbanVO;
|
|||||||
import com.ruoyi.system.mapper_yada.AorestCoverageMapper;
|
import com.ruoyi.system.mapper_yada.AorestCoverageMapper;
|
||||||
import com.ruoyi.system.mapper_yada.UrbanMapper;
|
import com.ruoyi.system.mapper_yada.UrbanMapper;
|
||||||
import com.ruoyi.system.service_yada.IUrbanService;
|
import com.ruoyi.system.service_yada.IUrbanService;
|
||||||
|
import org.apache.ibatis.annotations.Param;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
import org.springframework.stereotype.Service;
|
import org.springframework.stereotype.Service;
|
||||||
|
|
||||||
@ -23,8 +24,8 @@ public class UrbanServiceimpl implements IUrbanService {
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|
||||||
public List<UrbanVO> selectUrban() {
|
public List<UrbanVO> selectUrban(String name, String particularYear) {
|
||||||
return urbanMapper.selectUrban();
|
return urbanMapper.selectUrban(name,particularYear);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
@ -5,6 +5,7 @@ import com.ruoyi.system.domain_yada.VegetationCoverageVO;
|
|||||||
import com.ruoyi.system.mapper_yada.AustraliaMiddleEastMapper;
|
import com.ruoyi.system.mapper_yada.AustraliaMiddleEastMapper;
|
||||||
import com.ruoyi.system.mapper_yada.VegetationCoverageMapper;
|
import com.ruoyi.system.mapper_yada.VegetationCoverageMapper;
|
||||||
import com.ruoyi.system.service_yada.IVegetationCoverageService;
|
import com.ruoyi.system.service_yada.IVegetationCoverageService;
|
||||||
|
import org.apache.ibatis.annotations.Param;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
import org.springframework.stereotype.Service;
|
import org.springframework.stereotype.Service;
|
||||||
|
|
||||||
@ -25,8 +26,8 @@ public class VegetationCoverageServiceimpl implements IVegetationCoverageService
|
|||||||
|
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public List<VegetationCoverageVO> selectVegetation() {
|
public List<VegetationCoverageVO> selectVegetation(/*String region,String particularYear*/) {
|
||||||
return coverageMapper.selectVegetation();
|
return coverageMapper.selectVegetation(/*region,particularYear*/);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
@ -5,7 +5,6 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||||||
<mapper namespace="com.ruoyi.system.mapper_yada.AorestCoverageMapper">
|
<mapper namespace="com.ruoyi.system.mapper_yada.AorestCoverageMapper">
|
||||||
|
|
||||||
<resultMap id="RM_AorestCoverage" type="com.ruoyi.system.domain_yada.AorestCoverageVO">
|
<resultMap id="RM_AorestCoverage" type="com.ruoyi.system.domain_yada.AorestCoverageVO">
|
||||||
|
|
||||||
<result property="id" column="id"/>
|
<result property="id" column="id"/>
|
||||||
<result property="particularYear" column="particular_year"/>
|
<result property="particularYear" column="particular_year"/>
|
||||||
<result property="region" column="region"/>
|
<result property="region" column="region"/>
|
||||||
@ -25,7 +24,14 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||||||
</sql>
|
</sql>
|
||||||
|
|
||||||
<select id="selectAorestCoverage" resultMap="RM_AorestCoverage">
|
<select id="selectAorestCoverage" resultMap="RM_AorestCoverage">
|
||||||
SELECT <include refid="columns"/> FROM forest_coverage;
|
SELECT <include refid="columns"/> FROM forest_coverage
|
||||||
|
<!-- WHERE 1=1-->
|
||||||
|
<!-- <if test="particularYear!= null and particularYear !=''">-->
|
||||||
|
<!-- AND particular_year = #{particularYear}-->
|
||||||
|
<!-- </if>-->
|
||||||
|
<!-- <if test="region!= null and region !=''">-->
|
||||||
|
<!-- AND region = #{typeName}-->
|
||||||
|
<!-- </if>-->
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
<delete id="DelAorestCoverage">
|
<delete id="DelAorestCoverage">
|
||||||
@ -36,7 +42,6 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||||||
<insert id="IntoAorestCoverage">
|
<insert id="IntoAorestCoverage">
|
||||||
<![CDATA[
|
<![CDATA[
|
||||||
INSERT INTO forest_coverage (
|
INSERT INTO forest_coverage (
|
||||||
id ,
|
|
||||||
particular_year ,
|
particular_year ,
|
||||||
region ,
|
region ,
|
||||||
region_en ,
|
region_en ,
|
||||||
@ -44,21 +49,98 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||||||
non_protected_lands ,
|
non_protected_lands ,
|
||||||
mountain,
|
mountain,
|
||||||
non_mountain,
|
non_mountain,
|
||||||
created_by ,
|
created_by,
|
||||||
created_time
|
created_time
|
||||||
) VALUES (
|
) VALUES (
|
||||||
#{id,jdbcType=VARCHAR},
|
|
||||||
#{particularYear,jdbcType=VARCHAR},
|
#{particularYear,jdbcType=VARCHAR},
|
||||||
#{region,jdbcType=VARCHAR},
|
#{region,jdbcType=VARCHAR},
|
||||||
#{regionEn,jdbcType=VARCHAR},
|
#{regionEn,jdbcType=VARCHAR},
|
||||||
#{protectedLands,jdbcType=DOUBLE},
|
#{protectedLands,jdbcType=DOUBLE},
|
||||||
#{nonProtectedLand,jdbcType=DOUBLE},
|
#{nonProtectedLands,jdbcType=DOUBLE},
|
||||||
#{mountain,jdbcType=DOUBLE},
|
#{mountain,jdbcType=DOUBLE},
|
||||||
#{nonMountain,jdbcType=DOUBLE},
|
#{nonMountain,jdbcType=DOUBLE},
|
||||||
#{createBy,jdbcType=VARCHAR},
|
#{createBy,jdbcType=VARCHAR},
|
||||||
#{createTime,jdbcType=DATE}
|
#{createTime,jdbcType=TIMESTAMP}
|
||||||
)
|
)
|
||||||
]]>
|
]]>
|
||||||
</insert>
|
</insert>
|
||||||
|
|
||||||
|
<resultMap id="RM_Upload" type="com.ruoyi.system.domain_yada.UploadFile">
|
||||||
|
<result property="id" column="id"/>
|
||||||
|
<result property="fileId" column="file_id"/>
|
||||||
|
<result property="fileName" column="file_name"/>
|
||||||
|
<result property="fileSize" column="file_size"/>
|
||||||
|
<result property="filePath" column="file_path"/>
|
||||||
|
<result property="createBy" column="created_by"/>
|
||||||
|
<result property="createTime" column="created_time"/>
|
||||||
|
</resultMap>
|
||||||
|
|
||||||
|
<insert id="IntoUpload">
|
||||||
|
<![CDATA[
|
||||||
|
INSERT INTO sys_file_info (
|
||||||
|
id ,
|
||||||
|
file_id ,
|
||||||
|
file_name ,
|
||||||
|
file_size ,
|
||||||
|
file_path ,
|
||||||
|
created_by,
|
||||||
|
created_time
|
||||||
|
) VALUES (
|
||||||
|
#{id,jdbcType=VARCHAR},
|
||||||
|
#{fileId,jdbcType=VARCHAR},
|
||||||
|
#{fileName,jdbcType=VARCHAR},
|
||||||
|
#{fileSize,jdbcType=VARCHAR},
|
||||||
|
#{filePath,jdbcType=VARCHAR},
|
||||||
|
#{createBy,jdbcType=VARCHAR},
|
||||||
|
#{createTime,jdbcType=TIMESTAMP}
|
||||||
|
)
|
||||||
|
]]>
|
||||||
|
</insert>
|
||||||
|
|
||||||
|
<select id="selectUpload" resultMap="RM_Upload">
|
||||||
|
SELECT file_id,file_name,file_size,file_path,created_by,created_time FROM sys_file_info
|
||||||
|
WHERE 1=1
|
||||||
|
<if test="fileId!= null and fileId !=''">
|
||||||
|
AND fileId = #{fileId}
|
||||||
|
</if>
|
||||||
|
<if test="fileName!= null and fileName !=''">
|
||||||
|
AND file_name = #{fileName}
|
||||||
|
</if>
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<resultMap id="RM_Dictionary" type="com.ruoyi.system.domain_yada.Dictionary">
|
||||||
|
<result property="codingType" column="coding_type"/>
|
||||||
|
<result property="codingType1" column="codingType1"/>
|
||||||
|
<result property="codingType2" column="codingType2"/>
|
||||||
|
<result property="dictionary" column="dictionary"/>
|
||||||
|
<result property="name" column="name"/>
|
||||||
|
<result property="nameEn" column="name_en"/>
|
||||||
|
<result property="createBy" column="created_by"/>
|
||||||
|
<result property="createTime" column="created_time"/>
|
||||||
|
</resultMap>
|
||||||
|
|
||||||
|
<sql id="columnsdic">
|
||||||
|
<![CDATA[
|
||||||
|
coding_type,dictionary,name,name_En,created_by,created_time
|
||||||
|
]]>
|
||||||
|
</sql>
|
||||||
|
|
||||||
|
<select id="selectDic" resultMap="RM_Dictionary">
|
||||||
|
select <include refid="columnsdic"/> from dictionary
|
||||||
|
where dictionary in
|
||||||
|
(SELECT A.dictionary FROM dictionary a
|
||||||
|
join (select dictionary from dictionary
|
||||||
|
where 1=1
|
||||||
|
<if test="codingType!= null and codingType !=''">
|
||||||
|
AND coding_type = #{codingType}
|
||||||
|
</if>
|
||||||
|
<if test="codingType1!= null and codingType1 !=''">
|
||||||
|
AND dictionary = #{codingType1}
|
||||||
|
</if>
|
||||||
|
) b on a.coding_type=b.dictionary
|
||||||
|
<if test="codingType2!= null and codingType2 !=''">
|
||||||
|
AND a.dictionary = #{codingType2}
|
||||||
|
</if>
|
||||||
|
)
|
||||||
|
</select>
|
||||||
</mapper>
|
</mapper>
|
@ -5,25 +5,33 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||||||
<mapper namespace="com.ruoyi.system.mapper_yada.AustraliaMiddleEastMapper">
|
<mapper namespace="com.ruoyi.system.mapper_yada.AustraliaMiddleEastMapper">
|
||||||
<resultMap id="RM_AustraliaMiddleEast" type="com.ruoyi.system.domain_yada.AustraliaMiddleEastVO">
|
<resultMap id="RM_AustraliaMiddleEast" type="com.ruoyi.system.domain_yada.AustraliaMiddleEastVO">
|
||||||
|
|
||||||
<result property="yearMonth" column="year_month"/>
|
<result property="yearMonth" column="particular_month"/>
|
||||||
|
<result property="month" column="month"/>
|
||||||
<result property="id" column="ID"/>
|
<result property="id" column="ID"/>
|
||||||
<result property="sstAnomalyIndex" column="sst_anomaly_index"/>
|
<result property="sstAnomalyIndex" column="sst_anomaly_index"/>
|
||||||
<result property="temperatureAnomolies" column="temperature_anomolies"/>
|
<result property="temperatureAnomolies" column="temperature_anomolies"/>
|
||||||
<result property="precipitationAnomolies" column="precipitation_anomolies"/>
|
<result property="precipitationAnomolies" column="precipitation_anomolies"/>
|
||||||
<result property="vaiAnomolies" column="vai_anomolies"/>
|
<result property="vaiAnomolies" column="vai_anomolies"/>
|
||||||
<result property="createdBy" column="created_by"/>
|
<result property="createBy" column="created_by"/>
|
||||||
<result property="createdTime" column="created_time"/>
|
<result property="createTime" column="created_time"/>
|
||||||
|
|
||||||
</resultMap>
|
</resultMap>
|
||||||
|
|
||||||
<sql id="columns">
|
<sql id="columns">
|
||||||
<![CDATA[
|
<![CDATA[
|
||||||
ID,year_month,sst_anomaly_index,temperature_anomolies,precipitation_anomolies,vai_anomolies,created_by,created_time
|
ID,particular_month,sst_anomaly_index,temperature_anomolies,precipitation_anomolies,vai_anomolies,created_by,created_time,month
|
||||||
]]>
|
]]>
|
||||||
</sql>
|
</sql>
|
||||||
|
|
||||||
<select id="selectAustralia" resultMap="RM_AustraliaMiddleEast">
|
<select id="selectAustralia" resultMap="RM_AustraliaMiddleEast">
|
||||||
SELECT <include refid="columns"/> FROM central_and_eastern_australia;
|
SELECT <include refid="columns"/> FROM central_and_eastern_australia
|
||||||
|
WHERE 1=1
|
||||||
|
<if test="yearMonth!= null and yearMonth !=''">
|
||||||
|
AND particular_month = #{yearMonth}
|
||||||
|
</if>
|
||||||
|
<if test="month!= null and month !=''">
|
||||||
|
AND month = #{month}
|
||||||
|
</if>
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
<delete id="DelAustralia">
|
<delete id="DelAustralia">
|
||||||
@ -34,8 +42,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||||||
<insert id="IntoAustralia">
|
<insert id="IntoAustralia">
|
||||||
<![CDATA[
|
<![CDATA[
|
||||||
INSERT INTO central_and_eastern_australia (
|
INSERT INTO central_and_eastern_australia (
|
||||||
ID ,
|
particular_month ,
|
||||||
year_month ,
|
month,
|
||||||
sst_anomaly_index ,
|
sst_anomaly_index ,
|
||||||
temperature_anomolies ,
|
temperature_anomolies ,
|
||||||
precipitation_anomolies ,
|
precipitation_anomolies ,
|
||||||
@ -43,14 +51,14 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||||||
created_by ,
|
created_by ,
|
||||||
created_time
|
created_time
|
||||||
) VALUES (
|
) VALUES (
|
||||||
#{id,jdbcType=VARCHAR},
|
#{yearMonth,jdbcType=VARCHAR},
|
||||||
#{yearMonth,jdbcType=DATE},
|
#{month,jdbcType=VARCHAR},
|
||||||
#{sstAnomalyIndex,jdbcType=DOUBLE},
|
#{sstAnomalyIndex,jdbcType=DOUBLE},
|
||||||
#{temperatureAnomolies,jdbcType=DOUBLE},
|
#{temperatureAnomolies,jdbcType=DOUBLE},
|
||||||
#{precipitationAnomolies,jdbcType=DOUBLE},
|
#{precipitationAnomolies,jdbcType=DOUBLE},
|
||||||
#{vaiAnomolies,jdbcType=DOUBLE},
|
#{vaiAnomolies,jdbcType=DOUBLE},
|
||||||
#{createdBy,jdbcType=VARCHAR},
|
#{createBy,jdbcType=VARCHAR},
|
||||||
#{createdTime,jdbcType=DATE}
|
#{createTime,jdbcType=TIMESTAMP}
|
||||||
)
|
)
|
||||||
]]>
|
]]>
|
||||||
</insert>
|
</insert>
|
||||||
|
@ -21,9 +21,15 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||||||
id,particular_year,type_name,type_name_en,area_proportion,area,created_by,created_time
|
id,particular_year,type_name,type_name_en,area_proportion,area,created_by,created_time
|
||||||
]]>
|
]]>
|
||||||
</sql>
|
</sql>
|
||||||
|
|
||||||
<select id="selectGlobalType" resultMap="RM_GlobalType">
|
<select id="selectGlobalType" resultMap="RM_GlobalType">
|
||||||
SELECT <include refid="columns"/> FROM proportion_of_global_types;
|
SELECT <include refid="columns"/> FROM proportion_of_global_types
|
||||||
|
WHERE 1=1
|
||||||
|
<if test="particularYear!= null and particularYear !=''">
|
||||||
|
AND particular_year = #{particularYear}
|
||||||
|
</if>
|
||||||
|
<if test="typeName!= null and typeName !=''">
|
||||||
|
AND type_name = #{typeName}
|
||||||
|
</if>
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
<delete id="DelGlobalType">
|
<delete id="DelGlobalType">
|
||||||
|
@ -23,6 +23,11 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||||||
|
|
||||||
<select id="selectOcean" resultMap="RM_Ocean">
|
<select id="selectOcean" resultMap="RM_Ocean">
|
||||||
SELECT <include refid="columns"/> FROM sea_surface_temperature_anomaly
|
SELECT <include refid="columns"/> FROM sea_surface_temperature_anomaly
|
||||||
|
WHERE 1=1
|
||||||
|
<if test="startDate!= null and startDate !=''">
|
||||||
|
AND startDate > #{startDate}
|
||||||
|
</if>
|
||||||
|
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
<delete id="DelOcean">
|
<delete id="DelOcean">
|
||||||
|
@ -25,7 +25,16 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||||||
</sql>
|
</sql>
|
||||||
|
|
||||||
<select id="selectRegion" resultMap="RM_RegionVGI">
|
<select id="selectRegion" resultMap="RM_RegionVGI">
|
||||||
SELECT <include refid="columns"/> FROM region_vgi;
|
SELECT <include refid="columns"/> FROM region_vgi
|
||||||
|
where particular_year='2020.0'
|
||||||
|
|
||||||
|
<!-- WHERE 1=1-->
|
||||||
|
<!-- <if test="particularYear!= null and particularYear !=''">-->
|
||||||
|
<!-- AND particular_year = #{particularYear}-->
|
||||||
|
<!-- </if>-->
|
||||||
|
<!-- <if test="typeName!= null and typeName !=''">-->
|
||||||
|
<!-- AND type_name = #{typeName}-->
|
||||||
|
<!-- </if>-->
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
<delete id="DelRegion">
|
<delete id="DelRegion">
|
||||||
@ -50,9 +59,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||||||
) VALUES (
|
) VALUES (
|
||||||
#{id,jdbcType=VARCHAR},
|
#{id,jdbcType=VARCHAR},
|
||||||
#{region,jdbcType=VARCHAR},
|
#{region,jdbcType=VARCHAR},
|
||||||
#{region_en,jdbcType=VARCHAR},
|
#{regionEn,jdbcType=VARCHAR},
|
||||||
#{type_name,jdbcType=VARCHAR},
|
#{typeName,jdbcType=VARCHAR},
|
||||||
#{type_name_en,jdbcType=TIMESTAMP},
|
#{typeNameEn,jdbcType=TIMESTAMP},
|
||||||
#{forest,jdbcType=DOUBLE},
|
#{forest,jdbcType=DOUBLE},
|
||||||
#{createdBy,jdbcType=VARCHAR},
|
#{createdBy,jdbcType=VARCHAR},
|
||||||
#{createdTime,jdbcType=DATE},
|
#{createdTime,jdbcType=DATE},
|
||||||
|
@ -19,12 +19,16 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||||||
|
|
||||||
<sql id="columns">
|
<sql id="columns">
|
||||||
<![CDATA[
|
<![CDATA[
|
||||||
id,region,region_en,type_conversion,type_conversion_en,proportion_of_changed_areas,particular_year,createBy,createTime
|
id,region,region_en,type_conversion,type_conversion_en,proportion_of_changed_areas,particular_year,created_by,created_time
|
||||||
]]>
|
]]>
|
||||||
</sql>
|
</sql>
|
||||||
|
|
||||||
<select id="selectRegional" resultMap="RM_Regional">
|
<select id="selectRegional" resultMap="RM_Regional">
|
||||||
SELECT <include refid="columns"/> FROM proportion_of_ecosystem_type_transfer
|
SELECT <include refid="columns"/> FROM proportion_of_ecosystem_type_transfer
|
||||||
|
WHERE 1=1
|
||||||
|
<if test="region!= null and region !=''">
|
||||||
|
AND region = #{region}
|
||||||
|
</if>
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
<delete id="DelRegional">
|
<delete id="DelRegional">
|
||||||
@ -35,7 +39,6 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||||||
<insert id="IntoRegional">
|
<insert id="IntoRegional">
|
||||||
<![CDATA[
|
<![CDATA[
|
||||||
INSERT INTO proportion_of_ecosystem_type_transfer (
|
INSERT INTO proportion_of_ecosystem_type_transfer (
|
||||||
id ,
|
|
||||||
region ,
|
region ,
|
||||||
region_en ,
|
region_en ,
|
||||||
type_conversion ,
|
type_conversion ,
|
||||||
@ -45,7 +48,6 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||||||
created_by ,
|
created_by ,
|
||||||
created_time
|
created_time
|
||||||
) VALUES (
|
) VALUES (
|
||||||
#{id,jdbcType=VARCHAR},
|
|
||||||
#{region,jdbcType=VARCHAR},
|
#{region,jdbcType=VARCHAR},
|
||||||
#{regionEn,jdbcType=VARCHAR},
|
#{regionEn,jdbcType=VARCHAR},
|
||||||
#{typeConversion,jdbcType=VARCHAR},
|
#{typeConversion,jdbcType=VARCHAR},
|
||||||
@ -53,7 +55,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||||||
#{proportionOfChangedAreas,jdbcType=DOUBLE},
|
#{proportionOfChangedAreas,jdbcType=DOUBLE},
|
||||||
#{particularYear,jdbcType=VARCHAR},
|
#{particularYear,jdbcType=VARCHAR},
|
||||||
#{createBy,jdbcType=VARCHAR},
|
#{createBy,jdbcType=VARCHAR},
|
||||||
#{createTime,jdbcType=DATE}
|
#{createTime,jdbcType=TIMESTAMP}
|
||||||
)
|
)
|
||||||
]]>
|
]]>
|
||||||
</insert>
|
</insert>
|
||||||
|
@ -80,7 +80,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||||||
<if test="configType != null and configType != ''">#{configType},</if>
|
<if test="configType != null and configType != ''">#{configType},</if>
|
||||||
<if test="createBy != null and createBy != ''">#{createBy},</if>
|
<if test="createBy != null and createBy != ''">#{createBy},</if>
|
||||||
<if test="remark != null and remark != ''">#{remark},</if>
|
<if test="remark != null and remark != ''">#{remark},</if>
|
||||||
sysdate()
|
current_timestamp
|
||||||
)
|
)
|
||||||
</insert>
|
</insert>
|
||||||
|
|
||||||
@ -93,7 +93,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||||||
<if test="configType != null and configType != ''">config_type = #{configType},</if>
|
<if test="configType != null and configType != ''">config_type = #{configType},</if>
|
||||||
<if test="updateBy != null and updateBy != ''">update_by = #{updateBy},</if>
|
<if test="updateBy != null and updateBy != ''">update_by = #{updateBy},</if>
|
||||||
<if test="remark != null">remark = #{remark},</if>
|
<if test="remark != null">remark = #{remark},</if>
|
||||||
update_time = sysdate()
|
update_time = current_timestamp
|
||||||
</set>
|
</set>
|
||||||
where config_id = #{configId}
|
where config_id = #{configId}
|
||||||
</update>
|
</update>
|
||||||
|
@ -109,7 +109,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||||||
<if test="email != null and email != ''">#{email},</if>
|
<if test="email != null and email != ''">#{email},</if>
|
||||||
<if test="status != null">#{status},</if>
|
<if test="status != null">#{status},</if>
|
||||||
<if test="createBy != null and createBy != ''">#{createBy},</if>
|
<if test="createBy != null and createBy != ''">#{createBy},</if>
|
||||||
sysdate()
|
current_timestamp
|
||||||
)
|
)
|
||||||
</insert>
|
</insert>
|
||||||
|
|
||||||
@ -125,7 +125,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||||||
<if test="email != null">email = #{email},</if>
|
<if test="email != null">email = #{email},</if>
|
||||||
<if test="status != null and status != ''">status = #{status},</if>
|
<if test="status != null and status != ''">status = #{status},</if>
|
||||||
<if test="updateBy != null and updateBy != ''">update_by = #{updateBy},</if>
|
<if test="updateBy != null and updateBy != ''">update_by = #{updateBy},</if>
|
||||||
update_time = sysdate()
|
update_time = current_timestamp
|
||||||
</set>
|
</set>
|
||||||
where dept_id = #{deptId}
|
where dept_id = #{deptId}
|
||||||
</update>
|
</update>
|
||||||
|
@ -84,7 +84,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||||||
<if test="status != null">status = #{status},</if>
|
<if test="status != null">status = #{status},</if>
|
||||||
<if test="remark != null">remark = #{remark},</if>
|
<if test="remark != null">remark = #{remark},</if>
|
||||||
<if test="updateBy != null and updateBy != ''">update_by = #{updateBy},</if>
|
<if test="updateBy != null and updateBy != ''">update_by = #{updateBy},</if>
|
||||||
update_time = sysdate()
|
update_time = current_timestamp
|
||||||
</set>
|
</set>
|
||||||
where dict_code = #{dictCode}
|
where dict_code = #{dictCode}
|
||||||
</update>
|
</update>
|
||||||
@ -117,7 +117,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||||||
<if test="status != null">#{status},</if>
|
<if test="status != null">#{status},</if>
|
||||||
<if test="remark != null and remark != ''">#{remark},</if>
|
<if test="remark != null and remark != ''">#{remark},</if>
|
||||||
<if test="createBy != null and createBy != ''">#{createBy},</if>
|
<if test="createBy != null and createBy != ''">#{createBy},</if>
|
||||||
sysdate()
|
current_timestamp
|
||||||
)
|
)
|
||||||
</insert>
|
</insert>
|
||||||
|
|
||||||
|
@ -79,7 +79,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||||||
<if test="status != null">status = #{status},</if>
|
<if test="status != null">status = #{status},</if>
|
||||||
<if test="remark != null">remark = #{remark},</if>
|
<if test="remark != null">remark = #{remark},</if>
|
||||||
<if test="updateBy != null and updateBy != ''">update_by = #{updateBy},</if>
|
<if test="updateBy != null and updateBy != ''">update_by = #{updateBy},</if>
|
||||||
update_time = sysdate()
|
update_time = current_timestamp
|
||||||
</set>
|
</set>
|
||||||
where dict_id = #{dictId}
|
where dict_id = #{dictId}
|
||||||
</update>
|
</update>
|
||||||
@ -98,7 +98,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||||||
<if test="status != null">#{status},</if>
|
<if test="status != null">#{status},</if>
|
||||||
<if test="remark != null and remark != ''">#{remark},</if>
|
<if test="remark != null and remark != ''">#{remark},</if>
|
||||||
<if test="createBy != null and createBy != ''">#{createBy},</if>
|
<if test="createBy != null and createBy != ''">#{createBy},</if>
|
||||||
sysdate()
|
current_timestamp
|
||||||
)
|
)
|
||||||
</insert>
|
</insert>
|
||||||
|
|
||||||
|
@ -18,7 +18,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||||||
|
|
||||||
<insert id="insertLogininfor" parameterType="SysLogininfor">
|
<insert id="insertLogininfor" parameterType="SysLogininfor">
|
||||||
insert into sys_logininfor (user_name, status, ipaddr, login_location, browser, os, msg, login_time)
|
insert into sys_logininfor (user_name, status, ipaddr, login_location, browser, os, msg, login_time)
|
||||||
values (#{userName}, #{status}, #{ipaddr}, #{loginLocation}, #{browser}, #{os}, #{msg}, sysdate())
|
values (#{userName}, #{status}, #{ipaddr}, #{loginLocation}, #{browser}, #{os}, #{msg}, current_timestamp)
|
||||||
</insert>
|
</insert>
|
||||||
|
|
||||||
<select id="selectLogininforList" parameterType="SysLogininfor" resultMap="SysLogininforResult">
|
<select id="selectLogininforList" parameterType="SysLogininfor" resultMap="SysLogininforResult">
|
||||||
|
@ -28,7 +28,7 @@
|
|||||||
</resultMap>
|
</resultMap>
|
||||||
|
|
||||||
<sql id="selectMenuVo">
|
<sql id="selectMenuVo">
|
||||||
select menu_id, menu_name, parent_id, order_num, path, component, `query`, is_frame, is_cache, menu_type, visible, status, ifnull(perms,'') as perms, icon, create_time
|
select menu_id, menu_name, parent_id, order_num, path, component, `query`, is_frame, is_cache, menu_type, visible, status, nullif(perms,'') as perms, icon, create_time
|
||||||
from sys_menu
|
from sys_menu
|
||||||
</sql>
|
</sql>
|
||||||
|
|
||||||
@ -49,13 +49,13 @@
|
|||||||
</select>
|
</select>
|
||||||
|
|
||||||
<select id="selectMenuTreeAll" resultMap="SysMenuResult">
|
<select id="selectMenuTreeAll" resultMap="SysMenuResult">
|
||||||
select distinct m.menu_id, m.parent_id, m.menu_name, m.path, m.component, m.`query`, m.visible, m.status, ifnull(m.perms,'') as perms, m.is_frame, m.is_cache, m.menu_type, m.icon, m.order_num, m.create_time
|
select distinct m.menu_id, m.parent_id, m.menu_name, m.path, m.component, m.query, m.visible, m.status, nullif(m.perms,'') as perms, m.is_frame, m.is_cache, m.menu_type, m.icon, m.order_num, m.create_time
|
||||||
from sys_menu m where m.menu_type in ('M', 'C') and m.status = 0
|
from sys_menu m where m.menu_type in ('M', 'C') and m.status = 0
|
||||||
order by m.parent_id, m.order_num
|
order by m.parent_id, m.order_num
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
<select id="selectMenuListByUserId" parameterType="SysMenu" resultMap="SysMenuResult">
|
<select id="selectMenuListByUserId" parameterType="SysMenu" resultMap="SysMenuResult">
|
||||||
select distinct m.menu_id, m.parent_id, m.menu_name, m.path, m.component, m.`query`, m.visible, m.status, ifnull(m.perms,'') as perms, m.is_frame, m.is_cache, m.menu_type, m.icon, m.order_num, m.create_time
|
select distinct m.menu_id, m.parent_id, m.menu_name, m.path, m.component, m.query, m.visible, m.status, nullif (m.perms,'') as perms, m.is_frame, m.is_cache, m.menu_type, m.icon, m.order_num, m.create_time
|
||||||
from sys_menu m
|
from sys_menu m
|
||||||
left join sys_role_menu rm on m.menu_id = rm.menu_id
|
left join sys_role_menu rm on m.menu_id = rm.menu_id
|
||||||
left join sys_user_role ur on rm.role_id = ur.role_id
|
left join sys_user_role ur on rm.role_id = ur.role_id
|
||||||
@ -74,7 +74,7 @@
|
|||||||
</select>
|
</select>
|
||||||
|
|
||||||
<select id="selectMenuTreeByUserId" parameterType="Long" resultMap="SysMenuResult">
|
<select id="selectMenuTreeByUserId" parameterType="Long" resultMap="SysMenuResult">
|
||||||
select distinct m.menu_id, m.parent_id, m.menu_name, m.path, m.component, m.`query`, m.visible, m.status, ifnull(m.perms,'') as perms, m.is_frame, m.is_cache, m.menu_type, m.icon, m.order_num, m.create_time
|
select distinct m.menu_id, m.parent_id, m.menu_name, m.path, m.component, m.query, m.visible, m.status, nullif(m.perms,'') as perms, m.is_frame, m.is_cache, m.menu_type, m.icon, m.order_num, m.create_time
|
||||||
from sys_menu m
|
from sys_menu m
|
||||||
left join sys_role_menu rm on m.menu_id = rm.menu_id
|
left join sys_role_menu rm on m.menu_id = rm.menu_id
|
||||||
left join sys_user_role ur on rm.role_id = ur.role_id
|
left join sys_user_role ur on rm.role_id = ur.role_id
|
||||||
@ -143,7 +143,7 @@
|
|||||||
<if test="icon !=null and icon != ''">icon = #{icon},</if>
|
<if test="icon !=null and icon != ''">icon = #{icon},</if>
|
||||||
<if test="remark != null and remark != ''">remark = #{remark},</if>
|
<if test="remark != null and remark != ''">remark = #{remark},</if>
|
||||||
<if test="updateBy != null and updateBy != ''">update_by = #{updateBy},</if>
|
<if test="updateBy != null and updateBy != ''">update_by = #{updateBy},</if>
|
||||||
update_time = sysdate()
|
update_time = current_timestamp
|
||||||
</set>
|
</set>
|
||||||
where menu_id = #{menuId}
|
where menu_id = #{menuId}
|
||||||
</update>
|
</update>
|
||||||
@ -184,7 +184,7 @@
|
|||||||
<if test="icon != null and icon != ''">#{icon},</if>
|
<if test="icon != null and icon != ''">#{icon},</if>
|
||||||
<if test="remark != null and remark != ''">#{remark},</if>
|
<if test="remark != null and remark != ''">#{remark},</if>
|
||||||
<if test="createBy != null and createBy != ''">#{createBy},</if>
|
<if test="createBy != null and createBy != ''">#{createBy},</if>
|
||||||
sysdate()
|
current_timestamp
|
||||||
)
|
)
|
||||||
</insert>
|
</insert>
|
||||||
|
|
||||||
|
@ -58,7 +58,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||||||
<if test="status != null and status != ''">#{status}, </if>
|
<if test="status != null and status != ''">#{status}, </if>
|
||||||
<if test="remark != null and remark != ''">#{remark},</if>
|
<if test="remark != null and remark != ''">#{remark},</if>
|
||||||
<if test="createBy != null and createBy != ''">#{createBy},</if>
|
<if test="createBy != null and createBy != ''">#{createBy},</if>
|
||||||
sysdate()
|
current_timestamp
|
||||||
)
|
)
|
||||||
</insert>
|
</insert>
|
||||||
|
|
||||||
@ -70,7 +70,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||||||
<if test="noticeContent != null">notice_content = #{noticeContent}, </if>
|
<if test="noticeContent != null">notice_content = #{noticeContent}, </if>
|
||||||
<if test="status != null and status != ''">status = #{status}, </if>
|
<if test="status != null and status != ''">status = #{status}, </if>
|
||||||
<if test="updateBy != null and updateBy != ''">update_by = #{updateBy},</if>
|
<if test="updateBy != null and updateBy != ''">update_by = #{updateBy},</if>
|
||||||
update_time = sysdate()
|
update_time = current_timestamp
|
||||||
</set>
|
</set>
|
||||||
where notice_id = #{noticeId}
|
where notice_id = #{noticeId}
|
||||||
</update>
|
</update>
|
||||||
|
@ -30,7 +30,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||||||
|
|
||||||
<insert id="insertOperlog" parameterType="SysOperLog">
|
<insert id="insertOperlog" parameterType="SysOperLog">
|
||||||
insert into sys_oper_log(title, business_type, method, request_method, operator_type, oper_name, dept_name, oper_url, oper_ip, oper_location, oper_param, json_result, status, error_msg, oper_time)
|
insert into sys_oper_log(title, business_type, method, request_method, operator_type, oper_name, dept_name, oper_url, oper_ip, oper_location, oper_param, json_result, status, error_msg, oper_time)
|
||||||
values (#{title}, #{businessType}, #{method}, #{requestMethod}, #{operatorType}, #{operName}, #{deptName}, #{operUrl}, #{operIp}, #{operLocation}, #{operParam}, #{jsonResult}, #{status}, #{errorMsg}, sysdate())
|
values (#{title}, #{businessType}, #{method}, #{requestMethod}, #{operatorType}, #{operName}, #{deptName}, #{operUrl}, #{operIp}, #{operLocation}, #{operParam}, #{jsonResult}, #{status}, #{errorMsg}, current_timestamp)
|
||||||
</insert>
|
</insert>
|
||||||
|
|
||||||
<select id="selectOperLogList" parameterType="SysOperLog" resultMap="SysOperLogResult">
|
<select id="selectOperLogList" parameterType="SysOperLog" resultMap="SysOperLogResult">
|
||||||
|
@ -81,7 +81,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||||||
<if test="status != null and status != ''">status = #{status},</if>
|
<if test="status != null and status != ''">status = #{status},</if>
|
||||||
<if test="remark != null">remark = #{remark},</if>
|
<if test="remark != null">remark = #{remark},</if>
|
||||||
<if test="updateBy != null and updateBy != ''">update_by = #{updateBy},</if>
|
<if test="updateBy != null and updateBy != ''">update_by = #{updateBy},</if>
|
||||||
update_time = sysdate()
|
update_time = current_timestamp
|
||||||
</set>
|
</set>
|
||||||
where post_id = #{postId}
|
where post_id = #{postId}
|
||||||
</update>
|
</update>
|
||||||
@ -104,7 +104,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||||||
<if test="status != null and status != ''">#{status},</if>
|
<if test="status != null and status != ''">#{status},</if>
|
||||||
<if test="remark != null and remark != ''">#{remark},</if>
|
<if test="remark != null and remark != ''">#{remark},</if>
|
||||||
<if test="createBy != null and createBy != ''">#{createBy},</if>
|
<if test="createBy != null and createBy != ''">#{createBy},</if>
|
||||||
sysdate()
|
current_timestamp
|
||||||
)
|
)
|
||||||
</insert>
|
</insert>
|
||||||
|
|
||||||
|
@ -117,7 +117,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||||||
<if test="status != null and status != ''">#{status},</if>
|
<if test="status != null and status != ''">#{status},</if>
|
||||||
<if test="remark != null and remark != ''">#{remark},</if>
|
<if test="remark != null and remark != ''">#{remark},</if>
|
||||||
<if test="createBy != null and createBy != ''">#{createBy},</if>
|
<if test="createBy != null and createBy != ''">#{createBy},</if>
|
||||||
sysdate()
|
current_timestamp
|
||||||
)
|
)
|
||||||
</insert>
|
</insert>
|
||||||
|
|
||||||
@ -133,7 +133,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||||||
<if test="status != null and status != ''">status = #{status},</if>
|
<if test="status != null and status != ''">status = #{status},</if>
|
||||||
<if test="remark != null">remark = #{remark},</if>
|
<if test="remark != null">remark = #{remark},</if>
|
||||||
<if test="updateBy != null and updateBy != ''">update_by = #{updateBy},</if>
|
<if test="updateBy != null and updateBy != ''">update_by = #{updateBy},</if>
|
||||||
update_time = sysdate()
|
update_time = current_timestamp
|
||||||
</set>
|
</set>
|
||||||
where role_id = #{roleId}
|
where role_id = #{roleId}
|
||||||
</update>
|
</update>
|
||||||
|
@ -170,7 +170,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||||||
<if test="status != null and status != ''">#{status},</if>
|
<if test="status != null and status != ''">#{status},</if>
|
||||||
<if test="createBy != null and createBy != ''">#{createBy},</if>
|
<if test="createBy != null and createBy != ''">#{createBy},</if>
|
||||||
<if test="remark != null and remark != ''">#{remark},</if>
|
<if test="remark != null and remark != ''">#{remark},</if>
|
||||||
sysdate()
|
current_timestamp
|
||||||
)
|
)
|
||||||
</insert>
|
</insert>
|
||||||
|
|
||||||
@ -190,7 +190,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||||||
<if test="loginDate != null">login_date = #{loginDate},</if>
|
<if test="loginDate != null">login_date = #{loginDate},</if>
|
||||||
<if test="updateBy != null and updateBy != ''">update_by = #{updateBy},</if>
|
<if test="updateBy != null and updateBy != ''">update_by = #{updateBy},</if>
|
||||||
<if test="remark != null">remark = #{remark},</if>
|
<if test="remark != null">remark = #{remark},</if>
|
||||||
update_time = sysdate()
|
update_time = current_timestamp
|
||||||
</set>
|
</set>
|
||||||
where user_id = #{userId}
|
where user_id = #{userId}
|
||||||
</update>
|
</update>
|
||||||
|
@ -6,12 +6,14 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||||||
<resultMap id="RM_ThematicMap" type="com.ruoyi.system.domain_yada.ThematicMapDomain">
|
<resultMap id="RM_ThematicMap" type="com.ruoyi.system.domain_yada.ThematicMapDomain">
|
||||||
<result property="id" column="id"/>
|
<result property="id" column="id"/>
|
||||||
<result property="pictureZh" column="picture_zh"/>
|
<result property="pictureZh" column="picture_zh"/>
|
||||||
|
<result property="pictureCode" column="picture_code"/>
|
||||||
|
<result property="pictureTypeOne" column="picture_type_one"/>
|
||||||
|
<result property="pictureTypeTwo" column="picture_type_two"/>
|
||||||
<result property="pictureEn" column="picture_en"/>
|
<result property="pictureEn" column="picture_en"/>
|
||||||
<result property="pictureName" column="picture_name"/>
|
<result property="pictureName" column="picture_name"/>
|
||||||
<result property="pictureType" column="picture_type"/>
|
<result property="pictureType" column="picture_type"/>
|
||||||
<result property="pictureTime" column="picture_time"/>
|
<result property="pictureTime" column="picture_time"/>
|
||||||
<result property="picturePath" column="picture_path"/>
|
<result property="picturePath" column="picture_path"/>
|
||||||
<result property="pictureTime" column="picture_time"/>
|
|
||||||
<result property="remarks" column="remarks"/>
|
<result property="remarks" column="remarks"/>
|
||||||
<result property="createdBy" column="created_by"/>
|
<result property="createdBy" column="created_by"/>
|
||||||
<result property="createdTime" column="created_time"/>
|
<result property="createdTime" column="created_time"/>
|
||||||
@ -19,12 +21,22 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||||||
|
|
||||||
<sql id="columns">
|
<sql id="columns">
|
||||||
<![CDATA[
|
<![CDATA[
|
||||||
id,picture_zh,picture_en,picture_name,picture_type,picture_time,picture_path,picture_time,remarks,created_by,created_time
|
id,picture_zh,picture_code,picture_type_one,picture_type_two,picture_en,picture_name,picture_type,picture_time,picture_path,picture_time,remarks,created_by,created_time
|
||||||
]]>
|
]]>
|
||||||
</sql>
|
</sql>
|
||||||
|
|
||||||
<select id="selectAllThematicMap" resultMap="RM_ThematicMap">
|
<select id="selectAllThematicMap" resultMap="RM_ThematicMap">
|
||||||
SELECT <include refid="columns"/> FROM thematic_map;
|
SELECT <include refid="columns"/> FROM thematic_map
|
||||||
|
WHERE 1=1
|
||||||
|
<if test="pictureType!= null and pictureType !=''">
|
||||||
|
AND picture_type = #{pictureType}
|
||||||
|
</if>
|
||||||
|
<if test="pictureTypeOne!= null and pictureTypeOne !=''">
|
||||||
|
AND picture_type_one = #{pictureTypeOne}
|
||||||
|
</if>
|
||||||
|
<if test="pictureTypeTwo!= null and pictureTypeTwo !=''">
|
||||||
|
AND picture_type_two = #{pictureTypeTwo}
|
||||||
|
</if>
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
<delete id="deleteThematicMap">
|
<delete id="deleteThematicMap">
|
||||||
@ -40,6 +52,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||||||
picture_en ,
|
picture_en ,
|
||||||
picture_name ,
|
picture_name ,
|
||||||
picture_type ,
|
picture_type ,
|
||||||
|
picture_type_one,
|
||||||
|
picture_type_two,
|
||||||
|
picture_code,
|
||||||
picture_time ,
|
picture_time ,
|
||||||
picture_path,
|
picture_path,
|
||||||
remarks,
|
remarks,
|
||||||
@ -51,6 +66,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||||||
#{pictureEn,jdbcType=VARCHAR}},
|
#{pictureEn,jdbcType=VARCHAR}},
|
||||||
#{pictureName,jdbcType=VARCHAR}},
|
#{pictureName,jdbcType=VARCHAR}},
|
||||||
#{pictureType,jdbcType=VARCHAR}},
|
#{pictureType,jdbcType=VARCHAR}},
|
||||||
|
#{pictureTypeOne,jdbcType=VARCHAR}},
|
||||||
|
#{pictureTypeTwo,jdbcType=VARCHAR}},
|
||||||
|
#{pictureCode,jdbcType=VARCHAR}},
|
||||||
#{pictureTime,jdbcType=TIMESTAMP},
|
#{pictureTime,jdbcType=TIMESTAMP},
|
||||||
#{picturePath,jdbcType=VARCHAR},
|
#{picturePath,jdbcType=VARCHAR},
|
||||||
#{remarks,jdbcType=VARCHAR},
|
#{remarks,jdbcType=VARCHAR},
|
||||||
|
@ -23,6 +23,13 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||||||
|
|
||||||
<select id="selectUrban" resultMap="RM_Urban">
|
<select id="selectUrban" resultMap="RM_Urban">
|
||||||
SELECT <include refid="columns"/> FROM urban_agglomeration_china
|
SELECT <include refid="columns"/> FROM urban_agglomeration_china
|
||||||
|
WHERE 1=1
|
||||||
|
<if test="particularYear!= null and particularYear !=''">
|
||||||
|
AND particular_year = #{particularYear}
|
||||||
|
</if>
|
||||||
|
<if test="name!= null and name !=''">
|
||||||
|
AND name = #{name}
|
||||||
|
</if>
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
<delete id="DelUrban">
|
<delete id="DelUrban">
|
||||||
|
@ -25,6 +25,13 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||||||
|
|
||||||
<select id="selectVegetation" resultMap="RM_Vegetation">
|
<select id="selectVegetation" resultMap="RM_Vegetation">
|
||||||
SELECT <include refid="columns"/> FROM fvc_npp
|
SELECT <include refid="columns"/> FROM fvc_npp
|
||||||
|
<!-- WHERE 1=1-->
|
||||||
|
<!-- <if test="particularYear!= null and particularYear !=''">-->
|
||||||
|
<!-- AND particular_year = #{particularYear}-->
|
||||||
|
<!-- </if>-->
|
||||||
|
<!-- <if test="region != null and region !=''">-->
|
||||||
|
<!-- AND region = #{region}-->
|
||||||
|
<!-- </if>-->
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
<delete id="DelVegetation">
|
<delete id="DelVegetation">
|
||||||
@ -35,7 +42,6 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||||||
<insert id="IntoVegetation">
|
<insert id="IntoVegetation">
|
||||||
<![CDATA[
|
<![CDATA[
|
||||||
INSERT INTO fvc_npp (
|
INSERT INTO fvc_npp (
|
||||||
id ,
|
|
||||||
particular_year ,
|
particular_year ,
|
||||||
region ,
|
region ,
|
||||||
region_en ,
|
region_en ,
|
||||||
@ -46,12 +52,11 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||||||
created_by ,
|
created_by ,
|
||||||
created_time
|
created_time
|
||||||
) VALUES (
|
) VALUES (
|
||||||
#{id,jdbcType=VARCHAR},
|
|
||||||
#{particularYear,jdbcType=VARCHAR},
|
#{particularYear,jdbcType=VARCHAR},
|
||||||
#{region,jdbcType=VARCHAR},
|
#{region,jdbcType=VARCHAR},
|
||||||
#{regionEn,jdbcType=VARCHAR},
|
#{regionEn,jdbcType=VARCHAR},
|
||||||
#{protectedLands,jdbcType=DOUBLE},
|
#{protectedLands,jdbcType=DOUBLE},
|
||||||
#{nonProtectedLand,jdbcType=DOUBLE},
|
#{nonProtectedLands,jdbcType=DOUBLE},
|
||||||
#{mountain,jdbcType=DOUBLE},
|
#{mountain,jdbcType=DOUBLE},
|
||||||
#{nonMountain,jdbcType=DOUBLE},
|
#{nonMountain,jdbcType=DOUBLE},
|
||||||
#{createBy,jdbcType=VARCHAR},
|
#{createBy,jdbcType=VARCHAR},
|
||||||
|
@ -8,7 +8,8 @@ export default {
|
|||||||
components: { iFrame },
|
components: { iFrame },
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
url: process.env.VUE_APP_BASE_API + "/swagger-ui/index.html"
|
// url: process.env.VUE_APP_BASE_API + "/swagger-ui/index.html"
|
||||||
|
url: process.env.VUE_APP_BASE_API + "/doc.html"
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
|
Reference in New Issue
Block a user