replaced hard coded urls with setting

parent 38d6573f
......@@ -1873,8 +1873,9 @@ class UpdatesOnOrganizationFeed(Feed):
# item_link is only needed if NewsItem has no get_absolute_url method.
# unique links are required to properly display a feed.
def item_link(self, item):
return "https://faalkaart.nl/#report-%s/%s/%s/%s" % \
(item["organization_id"], item["url"], item["service"], item["rating_determined_on"])
return "%s/#report-%s/%s/%s/%s" % \
(config.PROJECT_WEBSITE,
item["organization_id"], item["url"], item["service"], item["rating_determined_on"])
# @cache_page(ten_minutes), you can't cache this using the decorator.
......@@ -1949,10 +1950,10 @@ class LatestScanFeed(Feed):
def item_link(self, item):
if item.type in ["DNSSEC"]:
# url generic scan:
return "https://faalkaart.nl/#updates/%s/%s" % (item.last_scan_moment, item.url.url)
return "%s/#updates/%s/%s" % (config.PROJECT_WEBSITE, item.last_scan_moment, item.url.url)
else:
# endpoint scan
return "https://faalkaart.nl/#updates/%s/%s" % (item.last_scan_moment, item.endpoint.url.url)
return "%s/#updates/%s/%s" % (config.PROJECT_WEBSITE, item.last_scan_moment, item.endpoint.url.url)
def organization_autcomplete(request, country: str = "NL", organization_type="municipality", parameter: str = ""):
......
......@@ -649,7 +649,7 @@ CONSTANCE_CONFIG = {
'PROJECT_NAME': ('', 'The name of this mapping project, used for branding and promotion.', str),
'PROJECT_COUNTRY': ('NL', 'Two letter ISO code of the country that should be shown.', str),
'PROJECT_TAGLINE': ('', 'Tagline for this project.', str),
'PROJECT_WEBSITE': ('', 'The url where this site is located.', str),
'PROJECT_WEBSITE': ('', 'The url where this site is located. Without trailing slash. Eg: https://example.com', str),
'PROJECT_MAIL': ('', 'The address where people can contact for more info about this project.', str),
'PROJECT_ISSUE_MAIL': ('', 'The address where people can mail when they encounter issues, for example when they '
'are using the incorrect findings button.', str),
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment