Beispiel #1
0
 def get_by_wiki(self, citiao):
     tt = CabWiki.select().where(CabWiki.title == citiao).count()
     if tt == 0:
         return None
     else:
         self.update_view_count(citiao)
         return CabWiki.get(CabWiki.title == citiao)
Beispiel #2
0
 def get_by_wiki(self, citiao):
     tt = CabWiki.select().where(CabWiki.title == citiao).count()
     if tt == 0:
         return None
     else:
         self.update_view_count(citiao)
         return CabWiki.get(CabWiki.title == citiao)
Beispiel #3
0
 def get_by_title(self, in_title):
     try:
         return CabWiki.get(CabWiki.title == in_title)
     except:
         return None
Beispiel #4
0
 def get_by_id(self, in_uid):
     tt = CabWiki.select().where(CabWiki.uid == in_uid).count()
     if tt == 0:
         return None
     else:
         return CabWiki.get(CabWiki.uid == in_uid)
Beispiel #5
0
 def get_by_title(self, in_title):
     try:
         return CabWiki.get(CabWiki.title == in_title)
     except:
         return None
Beispiel #6
0
 def get_by_id(self, in_uid):
     tt = CabWiki.select().where(CabWiki.uid == in_uid).count()
     if tt == 0:
         return None
     else:
         return CabWiki.get(CabWiki.uid == in_uid)