mirror of
https://github.com/ZwareBear/awx.git
synced 2026-03-20 07:43:35 -05:00
Merge pull request #13593 from gamuniz/fix_workflowapproval_view
Make /api/v2/workflow_approvals/ endpoint read-only
This commit is contained in:
@@ -4288,7 +4288,7 @@ class WorkflowApprovalTemplateJobsList(SubListAPIView):
|
|||||||
parent_key = 'workflow_approval_template'
|
parent_key = 'workflow_approval_template'
|
||||||
|
|
||||||
|
|
||||||
class WorkflowApprovalList(ListCreateAPIView):
|
class WorkflowApprovalList(ListAPIView):
|
||||||
model = models.WorkflowApproval
|
model = models.WorkflowApproval
|
||||||
serializer_class = serializers.WorkflowApprovalListSerializer
|
serializer_class = serializers.WorkflowApprovalListSerializer
|
||||||
|
|
||||||
|
|||||||
@@ -16,7 +16,7 @@ import glob
|
|||||||
# Normally a read-only endpoint should not have a module (i.e. /api/v2/me) but sometimes we reuse a name
|
# Normally a read-only endpoint should not have a module (i.e. /api/v2/me) but sometimes we reuse a name
|
||||||
# For example, we have a role module but /api/v2/roles is a read only endpoint.
|
# For example, we have a role module but /api/v2/roles is a read only endpoint.
|
||||||
# This list indicates which read-only endpoints have associated modules with them.
|
# This list indicates which read-only endpoints have associated modules with them.
|
||||||
read_only_endpoints_with_modules = ['settings', 'role', 'project_update']
|
read_only_endpoints_with_modules = ['settings', 'role', 'project_update', 'workflow_approval']
|
||||||
|
|
||||||
# If a module should not be created for an endpoint and the endpoint is not read-only add it here
|
# If a module should not be created for an endpoint and the endpoint is not read-only add it here
|
||||||
# THINK HARD ABOUT DOING THIS
|
# THINK HARD ABOUT DOING THIS
|
||||||
|
|||||||
Reference in New Issue
Block a user