Name changes for future
This commit is contained in:
Vendored
+1
-1
File diff suppressed because one or more lines are too long
Vendored
+4
-4
@@ -56,13 +56,13 @@ var __metadata = (this && this.__metadata) || function (k, v) {
|
||||
var DataService = (function () {
|
||||
function DataService(http) {
|
||||
this.http = http;
|
||||
this.baseUrl = '/webapi/data';
|
||||
this.dashboardURL = '/webapi/dashboard';
|
||||
}
|
||||
DataService.prototype.get = function () {
|
||||
DataService.prototype.dashboard = function () {
|
||||
var lineChartData$ =
|
||||
//<LineData>( {data: [65, 59, 80, 81, 56, 55, 40], label: 'Series A'} );
|
||||
this.http
|
||||
.get(("" + this.baseUrl), { headers: this.getHeaders() })
|
||||
.get(("" + this.dashboardURL), { headers: this.getHeaders() })
|
||||
.map(mapData);
|
||||
return lineChartData$;
|
||||
};
|
||||
@@ -323,7 +323,7 @@ var LineChartComponent = (function () {
|
||||
LineChartComponent.prototype.ngOnInit = function () {
|
||||
var _this = this;
|
||||
this.dataService
|
||||
.get()
|
||||
.dashboard()
|
||||
.subscribe(function (res) {
|
||||
console.log("Received from service:");
|
||||
console.log(res);
|
||||
|
||||
Vendored
+1
-1
File diff suppressed because one or more lines are too long
@@ -50,7 +50,7 @@ router.get('/', function(req, res) {
|
||||
|
||||
|
||||
|
||||
router.get('/data', function(req, res) {
|
||||
router.get('/dashboard', function(req, res) {
|
||||
|
||||
connection.query(
|
||||
'SELECT TOE1`, time FROM measurement ORDER BY time DESC LIMIT 0,10',
|
||||
|
||||
@@ -43,7 +43,7 @@ export class LineChartComponent implements OnInit {
|
||||
ngOnInit(): void {
|
||||
|
||||
this.dataService
|
||||
.get()
|
||||
.dashboard()
|
||||
.subscribe(res => {
|
||||
console.log("Received from service:");
|
||||
console.log(res);
|
||||
|
||||
@@ -9,15 +9,15 @@ import { LabelData } from './label-data';
|
||||
|
||||
@Injectable()
|
||||
export class DataService {
|
||||
private baseUrl: string = '/webapi/data';
|
||||
private dashboardURL: string = '/webapi/dashboard';
|
||||
|
||||
constructor(private http : Http){}
|
||||
|
||||
get(): Observable<GraphData> {
|
||||
dashboard(): Observable<GraphData> {
|
||||
let lineChartData$ =
|
||||
//<LineData>( {data: [65, 59, 80, 81, 56, 55, 40], label: 'Series A'} );
|
||||
this.http
|
||||
.get((`${this.baseUrl}`)
|
||||
.get((`${this.dashboardURL}`)
|
||||
, {headers: this.getHeaders()})
|
||||
.map(mapData);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user