Skip to content

Commit

Permalink
pass from and to config option only along, if they are set
Browse files Browse the repository at this point in the history
  • Loading branch information
klaernie committed Apr 2, 2023
1 parent ec5adc9 commit a594223
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions MMM-GrafanaChart.js
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,12 @@ Module.register("MMM-GrafanaChart", {
URL += "/" + this.config.dashboardname;
URL += "?orgId=" + this.config.orgId;
URL += "&panelId=" + this.config.panelId;
URL += "&from=" + this.config.from;
URL += "&to=" + this.config.to
if( this.config.from ){
URL += "&from=" + this.config.from;
}
if( this.config.to ){
URL += "&to=" + this.config.to
}
if (this.config.version == "6") {
URL += "&fullscreen&kiosk";
}
Expand Down

0 comments on commit a594223

Please sign in to comment.