From cd2dbabcdd948ebe9a14b32ad6227309979807f8 Mon Sep 17 00:00:00 2001 From: Sachin Chaurasiya Date: Mon, 7 Mar 2022 16:36:44 +0530 Subject: [PATCH] Fix #3208 Data Quality - Blank profiler page (#3211) --- .../TableProfiler/TableProfiler.component.tsx | 11 +-------- .../ui/src/constants/profiler.constant.ts | 23 +++++++++++++++++++ 2 files changed, 24 insertions(+), 10 deletions(-) create mode 100644 openmetadata-ui/src/main/resources/ui/src/constants/profiler.constant.ts diff --git a/openmetadata-ui/src/main/resources/ui/src/components/TableProfiler/TableProfiler.component.tsx b/openmetadata-ui/src/main/resources/ui/src/components/TableProfiler/TableProfiler.component.tsx index aa066fb451a..08fa6981efc 100644 --- a/openmetadata-ui/src/main/resources/ui/src/components/TableProfiler/TableProfiler.component.tsx +++ b/openmetadata-ui/src/main/resources/ui/src/components/TableProfiler/TableProfiler.component.tsx @@ -15,6 +15,7 @@ import classNames from 'classnames'; import React, { FC, Fragment } from 'react'; import { Link } from 'react-router-dom'; import { TITLE_FOR_NON_ADMIN_ACTION } from '../../constants/constants'; +import { excludedMetrics } from '../../constants/profiler.constant'; import { Table, TableProfile } from '../../generated/entity/data/table'; import { useAuth } from '../../hooks/authHooks'; import { @@ -63,16 +64,6 @@ const PercentageGraph = ({ ); }; -const excludedMetrics = [ - 'profilDate', - 'name', - 'nullCount', - 'nullProportion', - 'uniqueCount', - 'uniqueProportion', - 'rows', -]; - const TableProfiler: FC = ({ tableProfiles, columns, diff --git a/openmetadata-ui/src/main/resources/ui/src/constants/profiler.constant.ts b/openmetadata-ui/src/main/resources/ui/src/constants/profiler.constant.ts new file mode 100644 index 00000000000..8ce867b230d --- /dev/null +++ b/openmetadata-ui/src/main/resources/ui/src/constants/profiler.constant.ts @@ -0,0 +1,23 @@ +/* + * Copyright 2021 Collate + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * http://www.apache.org/licenses/LICENSE-2.0 + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +export const excludedMetrics = [ + 'profilDate', + 'name', + 'nullCount', + 'nullProportion', + 'uniqueCount', + 'uniqueProportion', + 'rows', + 'histogram', +];