|
|
@@ -0,0 +1,56 @@
|
|
|
+package com.xjrsoft.module.student.controller;
|
|
|
+
|
|
|
+import cn.dev33.satoken.annotation.SaCheckPermission;
|
|
|
+import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
|
|
+import com.xjrsoft.common.model.result.RT;
|
|
|
+import com.xjrsoft.common.page.ConventPage;
|
|
|
+import com.xjrsoft.common.page.PageOutput;
|
|
|
+import com.xjrsoft.module.student.dto.BaseStudentInfoPageDto;
|
|
|
+import com.xjrsoft.module.student.dto.UpdateBaseStudentInfoDto;
|
|
|
+import com.xjrsoft.module.student.service.impl.IBaseStudentSchoolRollService;
|
|
|
+import com.xjrsoft.module.student.vo.BaseStudentInfoPageVo;
|
|
|
+import io.swagger.annotations.Api;
|
|
|
+import io.swagger.annotations.ApiOperation;
|
|
|
+import lombok.AllArgsConstructor;
|
|
|
+import org.springframework.web.bind.annotation.GetMapping;
|
|
|
+import org.springframework.web.bind.annotation.PutMapping;
|
|
|
+import org.springframework.web.bind.annotation.RequestBody;
|
|
|
+import org.springframework.web.bind.annotation.RequestMapping;
|
|
|
+import org.springframework.web.bind.annotation.RestController;
|
|
|
+
|
|
|
+import javax.validation.Valid;
|
|
|
+
|
|
|
+/**
|
|
|
+* @title: 学生职务设置
|
|
|
+* @Author dzx
|
|
|
+* @Date: 2023-11-13
|
|
|
+* @Version 1.0
|
|
|
+*/
|
|
|
+@RestController
|
|
|
+@RequestMapping("/student" + "/basestudentinfo")
|
|
|
+@Api(value = "/student" + "/basestudentinfo",tags = "学生信息修改管理")
|
|
|
+@AllArgsConstructor
|
|
|
+public class BaseStudentInfoController {
|
|
|
+
|
|
|
+
|
|
|
+ private final IBaseStudentSchoolRollService baseStudentSchoolRollService;
|
|
|
+
|
|
|
+ @GetMapping(value = "/mobile-page")
|
|
|
+ @ApiOperation(value="学生列表(分页)")
|
|
|
+ @SaCheckPermission("basestudentpost:detail")
|
|
|
+ public RT<PageOutput<BaseStudentInfoPageVo>> mobilePage(@Valid BaseStudentInfoPageDto dto){
|
|
|
+ Page<BaseStudentInfoPageVo> mobilePage = baseStudentSchoolRollService.getMobilePage(new Page<>(dto.getLimit(), dto.getSize()), dto);
|
|
|
+ PageOutput<BaseStudentInfoPageVo> pageOutput = ConventPage.getPageOutput(mobilePage, BaseStudentInfoPageVo.class);
|
|
|
+ return RT.ok(pageOutput);
|
|
|
+ }
|
|
|
+
|
|
|
+
|
|
|
+ @PutMapping
|
|
|
+ @ApiOperation(value = "修改学生职务设置")
|
|
|
+ @SaCheckPermission("basestudentpost:edit")
|
|
|
+ public RT<Boolean> update(@Valid @RequestBody UpdateBaseStudentInfoDto dto){
|
|
|
+ return RT.ok(baseStudentSchoolRollService.updateInfo(dto));
|
|
|
+ }
|
|
|
+
|
|
|
+
|
|
|
+}
|