Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge commit 'django-friends/master'
Conflicts: friends/forms.py friends/models.py
- Loading branch information
Showing
5 changed files
with
63 additions
and
41 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
recursive-include friends/templates/notification * |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,18 +1,18 @@ | ||
from django.conf import settings | ||
from django.db.models import signals | ||
|
||
from django.utils.translation import ugettext_noop as _ | ||
|
||
try: | ||
if "notification" in settings.INSTALLED_APPS: | ||
from notification import models as notification | ||
|
||
def create_notice_types(app, created_models, verbosity, **kwargs): | ||
notification.create_notice_type("friends_invite", _("Invitation Received"), _("you have received an invitation"), default=2) | ||
notification.create_notice_type("friends_invite_sent", _("Invitation Sent"), _("you have sent an invitation"), default=1) | ||
notification.create_notice_type("friends_accept", _("Acceptance Received"), _("an invitation you sent has been accepted"), default=2) | ||
notification.create_notice_type("friends_accept_sent", _("Acceptance Sent"), _("you have accepted an invitation you received"), default=1) | ||
notification.create_notice_type("friends_otherconnect", _("Other Connection"), _("one of your friends has a new connection"), default=2) | ||
notification.create_notice_type("join_accept", _("Join Invitation Accepted"), _("an invitation you sent to join this site has been accepted"), default=2) | ||
|
||
signals.post_syncdb.connect(create_notice_types, sender=notification) | ||
except ImportError: | ||
else: | ||
print "Skipping creation of NoticeTypes as notification app not found" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters