コード例 #1
0
ファイル: models.py プロジェクト: jerryxing98/Tully
 def __getattr__(self, name):
     if name == "abstract":
         return get_abstract(self.content)
     if name == "visible_comments":
         return self.comments.filter(visible=True)
     
     return super(Article, self).__getattr__(name)
コード例 #2
0
 def __unicode__(self):
     return "<BaseLine: %s>" % get_abstract(self.content)
コード例 #3
0
 def __unicode__(self):
     return "<ClinicCondition: %s>" % get_abstract(self.content)
コード例 #4
0
 def __unicode__(self):
     return "%s, %s" % (self.type,get_abstract(self.content))
コード例 #5
0
 def __unicode__(self):
     return "<Guideline: %s>" % get_abstract(self.content)
コード例 #6
0
 def __unicode__(self):
     return "%s" % get_abstract(self.brief_content)
コード例 #7
0
 def __unicode__(self):
     return "<ResultContent: %s>" % get_abstract(self.content)
コード例 #8
0
ファイル: models.py プロジェクト: luoxinliang/pyblog
 def __getattr__(self, name):
     if name == "abstract":
         return get_abstract(self.info)
     
     return super(BlogUser, self).__getattr__(name)
コード例 #9
0
ファイル: models.py プロジェクト: luoxinliang/pyblog
 def __getattr__(self, name):
     if name == "abstract":
         return get_abstract(self.content)
     return super(Article, self).__getattr__(name)