Wiki Views

inyoka.wiki.views

The views for the wiki. Unlike the other applications the wiki doesn’t really use the views but actions. This is the case because we only have one kind of page which is a wiki page. Non existing pages render a replacement message to create one, so not much to dispatch.

Some internal functions such as the image serving are implemented as views too because they do not necessarily work on page objects.

copyright:
  1. 2007-2024 by the Inyoka Team, see AUTHORS for more details.

license:

BSD, see LICENSE for more details.

class inyoka.wiki.views.WikiAtomFeed

Atom feed with revisions of the whole wiki.

_subtitle(__)

Small helper which returns the subtitle content. Modify it in the subclass.

item_author_name(rev)
item_categories(rev)
item_comments(rev)
item_description(rev)
item_pubdate(rev)
item_title(rev)
item_updateddate(rev)
items(*args)
name = 'wiki_feed'
supports_modes = False
title = 'ubuntuusers.local:8080 wiki last changes'
class inyoka.wiki.views.WikiPageAtomFeed

Atom feed with revisions of one wiki page.

_subtitle(page)

Small helper which returns the subtitle content. Modify it in the subclass.

get_object(request, *args, **kwargs)
items(page)
title(page)

str(object=’’) -> str str(bytes_or_buffer[, encoding[, errors]]) -> str

Create a new string object from the given object. If encoding or errors is specified, then the object must expose a data buffer that will be decoded using the given encoding and error handler. Otherwise, returns the result of object.__str__() (if defined) or repr(object). encoding defaults to sys.getdefaultencoding(). errors defaults to ‘strict’.

inyoka.wiki.views.fetch_real_target(target, width=None, height=None, force=False)

Return the uri to a image

inyoka.wiki.views.get_attachment(request)

Get an attachment directly and do privilege check.

inyoka.wiki.views.get_image_resource(request)

Deliver the attachment as image. This is used by the Picture macro mainly. The idea is that we can still check privileges and that the image URL does not change if a new revision is uploaded.

inyoka.wiki.views.index(request)

Wiki index is a redirect to the settings.WIKI_MAIN_PAGE.

inyoka.wiki.views.missingpages(request, *args, **kwargs)

Show a table of links to missing pages and where they are located.

inyoka.wiki.views.randompages(request, *args, **kwargs)

Show a list of random wiki articles.

inyoka.wiki.views.recentchanges(request, *args, **kwargs)

Show a table of the recent changes.

inyoka.wiki.views.redirect_new_page(request)

Helper for the NewPage macro.

inyoka.wiki.views.show_pages_by_tag(request, *args, **kwargs)

Show a list of wiki pages that are tagged with the specified key word.

inyoka.wiki.views.show_tag_cloud(request, *args, **kwargs)

Show a tag cloud of the 100 most used tags.

inyoka.wiki.views.show_tag_list(request, *args, **kwargs)

Show an alphabetical tag list with all wiki tags.