mirror of
https://github.com/ArchiveBox/ArchiveBox
synced 2024-11-26 22:20:21 +00:00
fix adding and removing tags via admin snapshot list
This commit is contained in:
parent
49b77b91bb
commit
5568b3b612
1 changed files with 3 additions and 4 deletions
|
@ -213,10 +213,9 @@ class SnapshotAdmin(SearchResultsAdminMixin, admin.ModelAdmin):
|
||||||
delete_snapshots.short_description = "Delete"
|
delete_snapshots.short_description = "Delete"
|
||||||
|
|
||||||
def add_tag(self, request, queryset):
|
def add_tag(self, request, queryset):
|
||||||
if tag and tag.id:
|
tag = request.POST['tag']
|
||||||
tag = request.POST['tag']
|
for obj in queryset:
|
||||||
for obj in queryset:
|
obj.tags.add(tag)
|
||||||
obj.tags.add(tag)
|
|
||||||
|
|
||||||
add_tag.short_description = "Add tag"
|
add_tag.short_description = "Add tag"
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue