[virtualcommons-svn] commit/vcweb: alllee: applying never_cache cache-control http headers to json
Status: Beta
Brought to you by:
alllee
From: Bitbucket <com...@bi...> - 2011-08-30 22:00:01
|
1 new changeset in vcweb: http://bitbucket.org/virtualcommons/vcweb/changeset/f874f11bf8ee/ changeset: f874f11bf8ee user: alllee date: 2011-08-31 00:00:20 summary: applying never_cache cache-control http headers to json calls affected #: 2 files (105 bytes) --- a/vcweb/lighterprints/urls.py Mon Aug 22 16:24:16 2011 -0700 +++ b/vcweb/lighterprints/urls.py Tue Aug 30 15:00:20 2011 -0700 @@ -1,4 +1,5 @@ from django.conf.urls.defaults import url, patterns +from django.views.decorators.cache import never_cache from vcweb.lighterprints.views import (ActivityDetailView, ActivityListView, MobileView, post_chat_message, perform_activity, DiscussionBoardView, login, @@ -7,10 +8,10 @@ urlpatterns = patterns('vcweb.lighterprints.views', url(r'^mobile$', MobileView.as_view(), name='mobile'), url(r'^(?P<experiment_id>\d+)/configure$', 'configure', name='configure'), - url(r'^activity/list/?$', ActivityListView.as_view()), - url(r'^activity/(?P<activity_id>\d+)$', ActivityDetailView.as_view()), + url(r'^activity/list/?$', never_cache(ActivityListView.as_view())), + url(r'^activity/(?P<activity_id>\d+)$', never_cache(ActivityDetailView.as_view())), url(r'^discussion/(?P<experiment_id>\d+)/(?P<participant_id>\d+)', DiscussionBoardView.as_view()), - url(r'^api/group-activity/(?P<participant_group_id>\d+)', group_activity), + url(r'^api/group-activity/(?P<participant_group_id>\d+)', never_cache(group_activity)), url(r'^api/do-activity$', perform_activity), url(r'^api/post-chat', post_chat_message), url(r'^api/login', login), --- a/vcweb/lighterprints/views.py Mon Aug 22 16:24:16 2011 -0700 +++ b/vcweb/lighterprints/views.py Tue Aug 30 15:00:20 2011 -0700 @@ -8,7 +8,7 @@ from django.views.generic.list import BaseListView, MultipleObjectTemplateResponseMixin from vcweb.core.forms import LoginForm -from vcweb.core.models import (ChatMessage, Experiment, ParticipantGroupRelationship, ParticipantRoundDataValue) +from vcweb.core.models import (ChatMessage, ParticipantGroupRelationship, ParticipantRoundDataValue) from vcweb.core.views import JSONResponseMixin, dumps, set_authentication_token from vcweb.core.validate_jsonp import is_valid_jsonp_callback_value # FIXME: move ChatForm to core? Repository URL: https://bitbucket.org/virtualcommons/vcweb/ -- This is a commit notification from bitbucket.org. You are receiving this because you have the service enabled, addressing the recipient of this email. |