Skip to content

Instantly share code, notes, and snippets.

@ir4y
Last active August 29, 2015 14:02
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save ir4y/39a9c0cfd4f621982e05 to your computer and use it in GitHub Desktop.
Save ir4y/39a9c0cfd4f621982e05 to your computer and use it in GitHub Desktop.
def index(request):
@cached_as(News.objects.all()) #Что тут написать что бы так же работала инвалидация для Tag ?
def _index():
c = {'news':News.objects.all(),
'tags':Tag.objects.all()}
return render("index.html", c)
return _index()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment