views: Don't require sending diagnostics module name separately

- Reuse the app_id already available to the view.

- Implement automatically detecting if an app has implemented diagnostics.

Signed-off-by: Sunil Mohan Adapa <sunil@medhas.org>
Reviewed-by: James Valleroy <jvalleroy@mailbox.org>
This commit is contained in:
Sunil Mohan Adapa authored and James Valleroy committed 2019-12-30 11:38:02 -05:00
1 parent 636aa05b66
commit f65b4ec407
36 files changed
+12 -39

No files matched your search

+2 -1
View File
@@ -38,11 +38,12 @@ def index(request):
status = letsencrypt.get_status()
return TemplateResponse(
request, 'letsencrypt.html', {
'app_id': 'letsencrypt',
'name': letsencrypt.name,
'description': letsencrypt.description,
'status': status,
'manual_page': letsencrypt.manual_page,
'diagnostics_module_name': 'letsencrypt',
'has_diagnostics': True,
'is_enabled': letsencrypt.app.is_enabled(),
})