mirror of
https://github.com/makeplane/plane
synced 2024-06-14 14:31:34 +00:00
chore: project and workspace state change
This commit is contained in:
parent
4761d4e0e9
commit
8288e1363c
@ -49,8 +49,18 @@ class StateViewSet(BaseViewSet):
|
||||
return Response(serializer.errors, status=status.HTTP_400_BAD_REQUEST)
|
||||
|
||||
def list(self, request, slug, project_id):
|
||||
states = State.objects.filter(workspace__slug=slug, project_id=project_id).values(
|
||||
"id", "project_id", "workspace__slug", "name", "color", "group"
|
||||
states = State.objects.filter(
|
||||
workspace__slug=slug, project_id=project_id
|
||||
).values(
|
||||
"id",
|
||||
"project_id",
|
||||
"workspace__slug",
|
||||
"name",
|
||||
"color",
|
||||
"group",
|
||||
"default",
|
||||
"description",
|
||||
"sequence",
|
||||
)
|
||||
grouped = request.GET.get("grouped", False)
|
||||
if grouped == "true":
|
||||
|
@ -1469,7 +1469,15 @@ class WorkspaceStatesEndpoint(BaseAPIView):
|
||||
workspace__slug=slug,
|
||||
project__project_projectmember__member=request.user,
|
||||
).values(
|
||||
"id", "project_id", "workspace__slug", "name", "color", "group"
|
||||
"id",
|
||||
"project_id",
|
||||
"workspace__slug",
|
||||
"name",
|
||||
"color",
|
||||
"group",
|
||||
"default",
|
||||
"description",
|
||||
"sequence",
|
||||
)
|
||||
return Response(states, status=status.HTTP_200_OK)
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user