mirror of
https://github.com/open-metadata/OpenMetadata.git
synced 2025-11-13 09:23:45 +00:00
parent
b09744fdb3
commit
c6379cd95f
@ -13,6 +13,7 @@ import { TitleBreadcrumbProps } from '../title-breadcrumb/title-breadcrumb.inter
|
|||||||
type ExtraInfo = {
|
type ExtraInfo = {
|
||||||
key?: string;
|
key?: string;
|
||||||
value: string | number;
|
value: string | number;
|
||||||
|
isLink?: boolean;
|
||||||
};
|
};
|
||||||
|
|
||||||
type Props = {
|
type Props = {
|
||||||
@ -108,7 +109,25 @@ const EntityPageInfo = ({
|
|||||||
{info.key} :
|
{info.key} :
|
||||||
</span>{' '}
|
</span>{' '}
|
||||||
<span className="tw-pl-1 tw-font-normal">
|
<span className="tw-pl-1 tw-font-normal">
|
||||||
{info.value || '--'}
|
{info.isLink ? (
|
||||||
|
<a
|
||||||
|
className="link-text"
|
||||||
|
href={info.value as string}
|
||||||
|
rel="noopener noreferrer"
|
||||||
|
target="_blank">
|
||||||
|
<>
|
||||||
|
<span className="tw-mr-1">{info.value}</span>
|
||||||
|
<SVGIcons
|
||||||
|
alt="external-link"
|
||||||
|
className="tw-align-middle"
|
||||||
|
icon="external-link"
|
||||||
|
width="12px"
|
||||||
|
/>
|
||||||
|
</>
|
||||||
|
</a>
|
||||||
|
) : (
|
||||||
|
info.value || '--'
|
||||||
|
)}
|
||||||
</span>
|
</span>
|
||||||
{extraInfo.length !== 1 && index < extraInfo.length - 1 ? (
|
{extraInfo.length !== 1 && index < extraInfo.length - 1 ? (
|
||||||
<span className="tw-mx-3 tw-inline-block tw-text-gray-400">
|
<span className="tw-mx-3 tw-inline-block tw-text-gray-400">
|
||||||
|
|||||||
@ -68,6 +68,7 @@ const MyDashBoardPage = () => {
|
|||||||
const [activeTab, setActiveTab] = useState<number>(1);
|
const [activeTab, setActiveTab] = useState<number>(1);
|
||||||
const [isEdit, setIsEdit] = useState<boolean>(false);
|
const [isEdit, setIsEdit] = useState<boolean>(false);
|
||||||
const [charts, setCharts] = useState<ChartType[]>([]);
|
const [charts, setCharts] = useState<ChartType[]>([]);
|
||||||
|
const [dashboardUrl, setDashboardUrl] = useState<string>('');
|
||||||
// const [usage, setUsage] = useState('');
|
// const [usage, setUsage] = useState('');
|
||||||
// const [weeklyUsageCount, setWeeklyUsageCount] = useState('');
|
// const [weeklyUsageCount, setWeeklyUsageCount] = useState('');
|
||||||
const [slashedDashboardName, setSlashedDashboardName] = useState<
|
const [slashedDashboardName, setSlashedDashboardName] = useState<
|
||||||
@ -117,6 +118,7 @@ const MyDashBoardPage = () => {
|
|||||||
const extraInfo = [
|
const extraInfo = [
|
||||||
{ key: 'Owner', value: owner?.name || '' },
|
{ key: 'Owner', value: owner?.name || '' },
|
||||||
{ key: 'Tier', value: tier ? tier.split('.')[1] : '' },
|
{ key: 'Tier', value: tier ? tier.split('.')[1] : '' },
|
||||||
|
{ key: 'Dashboard Url', value: dashboardUrl, isLink: true },
|
||||||
// { key: 'Usage', value: usage },
|
// { key: 'Usage', value: usage },
|
||||||
// { key: 'Queries', value: `${weeklyUsageCount} past week` },
|
// { key: 'Queries', value: `${weeklyUsageCount} past week` },
|
||||||
];
|
];
|
||||||
@ -178,6 +180,7 @@ const MyDashBoardPage = () => {
|
|||||||
owner,
|
owner,
|
||||||
displayName,
|
displayName,
|
||||||
charts,
|
charts,
|
||||||
|
dashboardUrl,
|
||||||
// usageSummary,
|
// usageSummary,
|
||||||
} = res.data;
|
} = res.data;
|
||||||
setDashboardDetails(res.data);
|
setDashboardDetails(res.data);
|
||||||
@ -218,6 +221,7 @@ const MyDashBoardPage = () => {
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
);
|
);
|
||||||
|
setDashboardUrl(dashboardUrl);
|
||||||
fetchCharts(charts).then((charts) => setCharts(charts));
|
fetchCharts(charts).then((charts) => setCharts(charts));
|
||||||
// if (!isNil(usageSummary?.weeklyStats.percentileRank)) {
|
// if (!isNil(usageSummary?.weeklyStats.percentileRank)) {
|
||||||
// const percentile = getUsagePercentile(
|
// const percentile = getUsagePercentile(
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user