diff --git a/plugins/edsm.py b/plugins/edsm.py index 90066ee4..1f25f76d 100644 --- a/plugins/edsm.py +++ b/plugins/edsm.py @@ -57,6 +57,9 @@ STATION_UNDOCKED: str = '×' # "Station" name to display when not docked = U+00 # Main window clicks def system_url(system_name): + if this.system_address: + return requests.utils.requote_uri(f'https://www.edsm.net/en/system?systemID64={this.system_address}') + if system_name: return requests.utils.requote_uri(f'https://www.edsm.net/en/system?systemName={system_name}') @@ -66,6 +69,10 @@ def station_url(system_name, station_name): if system_name and station_name: return requests.utils.requote_uri(f'https://www.edsm.net/en/system?systemName={system_name}&stationName={station_name}') + # monitor state might think these are gone, but we don't yet + if this.system and this.station: + return requests.utils.requote_uri(f'https://www.edsm.net/en/system?systemName={this.system}&stationName={this.station}') + if system_name: return requests.utils.requote_uri(f'https://www.edsm.net/en/system?systemName={system_name}&stationName=ALL') diff --git a/plugins/inara.py b/plugins/inara.py index 529596f9..df03207a 100644 --- a/plugins/inara.py +++ b/plugins/inara.py @@ -137,6 +137,10 @@ def station_url(system_name, station_name): if system_name and station_name: return requests.utils.requote_uri(f'https://inara.cz/galaxy-station/?search={system_name}%20[{station_name}]') + # monitor state might think these are gone, but we don't yet + if this.system and this.station: + return requests.utils.requote_uri(f'https://inara.cz/galaxy-station/?search={this.system}%20[{this.station}]') + if system_name: return system_url(system_name)