mirror of
https://github.com/makeplane/plane
synced 2024-06-14 14:31:34 +00:00
chore: removed extra exporter function
This commit is contained in:
parent
eee6658cc2
commit
97820e3528
@ -89,7 +89,6 @@ from plane.api.views import (
|
|||||||
IssueCommentPublicViewSet,
|
IssueCommentPublicViewSet,
|
||||||
IssueReactionViewSet,
|
IssueReactionViewSet,
|
||||||
CommentReactionViewSet,
|
CommentReactionViewSet,
|
||||||
ExportIssuesEndpoint,
|
|
||||||
## End Issues
|
## End Issues
|
||||||
# States
|
# States
|
||||||
StateViewSet,
|
StateViewSet,
|
||||||
@ -175,6 +174,10 @@ from plane.api.views import (
|
|||||||
InboxIssuePublicViewSet,
|
InboxIssuePublicViewSet,
|
||||||
IssueVotePublicViewSet,
|
IssueVotePublicViewSet,
|
||||||
## End Public Boards
|
## End Public Boards
|
||||||
|
## Exporter
|
||||||
|
ExportIssuesEndpoint,
|
||||||
|
## End Exporter
|
||||||
|
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
||||||
|
@ -1827,28 +1827,3 @@ class IssueVotePublicViewSet(BaseViewSet):
|
|||||||
status=status.HTTP_400_BAD_REQUEST,
|
status=status.HTTP_400_BAD_REQUEST,
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
||||||
class ExportIssuesEndpoint(BaseAPIView):
|
|
||||||
permission_classes = [
|
|
||||||
WorkSpaceAdminPermission,
|
|
||||||
]
|
|
||||||
|
|
||||||
def post(self, request, slug):
|
|
||||||
try:
|
|
||||||
|
|
||||||
issue_export_task.delay(
|
|
||||||
email=request.user.email, data=request.data, slug=slug ,exporter_name=request.user.first_name
|
|
||||||
)
|
|
||||||
|
|
||||||
return Response(
|
|
||||||
{
|
|
||||||
"message": f"Once the export is ready it will be emailed to you at {str(request.user.email)}"
|
|
||||||
},
|
|
||||||
status=status.HTTP_200_OK,
|
|
||||||
)
|
|
||||||
except Exception as e:
|
|
||||||
capture_exception(e)
|
|
||||||
return Response(
|
|
||||||
{"error": "Something went wrong please try again later"},
|
|
||||||
status=status.HTTP_400_BAD_REQUEST,
|
|
||||||
)
|
|
Loading…
Reference in New Issue
Block a user