Exemple #1
0
def select_page(field_name='page', select=None, exclude=[], functions=[],
                list_limit=500, allow_empty=True, include_sectionpages=False):
    return render_tile('/page/tiles.html', 'select_page', None, select=select,
                       exclude=exclude, field_name=field_name,
                       functions=functions,
                       list_limit=list_limit, allow_empty=allow_empty,
                       include_sectionpages=include_sectionpages)
Exemple #2
0
def variants(selection, tile=None):
    if tile is None:
        tile = SelectionTile(selection)
    return render_tile('/selection/tiles.html',
                       'variants',
                       tile,
                       selection=selection,
                       user=c.user,
                       cached=True)
def inline(page, tile=None, text=None, subpages_pager=None,
           hide_discussion=False):
    if tile is None:
        tile = PageTile(page)
    if text is None:
        text = page.head
    return render_tile('/page/tiles.html', 'inline', tile, page=page,
                       hide_discussion=hide_discussion, text=text,
                       subpages_pager=subpages_pager)
def header(page, tile=None, active='goal', text=None, variant=None):
    if tile is None:
        tile = PageTile(page)
    if text is None:
        text = page.head
    if variant is None:
        variant = text.variant
    return render_tile('/page/tiles.html', 'header', tile,
                       page=page, text=text, variant=variant, active=active)
Exemple #5
0
def row(selection):
    if not selection or selection.is_deleted():
        return ""
    tile = SelectionTile(selection)
    return render_tile('/selection/tiles.html',
                       'row',
                       tile,
                       selection=selection,
                       user=c.user,
                       cached=True)
Exemple #6
0
def header(page, tile=None, active='goal', text=None, variant=None):
    if tile is None:
        tile = PageTile(page)
    if text is None:
        text = page.head
    if variant is None:
        variant = text.variant
    return render_tile('/page/tiles.html',
                       'header',
                       tile,
                       page=page,
                       text=text,
                       variant=variant,
                       active=active)
Exemple #7
0
def select_page(field_name='page',
                select=None,
                exclude=[],
                functions=[],
                list_limit=500,
                allow_empty=True):
    return render_tile('/page/tiles.html',
                       'select_page',
                       None,
                       select=select,
                       exclude=exclude,
                       field_name=field_name,
                       functions=functions,
                       list_limit=list_limit,
                       allow_empty=allow_empty)
Exemple #8
0
def inline(page,
           tile=None,
           text=None,
           subpages_pager=None,
           hide_discussion=False):
    if tile is None:
        tile = PageTile(page)
    if text is None:
        text = page.head
    return render_tile('/page/tiles.html',
                       'inline',
                       tile,
                       page=page,
                       hide_discussion=hide_discussion,
                       text=text,
                       subpages_pager=subpages_pager)
Exemple #9
0
def row(event):
    return render_tile('/event/tiles.html', 'row',
                       EventTile(event), event=event, cached=True)
Exemple #10
0
def smallrow(page):
    return render_tile('/page/tiles.html',
                       'smallrow',
                       PageTile(page),
                       page=page,
                       cached=True)
Exemple #11
0
def row(tag):
    return render_tile('/tag/tiles.html', 'row', TagTile(tag),
                       tag=tag, cached=True)
Exemple #12
0
def smallrow(page):
    return render_tile('/page/tiles.html', 'smallrow', PageTile(page),
                       page=page, cached=True)
Exemple #13
0
def event_row(event, row_type):
    return render_tile('/event/tiles.html',
                       row_type,
                       EventTile(event),
                       event=event,
                       cached=True)
Exemple #14
0
def event_row(event, row_type):
    return render_tile('/event/tiles.html', row_type,
                       EventTile(event), event=event, cached=True)
def row(selection):
    if selection is None or selection.is_deleted():
                return ""
    tile = SelectionTile(selection)
    return render_tile('/selection/tiles.html', 'row', tile,
                       selection=selection, user=c.user, cached=True)
def variants(selection, tile=None):
    if tile is None:
        tile = SelectionTile(selection)
    return render_tile('/selection/tiles.html', 'variants', tile,
                       selection=selection, user=c.user, cached=True)
Exemple #17
0
def row(event):
    return render_tile('/event/tiles.html', 'row',
                       EventTile(event), event=event, cached=True)