|
@@ -104,7 +104,7 @@ public class StudentSelectSupervisorRecordController {
|
|
|
Long loginId = SecurityFrameworkUtils.getLoginUserId();
|
|
|
AdminUserDO loginUser =adminUserService.getUser(loginId);
|
|
|
LocalDateTime dateTime =LocalDateTime.now();
|
|
|
- studentSelectionProjectSaveReqVO project = BeanUtils.toBean(studentSelectionProjectService.getStudentSelectionProjectByYear(dateTime.getYear()), studentSelectionProjectSaveReqVO.class);
|
|
|
+ studentSelectionProjectSaveReqVO project = BeanUtils.toBean(studentSelectionProjectService.getStudentSelectionProject(createReqVO.getProjectId()), studentSelectionProjectSaveReqVO.class);
|
|
|
Set<Long> roleIds = permissionService.getUserRoleIdListByUserId(loginId);
|
|
|
if ((roleIds.contains(112L) || roleIds.contains(113L)) && project.getSupervisorConfirmDeadline().isBefore(dateTime)) {
|
|
|
return error(1, "该项目已过截至日期");
|
|
@@ -258,7 +258,7 @@ public class StudentSelectSupervisorRecordController {
|
|
|
public CommonResult<Boolean> agreeSelectionRecord(@Valid @RequestBody StudentSelectSupervisorRecordSaveReqVO updateReqVO) {
|
|
|
LocalDateTime dateTime = LocalDateTime.now();
|
|
|
|
|
|
- studentSelectionProjectSaveReqVO project = BeanUtils.toBean(studentSelectionProjectService.getStudentSelectionProjectByYear(dateTime.getYear()), studentSelectionProjectSaveReqVO.class);
|
|
|
+ studentSelectionProjectSaveReqVO project = BeanUtils.toBean(studentSelectionProjectService.getStudentSelectionProject(updateReqVO.getProjectId()), studentSelectionProjectSaveReqVO.class);
|
|
|
if (updateReqVO.getId() != null) {
|
|
|
studentSelectSupervisorRecordDO record = studentSelectSupervisorRecordService.getStudentSelectSupervisorRecord(updateReqVO.getId());
|
|
|
AdminUserDO student = adminUserService.getUser(record.getStudentId());
|
|
@@ -318,7 +318,7 @@ public class StudentSelectSupervisorRecordController {
|
|
|
@PreAuthorize("@ss.hasPermission('system:student-select-supervisor-record:refuse')")
|
|
|
public CommonResult<Boolean> refuseSelectionRecord(@Valid @RequestBody StudentSelectSupervisorRecordSaveReqVO updateReqVO) {
|
|
|
LocalDateTime dateTime = LocalDateTime.now();
|
|
|
- studentSelectionProjectSaveReqVO project = BeanUtils.toBean(studentSelectionProjectService.getStudentSelectionProjectByYear(dateTime.getYear()), studentSelectionProjectSaveReqVO.class);
|
|
|
+ studentSelectionProjectSaveReqVO project = BeanUtils.toBean(studentSelectionProjectService.getStudentSelectionProject(updateReqVO.getProjectId()), studentSelectionProjectSaveReqVO.class);
|
|
|
Long loginId = SecurityFrameworkUtils.getLoginUserId();
|
|
|
Set<Long> roleIds = permissionService.getUserRoleIdListByUserId(loginId);
|
|
|
if ((roleIds.contains(112L) || roleIds.contains(113L)) && project.getSupervisorConfirmDeadline().isBefore(dateTime)) {
|
|
@@ -337,7 +337,7 @@ public class StudentSelectSupervisorRecordController {
|
|
|
@PreAuthorize("@ss.hasPermission('system:student-select-supervisor-record:withdraw')")
|
|
|
public CommonResult<Boolean> withdrawSelectionRecordBySupervisorId(@Valid @RequestBody StudentSelectSupervisorRecordSaveReqVO updateReqVO) {
|
|
|
LocalDateTime dateTime = LocalDateTime.now();
|
|
|
- studentSelectionProjectSaveReqVO project = BeanUtils.toBean(studentSelectionProjectService.getStudentSelectionProjectByYear(dateTime.getYear()), studentSelectionProjectSaveReqVO.class);
|
|
|
+ studentSelectionProjectSaveReqVO project = BeanUtils.toBean(studentSelectionProjectService.getStudentSelectionProject(updateReqVO.getProjectId()), studentSelectionProjectSaveReqVO.class);
|
|
|
Long loginId = SecurityFrameworkUtils.getLoginUserId();
|
|
|
Set<Long> roleIds = permissionService.getUserRoleIdListByUserId(loginId);
|
|
|
if ((roleIds.contains(112L) || roleIds.contains(113L)) && project.getSupervisorConfirmDeadline().isBefore(dateTime)) {
|
|
@@ -352,14 +352,14 @@ public class StudentSelectSupervisorRecordController {
|
|
|
return success(true);
|
|
|
}
|
|
|
|
|
|
-
|
|
|
//在互选记录里面撤回
|
|
|
@PutMapping("/withdrawRecord")
|
|
|
@Operation(summary = "互选记录撤回")
|
|
|
@PreAuthorize("@ss.hasPermission('system:student-select-supervisor-record:withdrawRecord')")
|
|
|
public CommonResult<Boolean> withdrawSelectionRecord(@Valid @RequestBody StudentSelectSupervisorRecordSaveReqVO updateReqVO) {
|
|
|
LocalDateTime dateTime = LocalDateTime.now();
|
|
|
- studentSelectionProjectSaveReqVO project = BeanUtils.toBean(studentSelectionProjectService.getStudentSelectionProjectByYear(dateTime.getYear()), studentSelectionProjectSaveReqVO.class);
|
|
|
+ studentSelectSupervisorRecordDO record = studentSelectSupervisorRecordService.getStudentSelectSupervisorRecord(updateReqVO.getId());
|
|
|
+ studentSelectionProjectSaveReqVO project = BeanUtils.toBean(studentSelectionProjectService.getStudentSelectionProject(record.getProjectId()), studentSelectionProjectSaveReqVO.class);
|
|
|
Long loginId = SecurityFrameworkUtils.getLoginUserId();
|
|
|
Set<Long> roleIds = permissionService.getUserRoleIdListByUserId(loginId);
|
|
|
if ((roleIds.contains(112L) || roleIds.contains(113L)) && project.getSupervisorConfirmDeadline().isBefore(dateTime)) {
|