Skip to content

Commit

Permalink
Merge pull request #1 from simonliuanu/13144-copy-enroll-student
Browse files Browse the repository at this point in the history
[#13144] copy enroll student
  • Loading branch information
simonliuanu authored Oct 25, 2024
2 parents 4d2d3c9 + c7b26e3 commit 2656142
Showing 1 changed file with 13 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -667,5 +667,18 @@ export class InstructorCourseEnrollPageComponent implements OnInit {
const existingStudentsData = existingStudentsHOTInstance.getData();

newStudentsHOTInstance.loadData(existingStudentsData);

if(!this.isExistingStudentsPresent) {

Check failure on line 671 in src/web/app/pages-instructor/instructor-course-enroll-page/instructor-course-enroll-page.component.ts

View workflow job for this annotation

GitHub Actions / lint (ubuntu-latest)

Expected space(s) after "if"

Check failure on line 671 in src/web/app/pages-instructor/instructor-course-enroll-page/instructor-course-enroll-page.component.ts

View workflow job for this annotation

GitHub Actions / lint (windows-latest)

Expected space(s) after "if"
this.statusMessageService.showErrorToast('No valid existing students to copy.');
return;
}

if(this.isExistingStudentsPanelCollapsed) {

Check failure on line 676 in src/web/app/pages-instructor/instructor-course-enroll-page/instructor-course-enroll-page.component.ts

View workflow job for this annotation

GitHub Actions / lint (ubuntu-latest)

Expected space(s) after "if"

Check failure on line 676 in src/web/app/pages-instructor/instructor-course-enroll-page/instructor-course-enroll-page.component.ts

View workflow job for this annotation

GitHub Actions / lint (windows-latest)

Expected space(s) after "if"
this.statusMessageService.showWarningToast('Please expand existing students.');
return;

Check failure on line 678 in src/web/app/pages-instructor/instructor-course-enroll-page/instructor-course-enroll-page.component.ts

View workflow job for this annotation

GitHub Actions / lint (ubuntu-latest)

Unnecessary return statement

Check failure on line 678 in src/web/app/pages-instructor/instructor-course-enroll-page/instructor-course-enroll-page.component.ts

View workflow job for this annotation

GitHub Actions / lint (windows-latest)

Unnecessary return statement
} else {

Check failure on line 679 in src/web/app/pages-instructor/instructor-course-enroll-page/instructor-course-enroll-page.component.ts

View workflow job for this annotation

GitHub Actions / lint (ubuntu-latest)

Unnecessary 'else' after 'return'

Check failure on line 679 in src/web/app/pages-instructor/instructor-course-enroll-page/instructor-course-enroll-page.component.ts

View workflow job for this annotation

GitHub Actions / lint (windows-latest)

Unnecessary 'else' after 'return'
this.statusMessageService.showSuccessToast('Existing students copied successfully.');
}

}
}

0 comments on commit 2656142

Please sign in to comment.