stake holders sharing & quota distribution to CMP - list of stake holder sharings

This commit is contained in:
2025-09-07 13:51:39 +03:30
parent bcc79d2c30
commit 6bac1bbd45
13 changed files with 298 additions and 15 deletions

View File

@@ -3,12 +3,12 @@ from rest_framework.response import Response
class SoftDeleteMixin:
def destroy(self, request, *args, **kwargs):
def destroy(self, request, pk=None, *args, **kwargs):
""" override destroy -> soft delete """
instance = self.get_object() # noqa
instance.soft_delete()
return Response(
{"detail": "رکورد با موفقیت حذف شد (Soft Delete)."},
{"detail": "رکورد با موفقیت حذف شد (Soft Delete)."}, # noqa
status=status.HTTP_200_OK
)