def GET(self):
     web.header('Content-Type', 'text/xml;charset=utf-8')
     posts = post_service.get_all_published()
     pages = page_service.get_all_published()
     tags = tag_service.get_all()
     archives = post_service.get_archives()
     return render.sitemap(posts,pages,tags,archives)
Esempio n. 2
0
 def GET(self):
     posts = post_service.get_all_published()
     _archives = post_service.get_archives()
     archives = []
     tags = tag_service.get_published()
     for archive in _archives:
         archives.append(
             {
                 "full_month": calendar.month_name[archive.month],
                 "month": archive.month,
                 "year": archive.year,
                 "posts_count": archive.posts_count,
             }
         )
     return render.archive(posts, tags, archives)