Files
konova/konova/views/report.py
mpeltriaux 1af807deae # Remove view
* refactors remove view methods into classes
* introduced AbstractRemoveView
* disables final-delete actions from admin views
* extends error warnings on RemoveEcoAccountModalForm
* removes LoginRequiredMixin from AbstractPublicReportView to make it accessible for the public
* updates translations
2025-12-14 17:37:01 +01:00

25 lines
622 B
Python

"""
Author: Michel Peltriaux
Created on: 14.12.25
"""
from abc import abstractmethod, ABC
from django.http import HttpRequest, HttpResponse
from django.utils.decorators import method_decorator
from django.views import View
from konova.decorators import uuid_required
class AbstractPublicReportView(View, ABC):
_TEMPLATE = None
@method_decorator(uuid_required)
def dispatch(self, request, *args, **kwargs):
return super().dispatch(request, *args, **kwargs)
@abstractmethod
def get(self, request: HttpRequest, id: str, *args, **kwargs) -> HttpResponse:
raise NotImplementedError()