aboutsummaryrefslogtreecommitdiff
path: root/modern/src/common/components
diff options
context:
space:
mode:
authorAnton Tananaev <anton@traccar.org>2022-06-13 17:04:46 -0700
committerAnton Tananaev <anton@traccar.org>2022-06-13 17:04:46 -0700
commitd171ec4d0c6a40a47af7870c40d1657da2b511e8 (patch)
tree958878149a060afcfa95779818c37532d88638e7 /modern/src/common/components
parente48d7264dec72c5daad3365e2127519fee0c8cd1 (diff)
downloadtrackermap-web-d171ec4d0c6a40a47af7870c40d1657da2b511e8.tar.gz
trackermap-web-d171ec4d0c6a40a47af7870c40d1657da2b511e8.tar.bz2
trackermap-web-d171ec4d0c6a40a47af7870c40d1657da2b511e8.zip
Hide link if network null
Diffstat (limited to 'modern/src/common/components')
-rw-r--r--modern/src/common/components/PositionValue.js5
1 files changed, 4 insertions, 1 deletions
diff --git a/modern/src/common/components/PositionValue.js b/modern/src/common/components/PositionValue.js
index cdb2c6d6..76de2862 100644
--- a/modern/src/common/components/PositionValue.js
+++ b/modern/src/common/components/PositionValue.js
@@ -88,7 +88,10 @@ const PositionValue = ({ position, property, attribute }) => {
}
return (<Link href="#" onClick={showAddress}>{t('sharedShowAddress')}</Link>);
case 'network':
- return (<Link component={RouterLink} to={`/network/${position.id}`}>{t('sharedInfoTitle')}</Link>);
+ if (value) {
+ return (<Link component={RouterLink} to={`/network/${position.id}`}>{t('sharedInfoTitle')}</Link>);
+ }
+ return '';
default:
return formatValue(value);
}