Add BaseExporter.available_for_user()

This commit is contained in:
Raphael Michel
2023-06-16 17:33:14 +02:00
parent 7a48cac862
commit b51ca58820
5 changed files with 23 additions and 4 deletions

View File

@@ -1694,7 +1694,7 @@ class ExportMixin:
not isinstance(ex, OrganizerLevelExportMixin) or
self.request.user.has_organizer_permission(self.request.organizer, ex.organizer_required_permission,
self.request)
)
) and ex.available_for_user(self.request.user if self.request.user and self.request.user.is_authenticated else None)
]
return sorted(
raw_exporters,