Created
January 10, 2019 12:23
-
-
Save AhsanNissar/6fe2cf654a8c1e5fb7924202f62fec12 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@Component({ | |
selector: 'app-student-list', | |
templateUrl: './student-list.component.html', | |
styleUrls: ['./student-list.component.css'], | |
animations: [appModuleAnimation()] | |
}) | |
export class StudentListComponent extends PagedListingComponentBase<StudentListDto> { | |
students: StudentListDto[] | undefined; | |
constructor( | |
injector: Injector, | |
private router: Router, | |
private _studentService: StudentServiceProxy, | |
private _sharedDataService: SharedDataService | |
) { | |
super(injector); | |
} | |
list(request: PagedRequestDto, pageNumber: number, finishedCallback: Function): void { | |
this.showSpinner = true; | |
this._studentService.GetSchoolStudents(this.appSession.tenant.tenancyName) | |
.finally(() => { | |
finishedCallback(); | |
this.showSpinner = false; | |
}) | |
.subscribe((result: ListResultDtoOfStudentDto) => { | |
this.students = result.studentList; | |
}); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment