Definition of the discussion class.
The context for a specific IdeaLoom discussion.
Most platform entities exist in the scope of a discussion, and inherit from
Return the admin source for this discussion. Used by notifications Very naive temporary implementation, to be revised with a proper relationship later
:use_api2 - uses API2 URL path pass as many nodes you want in the args
What is the URL where we expect to find this resource
Get the base URL of this server
Tied to discussion so that we can support virtual hosts or communities in the future and access the urls when we can’t rely on pyramid’s current request (such as when celery generates notifications) Temporarily equivalent to get_global_base_url
Returns a list of SQLA expressions that constrain a query on this class to a given discussion.
Get the ID of an associated discussion object, if any.
Reset all notification subscriptions for this discussion
returns a couple (query, usable), with a sqla query for conflicting similar objects. usable is true if the query has to be enforced; sometimes it makes sense to return un-usable query that will be used to construct queries of subclasses. Note that when a duplicate is found, you’ll often want to expunge the original.
slugify_topic_if_slug_is_empty(discussion, topic, oldvalue, initiator)¶
if the target doesn’t have a slug, slugify the topic and use that.