mirror of
https://github.com/ArchiveBox/ArchiveBox.git
synced 2025-05-14 23:24:30 -04:00
customize django admin ui chrome
This commit is contained in:
parent
b44281919d
commit
ba7144f6f3
5 changed files with 126 additions and 1 deletions
|
@ -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
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue