Student enrollment import

We need to have page where we can import student enrollments and display them on path /enroll/student-subject.

The page will display the StudentSubjectEnrollment fields in paged table. Also, there should be an import form, where the admin will be able to select semester and import tsv file with the following structure:

  • index (student)
  • code (for subject in enrollment)
  • num_enrollments

The process goes as follow:

  1. Upload tsv on a controller path: POST "/enroll/student-subject/{semester}/import"
  2. Controller transforms tsv into List<Map<String, String>> or List<SubjectEnrollmentDto>
  3. Send the list into the service, where we should:
  • if the student's index or subject's code exist, save the StudentSubjectEnrollment in db
  • If some of them does not exist, we skip the DTO and report it as problematic in the result list with a reason (student_not_found, subject_not_found).
  • The method signature will be: List<SubjectEnrollmentDto> import(List<SubjectEnrollmentDto> importEnrollments) where the result will be the invalid rows.
  1. The invalid row should be downloaded as tsv in the controller
Edited by Ристе Стојанов