customize django admin ui chrome

This commit is contained in:
Nick Sweeting 2019-04-22 21:40:42 -04:00
parent b44281919d
commit ba7144f6f3
5 changed files with 126 additions and 1 deletions

View file

@ -5,6 +5,7 @@ import uuid
from django.db import models
from legacy.schema import Link
from legacy.util import parse_date
class Page(models.Model):
@ -44,6 +45,10 @@ class Page(models.Model):
def as_link(self) -> Link:
return Link.from_json(self.as_json())
@property
def bookmarked(self):
return parse_date(self.timestamp)
@property
def is_archived(self):
return self.as_link().is_archived