~widelands-dev/widelands-website/django_staticfiles

« back to all changes in this revision

Viewing changes to wlmaps/management.py

  • Committer: Holger Rapp
  • Date: 2010-09-26 13:30:30 UTC
  • Revision ID: sirver@gmx.de-20100926133030-ceirjf83vde91tyt
Added a simple events model to display dates on the homepage

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
 
2
 
from django.utils.translation import ugettext_noop as _
3
 
 
4
 
try:
5
 
    from notification import models as notification
6
 
 
7
 
    def create_notice_types(sender, **kwargs):
8
 
        print('Creating notice types for maps ...')
9
 
        notification.create_notice_type('maps_new_map',
10
 
                                        _('A new Map is available'),
11
 
                                        _('a new map is available for download'), 1)
12
 
except ImportError:
13
 
    print 'Skipping creation of NoticeTypes as notification app not found'