diff --git a/context_processors.py b/context_processors.py index 603f78b..912b63f 100644 --- a/context_processors.py +++ b/context_processors.py @@ -23,6 +23,7 @@ if list.host_name == domainname: domain_lists.append(list) except: + raise Exception("No Domain Found or HTTP_HOST missing in reqeust") pass #in case there is not http_host (e.g. during testing) #return a Dict with the key used in templates diff --git a/forms.py b/forms.py index 98279d8..04597a8 100644 --- a/forms.py +++ b/forms.py @@ -732,6 +732,19 @@ label = _('Posting Address'), required = False, ) + def __init__(self,settings,visible_section,visible_option, *args, **kwargs): + super(ListSettings, self).__init__(*args, **kwargs) + if visible_option in self.layout: + self.layout = [["Option",visible_option]] + #debug + if visible_section: + sections=[] + for section in self.layout: + sections.append(section[0]) + if visible_section in sections: + for section in self.layout: + if section[0] == visible_section: + self.layout = [section] class Meta: """Class to handle the automatic insertion of fieldsets and divs. diff --git a/templates/mailman-django/base.html b/templates/mailman-django/base.html index 7d22eaf..4df888a 100644 --- a/templates/mailman-django/base.html +++ b/templates/mailman-django/base.html @@ -40,6 +40,8 @@ {% block content %}{% endblock %} + REGRESSION: + {% block links %}{% endblock %} diff --git a/templates/mailman-django/lists/settings.html b/templates/mailman-django/lists/settings.html index 8ba887d..174090a 100644 --- a/templates/mailman-django/lists/settings.html +++ b/templates/mailman-django/lists/settings.html @@ -2,14 +2,14 @@ {% load i18n %} {% block links%} -{% url list_info fqdn_listname as url_list_info %} -{% url list_delete fqdn_listname as url_list_delete %} -{% url mass_subscribe fqdn_listname as url_mass_subscription %} + {% url list_info fqdn_listname as url_list_info %} + {% url list_delete fqdn_listname as url_list_delete %} + {% url mass_subscribe fqdn_listname as url_mass_subscription %} -{% blocktrans %} -You can also subscribe or unsubscribe a user to the list "the normal way" or delete the list. If you wish to mass subscribe users to this list, please click here. -{% endblocktrans %} + {% blocktrans %} + You can also subscribe or unsubscribe a user to the list "the normal way" or delete the list. If you wish to mass subscribe users to this list, please click here. + {% endblocktrans %} {% endblock %} {% block content %} @@ -26,7 +26,6 @@ {% endif %}