diff --git a/renren-admin/src/main/java/io/renren/common/controller/AbilityCenterController.java b/renren-admin/src/main/java/io/renren/common/controller/AbilityCenterController.java index d41473b8..1e30a7ea 100644 --- a/renren-admin/src/main/java/io/renren/common/controller/AbilityCenterController.java +++ b/renren-admin/src/main/java/io/renren/common/controller/AbilityCenterController.java @@ -14,6 +14,8 @@ import io.renren.modules.activiti.service.ActRunningService; import io.renren.modules.processForm.dto.TAbilityApplicationDTO; import io.renren.modules.processForm.dto.TAbilityBatchApplicationDTO; import io.renren.modules.processForm.service.TAbilityApplicationService; +import io.swagger.annotations.Api; +import io.swagger.annotations.ApiOperation; import org.codehaus.jackson.map.ObjectMapper; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.web.bind.annotation.PostMapping; @@ -30,6 +32,8 @@ import java.util.stream.Collectors; /** * 能力集中中心 接口 */ + +@Api(tags = "能力集中") @RestController @RequestMapping("/ability/center") public class AbilityCenterController { @@ -55,6 +59,7 @@ public class AbilityCenterController { * @return */ @PostMapping(value = "/apply") + @ApiOperation("批量进行能力申请") public Result> apply(@RequestBody TAbilityBatchApplicationDTO abilityBatchApplicationDTO) { // 仿照请求接口 /act/process/lastestPage PageData> page = actProcessService.page(params); diff --git a/renren-admin/src/main/java/io/renren/common/controller/FileUploadController.java b/renren-admin/src/main/java/io/renren/common/controller/FileUploadController.java index da5266e6..44c98968 100644 --- a/renren-admin/src/main/java/io/renren/common/controller/FileUploadController.java +++ b/renren-admin/src/main/java/io/renren/common/controller/FileUploadController.java @@ -2,6 +2,10 @@ package io.renren.common.controller; import io.renren.common.utils.Result; +import io.swagger.annotations.Api; +import io.swagger.annotations.ApiImplicitParam; +import io.swagger.annotations.ApiImplicitParams; +import io.swagger.annotations.ApiOperation; import org.slf4j.Logger; import org.slf4j.LoggerFactory; import org.springframework.beans.factory.annotation.Value; @@ -18,6 +22,7 @@ import java.util.Date; import java.util.UUID; @RestController +@Api(tags = "静态资源上传") public class FileUploadController { @Value("${resource.path}") private String uploadPath; @@ -31,6 +36,10 @@ public class FileUploadController { private static SimpleDateFormat sdf = new SimpleDateFormat("yyyy/MM/dd/"); @PostMapping("/upload") + @ApiOperation("上传") + @ApiImplicitParams({ + @ApiImplicitParam(name = "file", value = "文件", paramType = "file", dataType = "file", required = true) + }) public Result upload(@RequestParam("file") MultipartFile uploadFile, HttpServletRequest request) { logger.info("上传文件:" + uploadFile.getOriginalFilename());