diff --git a/admin/src/main/java/com/neuedu/controller/FundApplyController.java b/admin/src/main/java/com/neuedu/controller/FundApplyController.java index 865b955be27a5e2fcc2ac16aabeeaafad75b6cce..2d8c9ed519b4668169f0e3b0f51f26cbce81b5f9 100644 --- a/admin/src/main/java/com/neuedu/controller/FundApplyController.java +++ b/admin/src/main/java/com/neuedu/controller/FundApplyController.java @@ -37,8 +37,10 @@ public class FundApplyController { @Resource private IFundApplyService iFundApplyService; @PostMapping("/add") - CommonResult add(FundApply fundApply) throws IOException { return CommonResult.success(iFundApplyService.add(fundApply));} - + CommonResult add(FundApply fundApply) throws IOException { + fundApply.setStatus(1); + return CommonResult.success(iFundApplyService.add(fundApply)); + } /** * 进行分页查询 */ @@ -49,6 +51,7 @@ public class FundApplyController { int limit = Integer.parseInt(param.get("limit").toString()); QueryWrapper wrapper = new QueryWrapper<>(); InitUtil.initEq(param, wrapper, "active"); + InitUtil.initLike(param, wrapper, "name"); IPage page = new Page<>(num, limit); return CommonResult.success(iFundApplyService.page(page, wrapper)); } diff --git a/admin/src/main/java/com/neuedu/controller/ProjectController.java b/admin/src/main/java/com/neuedu/controller/ProjectController.java index 8fe09d2165e095dae761579c60604d1876338518..2cf1d1e478b75a94bcd356d59b08cf12762a48d2 100644 --- a/admin/src/main/java/com/neuedu/controller/ProjectController.java +++ b/admin/src/main/java/com/neuedu/controller/ProjectController.java @@ -30,7 +30,7 @@ import org.slf4j.LoggerFactory; * @since 2020-09-17 */ @RestController -@RequestMapping("/college_project") +@RequestMapping("/project") public class ProjectController { private final Logger logger = LoggerFactory.getLogger(ProjectController.class); @@ -44,6 +44,7 @@ public class ProjectController { } @PostMapping("/add") CommonResult add(Project project) throws IOException { + project.setStatus(1); System.out.println(project.getMultipartFile()); System.out.println(project.getMultipartFile().getSize()); return CommonResult.success(iProjectService.add(project));} @@ -58,6 +59,7 @@ public class ProjectController { int limit = Integer.parseInt(param.get("limit").toString()); QueryWrapper wrapper = new QueryWrapper<>(); InitUtil.initEq(param, wrapper, "active"); + InitUtil.initLike(param, wrapper, "name"); IPage page = new Page<>(num, limit); return CommonResult.success(iProjectService.page(page, wrapper)); } diff --git a/pom.xml b/pom.xml index 7501018e878c7fb5c138f959fad7fb50c8201965..8675a140eacc0c400e2ae1202cb6a647dd3c01ab 100644 --- a/pom.xml +++ b/pom.xml @@ -38,6 +38,7 @@ 2.3.30 3.10.3 1.2.70 + 1.27.2 3.10.2 @@ -112,6 +113,11 @@ fastjson ${fastjson.version} + + com.github.tobato + fastdfs-client + ${fastdfs.verson} +