Move global JS methods to an ECharts API Object to avoid name clashes.
Context:
-/* global jQuery3, view, renderZoomableTrendChart */
+/* global jQuery3, view, echartsJenkinsApi */
(function ($) {
redrawTrendCharts();
storeAndRestoreCarousel('trend-carousel');
* Requires that a DOM <div> element exists with the ID '#severities-trend-chart'.
*/
view.getBuildTrend(isBuildOnXAxis, function (lineModel) {
- renderZoomableTrendChart('severities-trend-chart', lineModel.responseJSON, redrawTrendCharts);
+ echartsJenkinsApi.renderZoomableTrendChart('severities-trend-chart', lineModel.responseJSON, redrawTrendCharts);
});
/**
* Requires that a DOM <div> element exists with the ID '#tools-trend-chart'.
*/
view.getToolsTrend(isBuildOnXAxis, function (lineModel) {
- renderZoomableTrendChart('tools-trend-chart', lineModel.responseJSON, redrawTrendCharts);
+ echartsJenkinsApi.renderZoomableTrendChart('tools-trend-chart', lineModel.responseJSON, redrawTrendCharts);
});
/**
* Requires that a DOM <div> element exists with the ID '#new-versus-fixed-trend-chart'.
*/
view.getNewVersusFixedTrend(isBuildOnXAxis, function (lineModel) {
- renderZoomableTrendChart('new-versus-fixed-trend-chart', lineModel.responseJSON, redrawTrendCharts);
+ echartsJenkinsApi.renderZoomableTrendChart('new-versus-fixed-trend-chart', lineModel.responseJSON, redrawTrendCharts);
});
/**
*/
if ($('#health-trend-chart').length) {
view.getHealthTrend(isBuildOnXAxis, function (lineModel) {
- renderZoomableTrendChart('health-trend-chart', lineModel.responseJSON, redrawTrendCharts);
+ echartsJenkinsApi.renderZoomableTrendChart('health-trend-chart', lineModel.responseJSON, redrawTrendCharts);
});
}
}
