mirror of
https://github.com/apache/superset.git
synced 2024-09-12 00:29:39 -04:00
fix: click card view link to 404 page when card rendering(#15526)
This commit is contained in:
parent
2cb13e695e
commit
b20293d1b1
@ -137,7 +137,7 @@ interface LinkProps {
|
|||||||
}
|
}
|
||||||
|
|
||||||
const AnchorLink: React.FC<LinkProps> = ({ to, children }) => (
|
const AnchorLink: React.FC<LinkProps> = ({ to, children }) => (
|
||||||
<a href={to}>{children}</a>
|
<a {...(to ? { href: to } : {})}>{children}</a>
|
||||||
);
|
);
|
||||||
|
|
||||||
interface CardProps {
|
interface CardProps {
|
||||||
|
@ -134,7 +134,7 @@ export default function ChartCard({
|
|||||||
return (
|
return (
|
||||||
<CardStyles
|
<CardStyles
|
||||||
onClick={() => {
|
onClick={() => {
|
||||||
if (!bulkSelectEnabled) {
|
if (!bulkSelectEnabled && chart.url) {
|
||||||
window.location.href = chart.url;
|
window.location.href = chart.url;
|
||||||
}
|
}
|
||||||
}}
|
}}
|
||||||
|
Loading…
Reference in New Issue
Block a user