def index():
    '\n        Module Home Page\n        - provide the list of currently-Active Problems\n    '
    redirect(URL(f='problem'))
    module_name = settings.modules[module].name_nice
    table = s3db.delphi_group
    groups = db((table.active == True)).select()
    result = []
    for group in groups:
        actions = []
        duser = s3db.delphi_DelphiUser(group)
        if duser.authorised:
            actions.append((('group/%d/update' % group.id), T('Edit')))
            actions.append((('new_problem/create/?group=%s&next=%s' % (group.id, URL(f='group_summary', args=group.id))), 'Add New Problem'))
            actions.append((('group_summary/%s/#request' % group.id), T('Review Requests')))
        else:
            actions.append((('group_summary/%s/#request' % group.id), ('Role: %s%s' % (duser.status, (((duser.membership and duser.membership.req) and '*') or '')))))
        table = s3db.delphi_problem
        query = ((table.group_id == group.id) & (table.active == True))
        latest_problems = db(query).select(orderby=(~ table.modified_on))
        result.append((group, latest_problems, actions))
    response.title = module_name
    return dict(groups_problems=result, name=T('Active Problems'), module_name=module_name)
Module Home Page
- provide the list of currently-Active Problems
def index():
    '\n        Module Home Page\n        - provide the list of currently-Active Problems\n    '
    redirect(URL(f='problem'))
    module_name = settings.modules[module].name_nice
    table = s3db.delphi_group
    groups = db((table.active == True)).select()
    result = []
    for group in groups:
        actions = []
        duser = s3db.delphi_DelphiUser(group)
        if duser.authorised:
            actions.append((('group/%d/update' % group.id), T('Edit')))
            actions.append((('new_problem/create/?group=%s&next=%s' % (group.id, URL(f='group_summary', args=group.id))), 'Add New Problem'))
            actions.append((('group_summary/%s/#request' % group.id), T('Review Requests')))
        else:
            actions.append((('group_summary/%s/#request' % group.id), ('Role: %s%s' % (duser.status, (((duser.membership and duser.membership.req) and '*') or )))))
        table = s3db.delphi_problem
        query = ((table.group_id == group.id) & (table.active == True))
        latest_problems = db(query).select(orderby=(~ table.modified_on))
        result.append((group, latest_problems, actions))
    response.title = module_name
    return dict(groups_problems=result, name=T('Active Problems'), module_name=module_name)