Skip to content

Commit

Permalink
patch: add download records to actions
Browse files Browse the repository at this point in the history
  • Loading branch information
tinashechiraya authored Mar 4, 2024
1 parent 85fcb6e commit ae74f78
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion django_project/monitor/admin.py
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,8 @@ def download_records(self, request, queryset):
return response
download_records.short_description = "Download selected records"

actions = ['download_records']


class SiteImageInline(admin.TabularInline):
model = SiteImage
Expand All @@ -113,4 +115,3 @@ class SitesAdmin(admin.ModelAdmin):

admin.site.register(ObservationPestImage)
admin.site.register(Assessment, admin.ModelAdmin)
admin.site.add_action('download_records')

0 comments on commit ae74f78

Please sign in to comment.