|
|
|
@@ -174,10 +174,12 @@ public class SrsDormitoryStudentController extends BaseController {
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@PreAuthorize("@ss.hasPermi('dms:dormStu:add')")
|
|
|
|
@ApiOperation(value = "学生自主选择床位", notes = "id不用填写,只能选择是当前学生班级并且为空的宿舍床位", response = StudentDormitoryDto.class)
|
|
|
|
@ApiOperation(value = "学生自主选择床位", notes = "id不用填写,只能选择是当前学生班级并且为空的宿舍床位", response = StudentDormitoryDto.class)
|
|
|
|
@PostMapping("/add")
|
|
|
|
@PostMapping("/add")
|
|
|
|
public AjaxResult add(@RequestBody StudentDormitoryDto dto) {
|
|
|
|
public AjaxResult add(@RequestBody StudentDormitoryDto dto) {
|
|
|
|
boolean hasRole = RoleBool.isHigh(getUserId(), _postService);
|
|
|
|
boolean hasRole = RoleBool.isHigh(getUserId(), _postService);
|
|
|
|
|
|
|
|
System.out.println(hasRole);
|
|
|
|
if (hasRole) {
|
|
|
|
if (hasRole) {
|
|
|
|
DomInfo dorm = _dormService.getDormHas(dto.getDormitoryId());
|
|
|
|
DomInfo dorm = _dormService.getDormHas(dto.getDormitoryId());
|
|
|
|
SrsStudent stu = _stuService.getStuInfo(dto.getStuNo());
|
|
|
|
SrsStudent stu = _stuService.getStuInfo(dto.getStuNo());
|
|
|
|
@@ -262,6 +264,7 @@ public class SrsDormitoryStudentController extends BaseController {
|
|
|
|
return srsDormitoryStudentService.cancel();
|
|
|
|
return srsDormitoryStudentService.cancel();
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@ApiOperation(value = "管理员分配学生床位", notes = "id不用填写", response = StudentDormitoryDto.class)
|
|
|
|
@ApiOperation(value = "管理员分配学生床位", notes = "id不用填写", response = StudentDormitoryDto.class)
|
|
|
|
@PostMapping("/admin/add")
|
|
|
|
@PostMapping("/admin/add")
|
|
|
|
public AjaxResult adminAdd(@RequestBody StudentDormitoryDto studentDormitoryDto) {
|
|
|
|
public AjaxResult adminAdd(@RequestBody StudentDormitoryDto studentDormitoryDto) {
|
|
|
|
|