Mercurial > hg > Feedworm
view FeedEntry.py @ 20:0b8398ca6cd0
oops forgot these ones
author | Dirk Olmes <dirk@xanthippe.ping.de> |
---|---|
date | Wed, 28 Apr 2010 04:00:56 +0200 |
parents | 35225588b895 |
children | 74481aa49974 |
line wrap: on
line source
from datetime import datetime class FeedEntry(object): @staticmethod def findById(id, session): result = session.query(FeedEntry).filter(FeedEntry.id == id) return result.first() def __init__(self): self.create_timestamp = datetime.now() def __repr__(self): return "<FeedEntry (%d) %s>" % (self.pk, self.title) def userPresentableString(self): return self.title