Add default icon to feeds
Every feed has an icon. If not set by the user, the database automatically sets the default icon to media/default-icon-svg.
This commit is contained in:
Binary file not shown.
|
After Width: | Height: | Size: 10 KiB |
@@ -9,7 +9,7 @@ class User(models.Model):
|
||||
class Feed(models.Model):
|
||||
url = models.TextField(blank=False, null=False, validators=[URLValidator(['http', 'https'])])
|
||||
active = models.BooleanField()
|
||||
icon = models.FileField(upload_to='feed-icons', blank=True, null=True,
|
||||
icon = models.FileField(upload_to='feed-icons', blank=True, null=False, default='default-icon.svg',
|
||||
validators=[FileExtensionValidator(['png', 'svg'])])
|
||||
keywords = models.TextField(blank=False, null=False)
|
||||
match_all_keywords = models.BooleanField(blank=True, default=False)
|
||||
|
||||
Reference in New Issue
Block a user