给监测类数据api文档增加分组

master
李一帆 2024-01-29 15:36:02 +08:00
parent c92bc1eeee
commit 5a7b960c16
6 changed files with 42 additions and 12 deletions

View File

@ -0,0 +1,28 @@
package com.gunshi.project.xyt.config;
import org.springdoc.core.models.GroupedOpenApi;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
/**
*
*
* @author lyf
* @version 1.0.0
* @since 2024-01-29
*/
@Configuration
public class RcvOpenApiConfig {
@Bean
public GroupedOpenApi XytRcvOpenApi() {
String[] packagesToScan = {
"com.gunshi.project.xyt.controller",
};
return GroupedOpenApi.builder()
.group("xyt-rcv")
.displayName("监测数据类接口")
.pathsToMatch("/rcv/**")
.packagesToScan(packagesToScan)
.build();
}
}

View File

@ -8,7 +8,7 @@ import com.gunshi.project.xyt.model.StFlowRAutoDao;
import com.gunshi.project.xyt.model.StStbprpB;
import com.gunshi.project.xyt.model.StStbprpBAutoMapper;
import com.gunshi.project.xyt.so.RtuDataSo;
import io.swagger.v3.oas.annotations.media.Schema;
import io.swagger.v3.oas.annotations.Operation;
import io.swagger.v3.oas.annotations.tags.Tag;
import org.apache.commons.lang3.StringUtils;
import org.springframework.beans.factory.annotation.Autowired;
@ -35,7 +35,7 @@ public class StFlowRController {
@Autowired
private StStbprpBAutoMapper stbprpDao;
@Schema(description = "分页查询")
@Operation(summary = "分页查询")
@PostMapping("/page/{chid}")
public R<Page<StFlowR>> page(@RequestBody RtuDataSo so, @PathVariable("chid") String chid) {
List<String> stcds = new ArrayList<>();

View File

@ -8,7 +8,7 @@ import com.gunshi.project.xyt.model.StImgRAutoDao;
import com.gunshi.project.xyt.model.StStbprpB;
import com.gunshi.project.xyt.model.StStbprpBAutoMapper;
import com.gunshi.project.xyt.so.RtuDataSo;
import io.swagger.v3.oas.annotations.media.Schema;
import io.swagger.v3.oas.annotations.Operation;
import io.swagger.v3.oas.annotations.tags.Tag;
import org.apache.commons.lang3.StringUtils;
import org.springframework.beans.factory.annotation.Autowired;
@ -35,7 +35,7 @@ public class StImgRController {
@Autowired
private StStbprpBAutoMapper stbprpDao;
@Schema(description = "分页查询")
@Operation(summary = "分页查询")
@PostMapping("/page/{chid}")
public R<Page<StImgR>> page(@RequestBody RtuDataSo so, @PathVariable("chid") String chid) {
List<String> stcds = new ArrayList<>();

View File

@ -8,7 +8,7 @@ import com.gunshi.project.xyt.model.StPptnRAutoDao;
import com.gunshi.project.xyt.model.StStbprpB;
import com.gunshi.project.xyt.model.StStbprpBAutoMapper;
import com.gunshi.project.xyt.so.RtuDataSo;
import io.swagger.v3.oas.annotations.media.Schema;
import io.swagger.v3.oas.annotations.Operation;
import io.swagger.v3.oas.annotations.tags.Tag;
import org.apache.commons.lang3.StringUtils;
import org.springframework.beans.factory.annotation.Autowired;
@ -38,7 +38,7 @@ public class StPptnRController {
@Autowired
private StStbprpBAutoMapper stbprpDao;
@Schema(description = "分页查询")
@Operation(summary = "分页查询")
@PostMapping("/page")
public R<Page<StPptnR>> page(@RequestBody RtuDataSo so) {
List<String> stcds = new ArrayList<>();

View File

@ -3,11 +3,12 @@ package com.gunshi.project.xyt.controller;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.gunshi.core.result.R;
import com.gunshi.project.xyt.model.*;
import com.gunshi.project.xyt.model.StRsvrR;
import com.gunshi.project.xyt.model.StRsvrRAutoDao;
import com.gunshi.project.xyt.model.StStbprpB;
import com.gunshi.project.xyt.model.StStbprpBAutoMapper;
import com.gunshi.project.xyt.so.RtuDataSo;
import io.swagger.v3.oas.annotations.media.Schema;
import io.swagger.v3.oas.annotations.Operation;
import io.swagger.v3.oas.annotations.tags.Tag;
import org.apache.commons.lang3.StringUtils;
import org.springframework.beans.factory.annotation.Autowired;
@ -37,7 +38,7 @@ public class StRsvrRController {
@Autowired
private StStbprpBAutoMapper stbprpDao;
@Schema(description = "分页查询")
@Operation(summary = "分页查询")
@PostMapping("/page")
public R<Page<StRsvrR>> page(@RequestBody RtuDataSo so) {
List<String> stcds = new ArrayList<>();

View File

@ -3,11 +3,12 @@ package com.gunshi.project.xyt.controller;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.gunshi.core.result.R;
import com.gunshi.project.xyt.model.*;
import com.gunshi.project.xyt.model.StStbprpB;
import com.gunshi.project.xyt.model.StStbprpBAutoMapper;
import com.gunshi.project.xyt.model.StVoltageR;
import com.gunshi.project.xyt.model.StVoltageRAutoDao;
import com.gunshi.project.xyt.so.RtuDataSo;
import io.swagger.v3.oas.annotations.media.Schema;
import io.swagger.v3.oas.annotations.Operation;
import io.swagger.v3.oas.annotations.tags.Tag;
import org.apache.commons.lang3.StringUtils;
import org.springframework.beans.factory.annotation.Autowired;
@ -37,7 +38,7 @@ public class StVoltageRController {
@Autowired
private StStbprpBAutoMapper stbprpDao;
@Schema(description = "分页查询")
@Operation(summary = "分页查询")
@PostMapping("/page")
public R<Page<StVoltageR>> page(@RequestBody RtuDataSo so) {
List<String> stcds = new ArrayList<>();