aboutsummaryrefslogtreecommitdiff
path: root/src/web/models/bookmark.py
diff options
context:
space:
mode:
authorCédric Bonhomme <cedric@cedricbonhomme.org>2017-02-13 15:27:13 +0100
committerCédric Bonhomme <cedric@cedricbonhomme.org>2017-02-13 15:27:13 +0100
commit879427aa740f399aecd31c0e12909e6f39705f5e (patch)
tree5bb2d792e7211c763db550eaf8f0c676e37aa25a /src/web/models/bookmark.py
parentMerge branch 'master' of github.com:newspipe/newspipe into bookmark (diff)
downloadnewspipe-879427aa740f399aecd31c0e12909e6f39705f5e.tar.gz
newspipe-879427aa740f399aecd31c0e12909e6f39705f5e.tar.bz2
newspipe-879427aa740f399aecd31c0e12909e6f39705f5e.zip
wip
Diffstat (limited to 'src/web/models/bookmark.py')
-rw-r--r--src/web/models/bookmark.py9
1 files changed, 5 insertions, 4 deletions
diff --git a/src/web/models/bookmark.py b/src/web/models/bookmark.py
index a796cffa..b62285b7 100644
--- a/src/web/models/bookmark.py
+++ b/src/web/models/bookmark.py
@@ -34,14 +34,15 @@ from sqlalchemy.ext.associationproxy import association_proxy
from web.models.right_mixin import RightMixin
+
class Bookmark(db.Model, RightMixin):
"""
Represent a bookmark.
"""
id = db.Column(db.Integer(), primary_key=True)
href = db.Column(db.String(), default="")
+ title = db.Column(db.String(), default="")
description = db.Column(db.String(), default="FR")
- extended = db.Column(db.String())
shared = db.Column(db.Boolean(), default=False)
to_read = db.Column(db.Boolean(), default=False)
time = db.Column(db.DateTime(), default=datetime.utcnow)
@@ -49,9 +50,9 @@ class Bookmark(db.Model, RightMixin):
# relationships
tag_objs = db.relationship('BookmarkTag', back_populates='bookmark',
- cascade='all,delete-orphan',
- lazy=False,
- foreign_keys='[BookmarkTag.bookmark_id]')
+ cascade='all,delete-orphan',
+ lazy=False,
+ foreign_keys='[BookmarkTag.bookmark_id]')
tags = association_proxy('tag_objs', 'text')
bgstack15