org.views.page

Renders a onegov.page.

Classes

AtomLinkInRSSExtension

Basic FeedGenerator extension.

Functions

delete_page(→ None)

view_topic(→ onegov.core.types.RenderData | webob.Response)

view_news_collection(...)

view_news(→ onegov.core.types.RenderData | webob.Response)

generate_rss_feed(→ str)

Module Contents

org.views.page.delete_page(self: onegov.org.models.Topic | onegov.org.models.News, request: onegov.org.request.OrgRequest) None[source]
org.views.page.view_topic(self: onegov.org.models.Topic, request: onegov.org.request.OrgRequest, layout: onegov.org.layout.PageLayout | None = None) onegov.core.types.RenderData | webob.Response[source]
org.views.page.view_news_collection(self: onegov.org.models.NewsCollection, request: onegov.org.request.OrgRequest, layout: onegov.org.layout.NewsLayout | None = None) onegov.core.types.RenderData | webob.Response[source]
org.views.page.view_news(self: onegov.org.models.News, request: onegov.org.request.OrgRequest, layout: onegov.org.layout.NewsLayout | None = None) onegov.core.types.RenderData | webob.Response[source]
class org.views.page.AtomLinkInRSSExtension[source]

Bases: feedgen.ext.base.BaseExtension

Basic FeedGenerator extension.

fg[source]
extend_rss(feed: lxml.etree._Element) lxml.etree._Element[source]

Extend a RSS feed xml structure containing all previously set fields.

Parameters:

feed – The feed xml root element.

Returns:

The feed root element.

org.views.page.generate_rss_feed(items: list[dict[str, str | bool]], request_url: str, prev_url: str | None, next_url: str | None, feed_title: str, language: str = 'de_CH') str[source]