Mercurial > hg > Feedworm
comparison Mapping.py @ 5:bfd47f55d85b
add the updated date of the feed
author | Dirk Olmes <dirk@xanthippe.ping.de> |
---|---|
date | Mon, 26 Apr 2010 20:46:37 +0200 |
parents | e0199f383442 |
children | 87317ba41816 |
comparison
equal
deleted
inserted
replaced
4:e0199f383442 | 5:bfd47f55d85b |
---|---|
1 | 1 |
2 from Feed import Feed | 2 from Feed import Feed |
3 from FeedEntry import FeedEntry | 3 from FeedEntry import FeedEntry |
4 from sqlalchemy import Column | 4 from sqlalchemy import Column |
5 from sqlalchemy import DateTime | |
5 from sqlalchemy import ForeignKey | 6 from sqlalchemy import ForeignKey |
6 from sqlalchemy import Integer | 7 from sqlalchemy import Integer |
7 from sqlalchemy import MetaData | 8 from sqlalchemy import MetaData |
8 from sqlalchemy import String | 9 from sqlalchemy import String |
9 from sqlalchemy import Table | 10 from sqlalchemy import Table |
20 ) | 21 ) |
21 | 22 |
22 feedEntryTable = Table("feed_entry", metadata, | 23 feedEntryTable = Table("feed_entry", metadata, |
23 Column("pk", Integer, primary_key=True), | 24 Column("pk", Integer, primary_key=True), |
24 Column("id", String(255), nullable=False), | 25 Column("id", String(255), nullable=False), |
25 Column("url", String(255), nullable=False), | 26 Column("link", String(255), nullable=False), |
26 Column("title", String, nullable=False), | 27 Column("title", String, nullable=False), |
27 Column("summary", String, nullable=False), | 28 Column("summary", String, nullable=False), |
29 Column("updated", DateTime), | |
28 Column("feed_id", Integer, ForeignKey("feed.pk")) | 30 Column("feed_id", Integer, ForeignKey("feed.pk")) |
29 ) | 31 ) |
30 | 32 |
31 metadata.create_all() | 33 metadata.create_all() |
32 | 34 |