Fixed imports in `Sitemap for static views` example

This commit is contained in:
John-Scott Atlakson 2014-09-04 21:04:53 -04:00
parent 2ca244aae6
commit 344f37718b
1 changed files with 3 additions and 3 deletions

View File

@ -314,11 +314,8 @@ the sitemap. For example::
# sitemaps.py # sitemaps.py
from django.contrib import sitemaps from django.contrib import sitemaps
from django.contrib.sitemaps.views import sitemap
from django.core.urlresolvers import reverse from django.core.urlresolvers import reverse
from . import views
class StaticViewSitemap(sitemaps.Sitemap): class StaticViewSitemap(sitemaps.Sitemap):
priority = 0.5 priority = 0.5
changefreq = 'daily' changefreq = 'daily'
@ -331,7 +328,10 @@ the sitemap. For example::
# urls.py # urls.py
from django.conf.urls import url from django.conf.urls import url
from django.contrib.sitemaps.views import sitemap
from .sitemaps import StaticViewSitemap from .sitemaps import StaticViewSitemap
from . import views
sitemaps = { sitemaps = {
'static': StaticViewSitemap, 'static': StaticViewSitemap,