添加swagger 新界面
This commit is contained in:
parent
5c0a93f679
commit
498a502c02
@ -34,7 +34,13 @@
|
|||||||
<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>
|
</dependency>
|
||||||
|
|
||||||
<!-- Mysql驱动包 -->
|
<!-- Mysql驱动包 -->
|
||||||
|
@ -3,6 +3,7 @@ package com.ruoyi.web.controller.yada;
|
|||||||
import com.ruoyi.common.core.domain.AjaxResult;
|
import com.ruoyi.common.core.domain.AjaxResult;
|
||||||
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.RequestBody;
|
||||||
import org.springframework.web.bind.annotation.RequestMapping;
|
import org.springframework.web.bind.annotation.RequestMapping;
|
||||||
@ -16,10 +17,12 @@ import java.time.LocalDateTime;
|
|||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 中国城市监测
|
* 专题图模块
|
||||||
|
* @author taco chen
|
||||||
*/
|
*/
|
||||||
@RestController
|
@RestController
|
||||||
@RequestMapping(value = "/thematic-map")
|
@RequestMapping(value = "/thematic-map")
|
||||||
|
@Api(tags = "专题图模块")
|
||||||
public class ThematicMapController {
|
public class ThematicMapController {
|
||||||
|
|
||||||
@Resource
|
@Resource
|
||||||
@ -31,6 +34,14 @@ public class ThematicMapController {
|
|||||||
* @param request 客户端请求
|
* @param request 客户端请求
|
||||||
* @return 参数类
|
* @return 参数类
|
||||||
*/
|
*/
|
||||||
|
@ApiOperation("获取所有专题图")
|
||||||
|
@ApiImplicitParams({})
|
||||||
|
@ApiResponses({
|
||||||
|
@ApiResponse(code =200,message = "请求成功"),
|
||||||
|
@ApiResponse(code =401,message = "没有认证"),
|
||||||
|
@ApiResponse(code =403,message = "权限不足"),
|
||||||
|
@ApiResponse(code =404,message = "未找到")
|
||||||
|
})
|
||||||
@RequestMapping(value = "/get/all",method = {RequestMethod.GET})
|
@RequestMapping(value = "/get/all",method = {RequestMethod.GET})
|
||||||
public AjaxResult selectAllThematicMap(HttpServletResponse response, HttpServletRequest request)
|
public AjaxResult selectAllThematicMap(HttpServletResponse response, HttpServletRequest request)
|
||||||
{
|
{
|
||||||
|
@ -1,15 +1,16 @@
|
|||||||
<template>
|
<template>
|
||||||
<i-frame :src="url" />
|
<i-frame :src="url" />
|
||||||
</template>
|
</template>
|
||||||
<script>
|
<script>
|
||||||
import iFrame from "@/components/iFrame/index";
|
import iFrame from "@/components/iFrame/index";
|
||||||
export default {
|
export default {
|
||||||
name: "Swagger",
|
name: "Swagger",
|
||||||
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"
|
||||||
},
|
};
|
||||||
};
|
},
|
||||||
</script>
|
};
|
||||||
|
</script>
|
||||||
|
Loading…
Reference in New Issue
Block a user