mirror of
https://github.com/grafana/grafana.git
synced 2025-02-11 16:15:42 -06:00
DashboardScene: Do not hide variables on save (#81501)
This commit is contained in:
parent
f77c831e3f
commit
9982830bd7
@ -494,7 +494,6 @@ exports[`transformSceneToSaveModel Given a simple scene with custom settings Sho
|
||||
"text": "1m",
|
||||
"value": "1m",
|
||||
},
|
||||
"hide": 2,
|
||||
"name": "intervalVar",
|
||||
"query": "1m,10m,30m,1h,6h,12h,1d,7d,14d,30d",
|
||||
"refresh": 2,
|
||||
@ -812,7 +811,6 @@ exports[`transformSceneToSaveModel Given a simple scene with variables Should tr
|
||||
"text": "1m",
|
||||
"value": "1m",
|
||||
},
|
||||
"hide": 2,
|
||||
"name": "intervalVar",
|
||||
"query": "1m,10m,30m,1h,6h,12h,1d,7d,14d,30d",
|
||||
"refresh": 2,
|
||||
|
@ -336,7 +336,6 @@ describe('sceneVariablesSetToVariables', () => {
|
||||
"value": "text value",
|
||||
},
|
||||
"description": "test-desc",
|
||||
"hide": 2,
|
||||
"label": "test-label",
|
||||
"name": "test",
|
||||
"query": "text value",
|
||||
|
@ -34,7 +34,6 @@ export function sceneVariablesSetToVariables(set: SceneVariables) {
|
||||
includeAll: variable.state.includeAll,
|
||||
multi: variable.state.isMulti,
|
||||
skipUrlSync: variable.state.skipUrlSync,
|
||||
hide: variable.state.hide || VariableHide.dontHide,
|
||||
});
|
||||
} else if (sceneUtils.isCustomVariable(variable)) {
|
||||
variables.push({
|
||||
@ -90,7 +89,6 @@ export function sceneVariablesSetToVariables(set: SceneVariables) {
|
||||
value: variable.state.value,
|
||||
},
|
||||
query: intervals,
|
||||
hide: VariableHide.hideVariable,
|
||||
refresh: variable.state.refresh,
|
||||
// @ts-expect-error ?? how to fix this without adding the ts-expect-error
|
||||
auto: variable.state.autoEnabled,
|
||||
@ -105,7 +103,6 @@ export function sceneVariablesSetToVariables(set: SceneVariables) {
|
||||
value: variable.state.value,
|
||||
},
|
||||
query: variable.state.value,
|
||||
hide: VariableHide.hideVariable,
|
||||
});
|
||||
} else {
|
||||
throw new Error('Unsupported variable type');
|
||||
|
Loading…
Reference in New Issue
Block a user