feat: 修改ops api

This commit is contained in:
Aaron3S
2022-11-26 03:13:06 +08:00
parent 5e503ec5b8
commit 2c8f51940a
2 changed files with 9 additions and 1 deletions

View File

@@ -16,7 +16,9 @@ class JobViewSet(OrgBulkModelViewSet):
def get_queryset(self):
query_set = super().get_queryset()
return query_set.filter(instant=False)
if self.action != 'retrieve':
return query_set.filter(instant=False)
return query_set
def perform_create(self, serializer):
instance = serializer.save()