PanelInspect: Clean table display settings from field config (#71226)

* Does not work, hmm..

* now it works

* fixing and refactoring

* remove unused import
This commit is contained in:
Torkel Ödegaard
2023-07-10 16:27:03 +02:00
committed by GitHub
parent 4b3050e02e
commit 9f2baaf5c3
2 changed files with 33 additions and 5 deletions

View File

@@ -30,7 +30,8 @@ export const usePanelLatestData = (
querySubscription.current = panel
.getQueryRunner()
.getData(options)
// We apply field config later
.getData({ withTransforms: options.withTransforms, withFieldConfig: false })
.subscribe({
next: (data) => {
if (checkSchema) {
@@ -58,7 +59,7 @@ export const usePanelLatestData = (
* Otherwise, passing different references to the same object might cause troubles.
*/
// eslint-disable-next-line react-hooks/exhaustive-deps
}, [panel, options.withFieldConfig, options.withTransforms]);
}, [panel, options.withTransforms]);
return {
data: latestData,