ngx-admin/src/app/@core/mock/traffic-chart.service.ts
Valentin Kononov cac36f0717 refactor(@core): refactor data services for better integration (#1997)
With this change all components, which used data services before, now use abstract classes of service interfaces, mock services extend interface services, CoreModule contains code to inject a needed implementation of some service.
2019-01-18 16:25:35 +03:00

16 lines
407 B
TypeScript

import { Injectable } from '@angular/core';
import { of as observableOf, Observable } from 'rxjs';
import { TrafficChartData } from '../data/traffic-chart';
@Injectable()
export class TrafficChartService extends TrafficChartData {
private data: number[] = [
300, 520, 435, 530,
730, 620, 660, 860,
];
getTrafficChartData(): Observable<number[]> {
return observableOf(this.data);
}
}