A simple way for objects to subscribe to other objects for a "feed-like" functionality in a Django project
A simple way for objects to subscribe to other objects for a “feed-like” functionality in a Django project.
pip install django-generic-feeds
Run setup.py install or add to your Python path and include 'feeds' in your INSTALLED_APPS setting.
Make a new feed:
from feeds.models import Feed feed = Feed.objects.create()
Add a subscription to a feed:
from myapp.models import Event event = Event.objects.get(pk=36) feed.add_subscription(event)
Then you can add an activity:
from feeds.models import add_activity add_activity(actor=request.user, verb='attended', obj=event)
Then the feed’s activity will be populated with this activity:
See the source code for more.
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Hashes for django-generic-feeds-0.1.5.tar.gz