From 51bbea4361d4fafe93997ed0f3dae05be8389c96 Mon Sep 17 00:00:00 2001 From: Matthew Lemon Date: Thu, 19 Sep 2024 19:52:02 +0100 Subject: wip: getting the thumbnails of resources --- pyblackbird_cc/resources/models.py | 3 +++ 1 file changed, 3 insertions(+) (limited to 'pyblackbird_cc/resources/models.py') diff --git a/pyblackbird_cc/resources/models.py b/pyblackbird_cc/resources/models.py index 6ecf525..7bbf244 100644 --- a/pyblackbird_cc/resources/models.py +++ b/pyblackbird_cc/resources/models.py @@ -115,6 +115,9 @@ class Resource(models.Model): def get_absolute_url(self): return reverse("resources:resource_detail", kwargs={"resource_id": self.pk}) + def thumbnail_urls(self): + ri = _extract_metadata_from_resource(self) + class ResourceType(models.Model): name = models.CharField(max_length=255, null=False) -- cgit v1.2.3