From b8d62de41ff7e1e0549061308aa11f68cf881ed9 Mon Sep 17 00:00:00 2001 From: 13693261870 <252740454@qq.com> Date: 星期三, 16 七月 2025 17:01:20 +0800 Subject: [PATCH] 修改所有的controller --- se-system/src/main/java/com/terra/system/controller/data/upload/QueryController.java | 80 ++++++++++++++++++++------------------- 1 files changed, 41 insertions(+), 39 deletions(-) diff --git a/se-system/src/main/java/com/terra/system/controller/data/upload/QueryController.java b/se-system/src/main/java/com/terra/system/controller/data/upload/QueryController.java index 90defdd..60199dd 100644 --- a/se-system/src/main/java/com/terra/system/controller/data/upload/QueryController.java +++ b/se-system/src/main/java/com/terra/system/controller/data/upload/QueryController.java @@ -18,10 +18,12 @@ import com.terra.system.service.data.*; import com.terra.system.service.sys.DepService; import com.terra.system.service.sys.TokenService; -import io.swagger.annotations.ApiImplicitParam; -import io.swagger.annotations.ApiImplicitParams; -import io.swagger.annotations.ApiOperation; +import io.swagger.v3.oas.annotations.Operation; +import io.swagger.v3.oas.annotations.Parameter; +import io.swagger.v3.oas.annotations.Parameters; import javax.annotation.Resource; + +import io.swagger.v3.oas.annotations.enums.ParameterIn; import org.springframework.web.bind.annotation.GetMapping; import javax.servlet.http.HttpServletRequest; @@ -57,12 +59,12 @@ DictService dictService; @SysLog() - @ApiOperation(value = "鏍规嵁鐖禝D鍒嗛〉鏌ヨ骞惰繑鍥炶褰曟暟") - @ApiImplicitParams({ - @ApiImplicitParam(name = "metaid", value = "鐖禝D", dataType = "String", paramType = "query", example = "0"), - @ApiImplicitParam(name = "name", value = "鍚嶇О", dataType = "String", paramType = "query", example = ""), - @ApiImplicitParam(name = "pageSize", value = "姣忛〉鏉℃暟", dataType = "Integer", paramType = "query", example = "10"), - @ApiImplicitParam(name = "pageIndex", value = "鍒嗛〉鏁帮紙浠�1寮�濮嬶級", dataType = "Integer", paramType = "query", example = "1") + @Operation(summary = "鏍规嵁鐖禝D鍒嗛〉鏌ヨ骞惰繑鍥炶褰曟暟") + @Parameters({ + @Parameter(name = "metaid", description = "鐖禝D", in = ParameterIn.QUERY, example = "0"), + @Parameter(name = "name", description = "鍚嶇О", in = ParameterIn.QUERY, example = ""), + @Parameter(name = "pageSize", description = "姣忛〉鏉℃暟", in = ParameterIn.QUERY, example = "10"), + @Parameter(name = "pageIndex", description = "鍒嗛〉鏁帮紙浠�1寮�濮嬶級", in = ParameterIn.QUERY, example = "1") }) @GetMapping(value = "/selectPageAndCountByPid") public ResponseMsg<List<MetaEntity>> selectPageAndCountByPid(Integer metaid, String name, Integer pageSize, Integer pageIndex) { @@ -88,7 +90,7 @@ } @SysLog() - @ApiOperation(value = "鏌ヨ鎵�鏈夊崟浣�") + @Operation(summary = "鏌ヨ鎵�鏈夊崟浣�") @GetMapping(value = "/selectDepAll") public ResponseMsg<List<DepEntity>> selectDepAll() { try { @@ -101,7 +103,7 @@ } @SysLog() - @ApiOperation(value = "鏌ヨ鎵�鏈夌洰褰�") + @Operation(summary = "鏌ヨ鎵�鏈夌洰褰�") @GetMapping(value = "/selectDirAll") public ResponseMsg<List<DirEntity>> selectDirAll() { try { @@ -114,9 +116,9 @@ } @SysLog() - @ApiOperation(value = "鏍规嵁鐩綍ID鏌ヨ鐗堟湰鍒楄〃") - @ApiImplicitParams({ - @ApiImplicitParam(name = "dirid", value = "鐩綍ID", dataType = "Integer", paramType = "query") + @Operation(summary = "鏍规嵁鐩綍ID鏌ヨ鐗堟湰鍒楄〃") + @Parameters({ + @Parameter(name = "dirid", description = "鐩綍ID", in = ParameterIn.QUERY) }) @GetMapping(value = "/selectVerByDirid") public ResponseMsg<List<VerEntity>> selectVerByDirid(Integer dirid) { @@ -137,9 +139,9 @@ } @SysLog() - @ApiOperation(value = "鏌ヨ鍧愭爣绯�") - @ApiImplicitParams({ - @ApiImplicitParam(name = "zoning", value = "甯﹀彿", dataType = "String", paramType = "query", example = "6搴︽湁甯﹀彿") + @Operation(summary = "鏌ヨ鍧愭爣绯�") + @Parameters({ + @Parameter(name = "zoning", description = "甯﹀彿", in = ParameterIn.QUERY, example = "6搴︽湁甯﹀彿") }) @GetMapping(value = "/selectCoords") public ResponseMsg<Object> selectCoords(String zoning) { @@ -153,7 +155,7 @@ } @SysLog() - @ApiOperation(value = "鏌ヨ椤圭洰鍚嶇О") + @Operation(summary = "鏌ヨ椤圭洰鍚嶇О") @GetMapping(value = "/selectProject") public ResponseMsg<Object> selectProject() { try { @@ -166,10 +168,10 @@ } @SysLog() - @ApiOperation(value = "鏌ヨ鎵�鏈夎〃") - @ApiImplicitParams({ - @ApiImplicitParam(name = "name", value = "鍚嶇О", dataType = "String", paramType = "query", example = "鐐�"), - @ApiImplicitParam(name = "hasGeom", value = "鍚湁Geom瀛楁", dataType = "Boolean", paramType = "query", example = "false") + @Operation(summary = "鏌ヨ鎵�鏈夎〃") + @Parameters({ + @Parameter(name = "name", description = "鍚嶇О", in = ParameterIn.QUERY, example = "鐐�"), + @Parameter(name = "hasGeom", description = "鍚湁Geom瀛楁", in = ParameterIn.QUERY, example = "false") }) @GetMapping(value = "/selectTabs") public ResponseMsg<List<TabEntity>> selectTabs(String name, Boolean hasGeom) { @@ -183,10 +185,10 @@ } @SysLog() - @ApiOperation(value = "鏌ヨ瀛楁淇℃伅") - @ApiImplicitParams({ - @ApiImplicitParam(name = "ns", value = "鍚嶇О绌洪棿", dataType = "String", paramType = "query", example = "bd"), - @ApiImplicitParam(name = "tab", value = "琛ㄥ悕", dataType = "String", paramType = "query", example = "dlg25wAanp") + @Operation(summary = "鏌ヨ瀛楁淇℃伅") + @Parameters({ + @Parameter(name = "ns", description = "鍚嶇О绌洪棿", in = ParameterIn.QUERY, example = "bd"), + @Parameter(name = "tab", description = "琛ㄥ悕", in = ParameterIn.QUERY, example = "dlg25wAanp") }) @GetMapping(value = "/selectFields") public ResponseMsg<List<DictEntity>> selectFields(String ns, String tab) { @@ -204,11 +206,11 @@ } @SysLog() - @ApiOperation(value = "鏌ヨ琛ㄤ腑鏁版嵁") - @ApiImplicitParams({ - @ApiImplicitParam(name = "id", value = "鍏冩暟鎹甀D", dataType = "Integer", paramType = "query", example = "115"), - @ApiImplicitParam(name = "pageIndex", value = "鍒嗛〉鏁帮紙浠�1寮�濮嬶級", dataType = "Integer", paramType = "query", example = "1"), - @ApiImplicitParam(name = "pageSize", value = "姣忛〉鏉℃暟", dataType = "Integer", paramType = "query", example = "10") + @Operation(summary = "鏌ヨ琛ㄤ腑鏁版嵁") + @Parameters({ + @Parameter(name = "id", description = "鍏冩暟鎹甀D", in = ParameterIn.QUERY, example = "115"), + @Parameter(name = "pageIndex", description = "鍒嗛〉鏁帮紙浠�1寮�濮嬶級", in = ParameterIn.QUERY, example = "1"), + @Parameter(name = "pageSize", description = "姣忛〉鏉℃暟", in = ParameterIn.QUERY, example = "10") }) @GetMapping(value = "/selectDbData") public ResponseMsg<Object> selectDbData(Integer id, Integer pageIndex, Integer pageSize) { @@ -243,11 +245,11 @@ } @SysLog() - @ApiOperation(value = "鍒嗛〉鏌ヨ涓婁紶鏁版嵁骞惰繑鍥炶褰曟暟") - @ApiImplicitParams({ - @ApiImplicitParam(name = "name", value = "鍚嶇О", dataType = "String", paramType = "query", example = ""), - @ApiImplicitParam(name = "pageSize", value = "姣忛〉鏉℃暟", dataType = "Integer", paramType = "query", example = "10"), - @ApiImplicitParam(name = "pageIndex", value = "鍒嗛〉鏁帮紙浠�1寮�濮嬶級", dataType = "Integer", paramType = "query", example = "1") + @Operation(summary = "鍒嗛〉鏌ヨ涓婁紶鏁版嵁骞惰繑鍥炶褰曟暟") + @Parameters({ + @Parameter(name = "name", description = "鍚嶇О", in = ParameterIn.QUERY, example = ""), + @Parameter(name = "pageSize", description = "姣忛〉鏉℃暟", in = ParameterIn.QUERY, example = "10"), + @Parameter(name = "pageIndex", description = "鍒嗛〉鏁帮紙浠�1寮�濮嬶級", in = ParameterIn.QUERY, example = "1") }) @GetMapping(value = "/selectByPageForUpload") public ResponseMsg<Object> selectByPageForUpload(String name, Integer pageSize, Integer pageIndex, HttpServletRequest req) { @@ -272,9 +274,9 @@ } @SysLog() - @ApiOperation(value = "鏍规嵁鍏冩暟鎹甀D鏌ヨ") - @ApiImplicitParams({ - @ApiImplicitParam(name = "id", value = "ID", dataType = "int", paramType = "query", example = "1") + @Operation(summary = "鏍规嵁鍏冩暟鎹甀D鏌ヨ") + @Parameters({ + @Parameter(name = "id", description = "ID", in = ParameterIn.QUERY, example = "1") }) @GetMapping(value = "/selectMetaById") public ResponseMsg<MetaEntity> selectMetaById(int id) { -- Gitblit v1.9.3