diff options
| author | bwarsaw | 2001-08-20 15:09:21 +0000 |
|---|---|---|
| committer | bwarsaw | 2001-08-20 15:09:21 +0000 |
| commit | 0ab9466f243627b7ffbe47d48ff7781c0771d2f7 (patch) | |
| tree | d7b998b434c974f611bba6de70076dbad307b3de /Mailman | |
| parent | 3b8ebed48d82f26d013bae4944ab3d1bdae7199d (diff) | |
| download | mailman-0ab9466f243627b7ffbe47d48ff7781c0771d2f7.tar.gz mailman-0ab9466f243627b7ffbe47d48ff7781c0771d2f7.tar.zst mailman-0ab9466f243627b7ffbe47d48ff7781c0771d2f7.zip | |
admin_overview(): Use get_domain() instead of hardcoded
DEFAULT_HOST_NAME to get the hostname.
Also, do the same kind of virtual host filtering for the admin
overview as we do in the listinfo overview. This more clearly
separates the virtual domains (there perhaps should be a site
overview).
Diffstat (limited to 'Mailman')
| -rw-r--r-- | Mailman/Cgi/admin.py | 13 |
1 files changed, 11 insertions, 2 deletions
diff --git a/Mailman/Cgi/admin.py b/Mailman/Cgi/admin.py index f5b1680b3..95e46212c 100644 --- a/Mailman/Cgi/admin.py +++ b/Mailman/Cgi/admin.py @@ -199,7 +199,7 @@ def admin_overview(msg=''): # # This page should be displayed in the server's default language, which # should have already been set. - hostname = mm_cfg.DEFAULT_HOST_NAME + hostname = Utils.get_domain() legend = _('%(hostname)s mailing lists - Admin Links') # The html `document' doc = Document() @@ -214,10 +214,19 @@ def admin_overview(msg=''): advertised = [] listnames = Utils.list_names() listnames.sort() + for name in listnames: mlist = MailList.MailList(name, lock=0) if mlist.advertised: - advertised.append(mlist) + if mm_cfg.VIRTUAL_HOST_OVERVIEW and \ + hostname and \ + hostname.find(mlist.web_page_url) == -1 and \ + mlist.web_page_url.find(hostname) == -1: + # List is for different identity of this host - skip it. + continue + else: + advertised.append(mlist) + # Greeting depends on whether there was an error or not if msg: greeting = FontAttr(msg, color="ff5060", size="+1") |
