mirror of
https://github.com/sissbruecker/linkding.git
synced 2025-08-06 18:38:31 +02:00
Implement basic bookmark page
This commit is contained in:
15
bookmarks/models.py
Normal file
15
bookmarks/models.py
Normal file
@@ -0,0 +1,15 @@
|
||||
from django.contrib.auth import get_user_model
|
||||
from django.db import models
|
||||
|
||||
|
||||
# Create your models here.
|
||||
class Bookmark(models.Model):
|
||||
url = models.TextField()
|
||||
title = models.CharField(max_length=512)
|
||||
description = models.TextField()
|
||||
unread = models.BooleanField(default=True)
|
||||
date_added = models.DateTimeField()
|
||||
owner = models.ForeignKey(get_user_model(), on_delete=models.CASCADE)
|
||||
|
||||
def __str__(self):
|
||||
return self.title + ' (' + self.url[:30] + '...)'
|
Reference in New Issue
Block a user