Switch to unified view

a/ForgeClassic/sfx/mailman.py b/ForgeClassic/sfx/mailman.py
...
...
3
3
4
from tg import expose, redirect, validate, flash
4
from tg import expose, redirect, validate, flash
5
from tg.decorators import with_trailing_slash, without_trailing_slash
5
from tg.decorators import with_trailing_slash, without_trailing_slash
6
from pylons import c
6
from pylons import c
7
7
8
from allura.app import DefaultAdminController
8
from allura.app import DefaultAdminController, SitemapEntry
9
from allura.lib import helpers as h
9
from allura.lib import helpers as h
10
10
11
from . import widgets
11
from . import widgets
12
from . import model as SM
12
from . import model as SM
13
from .app_base import SFXBaseApp
13
from .app_base import SFXBaseApp
...
...
63
63
64
        @expose()
64
        @expose()
65
        def _lookup(self, name, *remainder):
65
        def _lookup(self, name, *remainder):
66
            return ListAdmin(SM.List(name)), remainder
66
            return ListAdmin(SM.List(name)), remainder
67
67
68
    @property
69
    @h.exceptionless([], log)
70
    def sitemap(self):
71
        result = []
72
        for lst in SM.List.find():
73
            result.append(SitemapEntry(lst.name, lst.info_url))
74
        return result
75
68
class ListAdmin(object):
76
class ListAdmin(object):
69
77
70
    def __init__(self, mailing_list):
78
    def __init__(self, mailing_list):
71
        self._list = mailing_list
79
        self._list = mailing_list
72
        self.subscribers = ListSubscribers(mailing_list)
80
        self.subscribers = ListSubscribers(mailing_list)