| | |
| | | import com.mindskip.xzs.base.RestResponse; |
| | | import com.mindskip.xzs.domain.ExamPaper; |
| | | import com.mindskip.xzs.domain.ExamPaperSubject; |
| | | import com.mindskip.xzs.service.ExamPaperDepartmentService; |
| | | import com.mindskip.xzs.service.ExamPaperService; |
| | | import com.mindskip.xzs.service.ExamPaperSubjectService; |
| | | import com.mindskip.xzs.utility.DateTimeUtil; |
| | |
| | | |
| | | private final ExamPaperService examPaperService; |
| | | private final ExamPaperSubjectService examPaperSubjectService; |
| | | private final ExamPaperDepartmentService examPaperDepartmentService; |
| | | |
| | | @Autowired |
| | | public ExamPaperController(ExamPaperService examPaperService, ExamPaperSubjectService examPaperSubjectService) { |
| | | public ExamPaperController(ExamPaperService examPaperService, ExamPaperSubjectService examPaperSubjectService, ExamPaperDepartmentService examPaperDepartmentService) { |
| | | this.examPaperService = examPaperService; |
| | | this.examPaperSubjectService = examPaperSubjectService; |
| | | this.examPaperDepartmentService = examPaperDepartmentService; |
| | | } |
| | | |
| | | @RequestMapping(value = "/page", method = RequestMethod.POST) |
| | |
| | | ExamPaper examPaper = examPaperService.selectById(id); |
| | | examPaper.setDeleted(true); |
| | | examPaperService.updateByIdFilter(examPaper); |
| | | examPaperDepartmentService.removeByExamPaperId(id); |
| | | examPaperSubjectService.removeByExamPaperId(id); |
| | | return RestResponse.ok(); |
| | | } |
| | | } |