Example #1
0
def blog_list(ea=''):
    if not ea:
        ea = api.echolist()[0]
    blogs = api.lst('et/%s' % ea)
    comms = mydict({n:len(api.lst('topic/%s' % n))-6 for n in blogs})
    pge = request.query.page or '1'
    return template ('blog-list.html',ea=ea,blogs=blogs,comms=comms,pge=int(pge)-1)
Example #2
0
def list_txt():
    out = ''
    response.content_type = 'text/plain; charset=utf-8'
    for n in api.echolist():
        out += '%s:%s:%s\n' % (n, len(api.get_ea(n)), api.echo_desc(n)
                               or 'no desc')
    return out
Example #3
0
def forum_list(ea=''):
    if not ea:
        ea = api.echolist()[0]
    pge = request.query.page or '1'
    return template('forum-list.html',out=api.forum_list(ea),ea=ea,u=u(),pge=int(pge)-1)
Example #4
0
def blog_select():
    return template('select-blog.html',
                    u=u(),
                    ea='',
                    out=[(n, len(api.lst('e/%s' % n)), api.echo_desc(n)
                          or 'no desc') for n in api.echolist()])