Welcome, guest | Sign In | My Account | Store | Cart

Notice! PyPM is being replaced with the ActiveState Platform, which enhances PyPM’s build and deploy capabilities. Create your free Platform account to download ActivePython or customize Python with the packages you require and get automatic updates.

Download
ActivePython
INSTALL>
pypm install tgapp-calendarevents

How to install tgapp-calendarevents

  1. Download and install ActivePython
  2. Open Command Prompt
  3. Type pypm install tgapp-calendarevents
 Python 2.7Python 3.2Python 3.3
Windows (32-bit)
Windows (64-bit)
Mac OS X (10.5+)
0.1.0 Available View build log
Linux (32-bit)
0.1.0 Available View build log
0.0.7 Available View build log
0.0.6 Available View build log
0.0.2 Available View build log
Linux (64-bit)
0.1.0 Available View build log
0.0.7 Available View build log
0.0.6 Available View build log
0.0.2 Available View build log
 
Lastest release
version 0.1.0 on Jun 30th, 2013

About calendarevents

calendarevents is a Pluggable calendars and events application for TurboGears2. It permits to create events which are associated to entities defined inside the application which plugs it in.

Calendarevents provides support for multiple calendars and event types, by defining new event types it is possible to define how the event relates to external entities like a blog post that describes it.

When displaying events if available weather informations for the day and location of the event will be provided.

Installing

calendarevents can be installed both from pypi or from bitbucket:

easy_install tgapp-calendarevents

should just work for most of the users

Plugging calendarevents

In your application config/app_cfg.py import plug:

from tgext.pluggable import plug

Then at the end of the file call plug with calendarevents:

plug(base_config, 'calendarevents', event_types=[...])

At least one event type must be defined inside the event_types argument. Defining event types is explained inside the Event Types section.

You will be able to access the calendars at http://localhost:8080/calendarevents.

Event Types

calendarevents needs the application to define at least one EventType to work.

Event types must be defined inheriting from the calendarevents.EventType class, for example to define an event for a concert which relates to a blog article that describes the concert itself:

class Concert(EventType):
    name = 'Concert'

    def get_linkable_entities(self, calendar):
        return [(a.uid, a.title) for a in model.DBSession.query(model.Article)]

    def get_linked_entity_info(self, event):
        return model.DBSession.query(model.Article).get(event.linked_entity_id).title

    def get_linked_entity_url(self, event):
        return tg.url('/blog/view/%s' % event.linked_entity_id)

plug(base_config, 'calendarevents', event_types=[Concert()])

Exposed Partials

calendarevents exposes a partial to render event boxes inside other pages:

  • calendarevents.partials:event(event) - Renders an event box

Subscribe to package updates

Last updated Jun 30th, 2013

Download Stats

Last month:2

What does the lock icon mean?

Builds marked with a lock icon are only available via PyPM to users with a current ActivePython Business Edition subscription.

Need custom builds or support?

ActivePython Enterprise Edition guarantees priority access to technical support, indemnification, expert consulting and quality-assured language builds.

Plan on re-distributing ActivePython?

Get re-distribution rights and eliminate legal risks with ActivePython OEM Edition.