mirror of
https://github.com/grafana/grafana.git
synced 2024-11-22 08:56:43 -06:00
Graph: Fix setting right y-axis when standard option unit is configured (#32426)
This commit is contained in:
parent
20f6ba5ba4
commit
33e33e3872
@ -51,9 +51,9 @@ export class AxesEditorCtrl {
|
||||
setUnitFormat(axis: { format: any }) {
|
||||
return (unit: string) => {
|
||||
axis.format = unit;
|
||||
// if already set via field config we need to update that as well
|
||||
// if already set via field config we clear that
|
||||
if (this.panel.fieldConfig.defaults.unit) {
|
||||
this.panel.fieldConfig.defaults.unit = unit;
|
||||
this.panel.fieldConfig.defaults.unit = undefined;
|
||||
this.panelCtrl.refresh();
|
||||
} else {
|
||||
this.panelCtrl.render();
|
||||
|
Loading…
Reference in New Issue
Block a user