Fixed imports in `Sitemap for static views` example
This commit is contained in:
parent
2ca244aae6
commit
344f37718b
|
@ -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,
|
||||||
|
|
Loading…
Reference in New Issue