Exemplo n.º 1
0
Arquivo: index.py Projeto: supor/vlog
 def render(self, template_path, **kwargs):
     tags = Logic.tag.get_tags()
     categories = Logic.category.get_categories()
     pl = Logic.post
     kwargs['comments'] = Logic.comment.get_last_comments()
     kwargs['tags'] = tags.get('data')
     kwargs['new'] = pl.get_new()
     kwargs['months'] = pl.get_months()
     kwargs['categories'] = categories.get('data')
     kwargs['SITE_TITLE'] = self.option.site_title
     kwargs['SITE_SUB_TITLE'] = self.option.sub_title
     kwargs["links"] = Logic.link.get_all_links()
     if not kwargs.has_key("description"):
         kwargs['description'] = self.option.description
     if not kwargs.has_key("keywords"):
         kwargs['keywords'] = self.option.keywords
     kwargs['page'] = Logic.page.get_all_pages()
     kwargs['uid'] = self.uid
     kwargs['username'] = self.username
     self.logger.debug("%r", kwargs)
     BaseHandler.render(self, template_path, **kwargs)
Exemplo n.º 2
0
 def render(self, template_path, **kwargs):
     tags = Logic.tag.get_tags()
     categories = Logic.category.get_categories()
     pl = Logic.post
     kwargs['comments'] = Logic.comment.get_last_comments()
     kwargs['tags'] = tags.get('data')
     kwargs['new'] = pl.get_new()
     kwargs['months'] = pl.get_months()
     kwargs['categories'] = categories.get('data')
     kwargs['SITE_TITLE'] = self.option.site_title
     kwargs['SITE_SUB_TITLE'] = self.option.sub_title
     kwargs["links"] = Logic.link.get_all_links()
     if not kwargs.has_key("description"):
         kwargs['description'] = self.option.description
     if not kwargs.has_key("keywords"):
         kwargs['keywords'] = self.option.keywords
     kwargs['page'] = Logic.page.get_all_pages()
     kwargs['uid'] = self.uid
     kwargs['username'] = self.username
     self.logger.debug("%r", kwargs)
     BaseHandler.render(self, template_path, **kwargs)
Exemplo n.º 3
0
Arquivo: admin.py Projeto: supor/vlog
 def render(self, template_path, **kwargs):
     kwargs['SITE_TITLE'] = self.option.site_title
     kwargs['SITE_SUB_TITLE'] = self.option.sub_title
     BaseHandler.render(self, template_path, **kwargs)
Exemplo n.º 4
0
 def render(self, template_path, **kwargs):
     kwargs['SITE_TITLE'] = self.option.site_title
     kwargs['SITE_SUB_TITLE'] = self.option.sub_title
     BaseHandler.render(self, template_path, **kwargs)