brewman/overlord/src/app/employee-attendance/employee-attendance-datasource.ts

17 lines
433 B
TypeScript
Raw Normal View History

import { DataSource } from '@angular/cdk/collections';
import { Observable } from 'rxjs';
import { EmployeeAttendanceItem } from './employee-attendance-item';
export class EmployeeAttendanceDataSource extends DataSource<EmployeeAttendanceItem> {
constructor(private data: Observable<EmployeeAttendanceItem[]>) {
super();
}
connect(): Observable<EmployeeAttendanceItem[]> {
return this.data;
}
disconnect() {}
}