예제 #1
0
파일: blog.py 프로젝트: lypinggan/adoa
 def _get_author(self):
     if self._author:
         self._author.website = None
         return self._author
     return storage(email = self.email, 
                    nickname = self.nickname, 
                    website = self.website)
예제 #2
0
파일: blog.py 프로젝트: lypinggan/adoa
    def as_data(self):

        comments = [storage({'author':comment.author,
                     'parent':comment.parent,
                     'comment':comment.comment,
                     }) for comment in self.all()]

        return comments
예제 #3
0
파일: blog.py 프로젝트: lypinggan/adoa
 def item(self):
     return storage(self.json)