mirror of https://github.com/jumpserver/jumpserver
parent
a87ff2d880
commit
b81416d973
|
@ -28,9 +28,6 @@ class PlaybookViewSet(OrgBulkModelViewSet):
|
|||
model = Playbook
|
||||
search_fields = ('name', 'comment')
|
||||
|
||||
def allow_bulk_destroy(self, qs, filtered):
|
||||
return True
|
||||
|
||||
def get_queryset(self):
|
||||
queryset = super().get_queryset()
|
||||
queryset = queryset.filter(creator=self.request.user)
|
||||
|
|
|
@ -12,10 +12,10 @@ app_name = "ops"
|
|||
router = DefaultRouter()
|
||||
bulk_router = BulkRouter()
|
||||
|
||||
router.register(r'adhocs', api.AdHocViewSet, 'adhoc')
|
||||
router.register(r'playbooks', api.PlaybookViewSet, 'playbook')
|
||||
router.register(r'jobs', api.JobViewSet, 'job')
|
||||
router.register(r'job-executions', api.JobExecutionViewSet, 'job-execution')
|
||||
bulk_router.register(r'adhocs', api.AdHocViewSet, 'adhoc')
|
||||
bulk_router.register(r'playbooks', api.PlaybookViewSet, 'playbook')
|
||||
bulk_router.register(r'jobs', api.JobViewSet, 'job')
|
||||
bulk_router.register(r'job-executions', api.JobExecutionViewSet, 'job-execution')
|
||||
|
||||
router.register(r'celery/period-tasks', api.CeleryPeriodTaskViewSet, 'celery-period-task')
|
||||
|
||||
|
|
Loading…
Reference in New Issue