Add chart exporting

This commit is contained in:
2019-10-01 20:26:44 -04:00
parent 25eca0e078
commit 37263488f0

View File

@@ -6,6 +6,10 @@ import { WeatherReadingGrouped } from '../../../models/weather/weather-reading-g
import { ActivatedRoute, ParamMap } from '@angular/router';
import * as moment from 'moment';
import * as Highcharts from 'highcharts';
import HC_exporting from 'highcharts/modules/exporting';
HC_exporting(Highcharts);
enum TimeSpan {
Last24Hours,
Day,
@@ -113,7 +117,7 @@ export class WeatherChartsComponent implements OnInit {
type: 'line'
},
title: {
text: ''
text: this.timeSpanItems[TimeSpan.Last24Hours]
},
credits: {
enabled: true
@@ -175,6 +179,9 @@ export class WeatherChartsComponent implements OnInit {
series: seriesData,
legend: {
enabled: true
},
exporting: {
enabled: true
}
});